/* Native debugging support for Intel x86 running DJGPP.
- Copyright (C) 1997, 1999, 2000, 2001, 2005, 2006, 2007, 2008, 2009, 2010,
- 2011 Free Software Foundation, Inc.
+ Copyright (C) 1997, 1999-2001, 2005-2012 Free Software Foundation,
+ Inc.
Written by Robert Hoehne.
This file is part of GDB.
return STATUS;
}
+/* Get the value of the DR7 debug status register from the inferior.
+ Here we just return the value stored in D_REGS, as we've got it
+ from the last go32_wait call. */
+
+static unsigned long
+go32_get_dr7 (void)
+{
+ return CONTROL;
+}
+
+/* Get the value of the DR debug register I from the inferior. Here
+ we just return the value stored in D_REGS, as we've got it from the
+ last go32_wait call. */
+
+static CORE_ADDR
+go32_get_dr (int i)
+{
+ if (i < 0 || i > 3)
+ internal_error (__FILE__, __LINE__,
+ _("Invalid register %d in go32_get_dr.\n"), i);
+ return D_REGS[i];
+}
+
/* Put the device open on handle FD into either raw or cooked
mode, return 1 if it was in raw mode, zero otherwise. */
i386_dr_low.set_control = go32_set_dr7;
i386_dr_low.set_addr = go32_set_dr;
- i386_dr_low.reset_addr = NULL;
i386_dr_low.get_status = go32_get_dr6;
+ i386_dr_low.get_control = go32_get_dr7;
+ i386_dr_low.get_addr = go32_get_dr;
i386_set_debug_register_length (4);
go32_ops.to_magic = OPS_MAGIC;