Module Name: src
Committed By: kamil
Date: Wed Jan 18 12:15:21 UTC 2017
Modified Files:
src/sys/arch/x86/x86: dbregs.c
Log Message:
Fix bug with swapped event type and register that fired in hw watchpoints
Swap bits for DR_EVENT_MASK and DR_REGISTER_MASK.
Sponsored by <The NetBSD Foundation>
To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/arch/x86/x86/dbregs.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/arch/x86/x86/dbregs.c
diff -u src/sys/arch/x86/x86/dbregs.c:1.3 src/sys/arch/x86/x86/dbregs.c:1.4
--- src/sys/arch/x86/x86/dbregs.c:1.3 Wed Jan 18 05:48:16 2017
+++ src/sys/arch/x86/x86/dbregs.c Wed Jan 18 12:15:21 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: dbregs.c,v 1.3 2017/01/18 05:48:16 kamil Exp $ */
+/* $NetBSD: dbregs.c,v 1.4 2017/01/18 12:15:21 kamil Exp $ */
/*-
* Copyright (c) 2016 The NetBSD Foundation, Inc.
@@ -144,8 +144,8 @@ clear_x86_hw_watchpoints(void)
}
/* Local temporary bitfield concept to compose event and register that fired */
-#define DR_EVENT_MASK __BITS(15,8)
-#define DR_REGISTER_MASK __BITS(7,0)
+#define DR_EVENT_MASK __BITS(7,0)
+#define DR_REGISTER_MASK __BITS(15,8)
int
user_trap_x86_hw_watchpoint(void)