*** empty log message ***
[binutils-gdb.git] / gdb / mips-linux-nat.c
index ac8d96daac4a35b0d47991cdb7f456d6cdf26783..e9e7c0277924ffc2fd74a057e47679becb799580 100644 (file)
@@ -1,6 +1,6 @@
 /* Native-dependent code for GNU/Linux on MIPS processors.
 
-   Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009
+   Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010
    Free Software Foundation, Inc.
 
    This file is part of GDB.
@@ -595,7 +595,8 @@ mips_show_dr (const char *func, CORE_ADDR addr,
 
   puts_unfiltered (func);
   if (addr || len)
-    printf_unfiltered (" (addr=0x%s, len=%d, type=%s)", paddr (addr), len,
+    printf_unfiltered (" (addr=%s, len=%d, type=%s)",
+                      paddress (target_gdbarch, addr), len,
                       type == hw_write ? "data-write"
                       : (type == hw_read ? "data-read"
                          : (type == hw_access ? "data-read/write"
@@ -604,9 +605,11 @@ mips_show_dr (const char *func, CORE_ADDR addr,
   puts_unfiltered (":\n");
 
   for (i = 0; i < MAX_DEBUG_REGISTER; i++)
-    printf_unfiltered ("\tDR%d: lo=0x%s, hi=0x%s\n",
-                      i, paddr (get_watchlo (&watch_mirror, i)),
-                      paddr (get_watchhi (&watch_mirror, i)));
+    printf_unfiltered ("\tDR%d: lo=%s, hi=%s\n", i,
+                      paddress (target_gdbarch,
+                                get_watchlo (&watch_mirror, i)),
+                      paddress (target_gdbarch,
+                                get_watchhi (&watch_mirror, i)));
 }
 
 /* Return 1 if watch registers are usable.  Cached information is used
@@ -923,7 +926,8 @@ populate_regs_from_watches (struct pt_watch_regs *regs)
    watch.  Return zero on success.  */
 
 static int
-mips_linux_insert_watchpoint (CORE_ADDR addr, int len, int type)
+mips_linux_insert_watchpoint (CORE_ADDR addr, int len, int type,
+                             struct expression *cond)
 {
   struct pt_watch_regs regs;
   struct mips_watchpoint *new_watch;
@@ -972,7 +976,8 @@ mips_linux_insert_watchpoint (CORE_ADDR addr, int len, int type)
    Return zero on success.  */
 
 static int
-mips_linux_remove_watchpoint (CORE_ADDR addr, int len, int type)
+mips_linux_remove_watchpoint (CORE_ADDR addr, int len, int type,
+                             struct expression *cond)
 {
   int retval;
   int deleted_one;
@@ -1044,15 +1049,18 @@ _initialize_mips_linux_nat (void)
 {
   struct target_ops *t;
 
-  deprecated_add_set_cmd ("show-debug-regs", class_maintenance,
-                         var_boolean, (char *) &maint_show_dr, _("\
-Set whether to show variables that mirror the mips debug registers.\n\
+  add_setshow_boolean_cmd ("show-debug-regs", class_maintenance,
+                          &maint_show_dr, _("\
+Set whether to show variables that mirror the mips debug registers."), _("\
+Show whether to show variables that mirror the mips debug registers."), _("\
 Use \"on\" to enable, \"off\" to disable.\n\
 If enabled, the debug registers values are shown when GDB inserts\n\
 or removes a hardware breakpoint or watchpoint, and when the inferior\n\
 triggers a breakpoint or watchpoint."),
-                         &maintenancelist);
-
+                          NULL,
+                          NULL,
+                          &maintenance_set_cmdlist,
+                          &maintenance_show_cmdlist);
 
   t = linux_trad_target (mips_linux_register_u_offset);