Make hw watchpoints work with both the 2.4.2 kernel and the 2.4.3 kernel.
authorKevin Buettner <kevinb@redhat.com>
Mon, 16 Apr 2001 21:26:46 +0000 (21:26 +0000)
committerKevin Buettner <kevinb@redhat.com>
Mon, 16 Apr 2001 21:26:46 +0000 (21:26 +0000)
gdb/ChangeLog
gdb/ia64-linux-nat.c

index db36920d705e4edf6cb7fa810be2f0f179a5e498..d6a5684609e2936cec4f5513a63f3ab756c406c4 100644 (file)
@@ -1,3 +1,9 @@
+2001-03-31  Kevin Buettner  <kevinb@redhat.com>
+
+       * ia64-linux-nat.c (ia64_linux_stopped_by_watchpoint): Adjust
+       comparison against TRAP_HWBKPT constant yet again to account
+       for the various values used by different kernel versions.
+
 2001-04-16  Daniel Berlin  <dan@cgsoftware.com>
 
        * demangle.c (_initialize_demangler): Use xcalloc on the
index 7fe28d11581bac59cae516e3ea0f4f46d75ef84f..1a000eafc363cf674fd5a51f32b46b3ce0bdedac 100644 (file)
@@ -630,7 +630,7 @@ ia64_linux_stopped_by_watchpoint (int pid)
   errno = 0;
   ptrace (PTRACE_GETSIGINFO, tid, (PTRACE_ARG3_TYPE) 0, &siginfo);
 
-  if (errno != 0 || siginfo.si_code != 0x30004 /* TRAP_HWBKPT */)
+  if (errno != 0 || (siginfo.si_code & 0xffff) != 0x0004 /* TRAP_HWBKPT */)
     return 0;
 
   psr = read_register_pid (IA64_PSR_REGNUM, pid);