summaryrefslogtreecommitdiff
path: root/gdb/config
diff options
context:
space:
mode:
authorJim Blandy <jimb@codesourcery.com>2004-02-18 03:47:35 +0000
committerJim Blandy <jimb@codesourcery.com>2004-02-18 03:47:35 +0000
commitd1931c28e1157353cbb0a8e38e37ff8c6e4a4a74 (patch)
tree975ed40b91be712fe435a39b04cd6af62a4cc94d /gdb/config
parent267be6a2d9c481b5e7cde35f050a3719a207f446 (diff)
downloadgdb-d1931c28e1157353cbb0a8e38e37ff8c6e4a4a74.tar.gz
2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
Committed by Jim Blandy <jimb@redhat.com>. * config/s390/nm-linux.h: Update comments. (target_insert_watchpoint, target_remove_watchpoint): Redefine. (STOPPED_BY_WATCHPOINT): Redefine. (TARGET_CAN_USE_HARDWARE_WATCHPOINT): Redefine to 1. (s390_insert_watchpoint, s390_remove_watchpoint): Update prototype. (s390_stopped_by_watchpoint): Likewise. (watch_area_cnt): Remove. * s390-nat.c: Update comments. (watch_area): Remove typedef. Global replace watch_area by struct watch_area. (watch_area_cnt, watch_lo_addr, watch_hi_addr): Remove. (s390_stopped_by_watchpoint): Remove pid argument, use s390_inferior_tid. Add short-cut for the no watchpoint case. (s390_fix_watch_points): Remove pid argument, use s390_inferior_tid. Recompute area spanned by watchpoints. (s390_insert_watchpoint, s390_remove_watchpoint): Remove pid argument. Reimplement.
Diffstat (limited to 'gdb/config')
-rw-r--r--gdb/config/s390/nm-linux.h41
1 files changed, 16 insertions, 25 deletions
diff --git a/gdb/config/s390/nm-linux.h b/gdb/config/s390/nm-linux.h
index 6931efb4c00..04cd863212a 100644
--- a/gdb/config/s390/nm-linux.h
+++ b/gdb/config/s390/nm-linux.h
@@ -39,33 +39,24 @@
extern int kernel_u_size (void);
-/* WATCHPOINT SPECIFIC STUFF */
+/* Hardware watchpoints. */
+
+extern int s390_stopped_by_watchpoint (void);
+extern int s390_insert_watchpoint (CORE_ADDR addr, int len);
+extern int s390_remove_watchpoint (CORE_ADDR addr, int len);
#define TARGET_HAS_HARDWARE_WATCHPOINTS
+#define TARGET_CAN_USE_HARDWARE_WATCHPOINT(type, cnt, ot) 1
#define HAVE_CONTINUABLE_WATCHPOINT 1
-#define target_insert_watchpoint(addr, len, type) \
- s390_insert_watchpoint (PIDGET (inferior_ptid), addr, len, type)
-
-#define target_remove_watchpoint(addr, len, type) \
- s390_remove_watchpoint (PIDGET (inferior_ptid), addr, len)
-
-extern int watch_area_cnt;
-/* gdb if really stupid & calls this all the time without a
- watchpoint even being set */
-#define STOPPED_BY_WATCHPOINT(W) \
- (watch_area_cnt&&s390_stopped_by_watchpoint (PIDGET(inferior_ptid)))
-
-extern CORE_ADDR s390_stopped_by_watchpoint (int);
-
-/*
- Type can be 1 for a read_watchpoint or 2 for an access watchpoint.
- */
-extern int s390_insert_watchpoint (int pid, CORE_ADDR addr, int len, int rw);
-extern int s390_remove_watchpoint (int pid, CORE_ADDR addr, int len);
-#define TARGET_CAN_USE_HARDWARE_WATCHPOINT(type, cnt, ot) \
- (((type) == bp_hardware_watchpoint)|| \
- ((type) == bp_watchpoint)|| \
- ((type) == bp_read_watchpoint) || \
- ((type) == bp_access_watchpoint))
+
+#define STOPPED_BY_WATCHPOINT(w) \
+ s390_stopped_by_watchpoint ()
+
+#define target_insert_watchpoint(addr, len, type) \
+ s390_insert_watchpoint (addr, len)
+
+#define target_remove_watchpoint(addr, len, type) \
+ s390_remove_watchpoint (addr, len)
+
#endif /* nm_linux.h */