aboutsummaryrefslogtreecommitdiff
path: root/gdb/m32r-linux-nat.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/m32r-linux-nat.c')
-rw-r--r--gdb/m32r-linux-nat.c29
1 files changed, 24 insertions, 5 deletions
diff --git a/gdb/m32r-linux-nat.c b/gdb/m32r-linux-nat.c
index a8c5031..8dcce7d 100644
--- a/gdb/m32r-linux-nat.c
+++ b/gdb/m32r-linux-nat.c
@@ -1,6 +1,6 @@
/* Native-dependent code for GNU/Linux m32r.
- Copyright 2004 Free Software Foundation, Inc.
+ Copyright 2004, 2005 Free Software Foundation, Inc.
This file is part of GDB.
@@ -24,6 +24,7 @@
#include "gdbcore.h"
#include "regcache.h"
#include "linux-nat.h"
+#include "target.h"
#include "gdb_assert.h"
#include "gdb_string.h"
@@ -187,8 +188,8 @@ fill_fpregset (gdb_fpregset_t *fpregs, int regno)
this for all registers (including the floating point and SSE
registers). */
-void
-fetch_inferior_registers (int regno)
+static void
+m32r_linux_fetch_inferior_registers (int regno)
{
int tid;
@@ -213,8 +214,8 @@ fetch_inferior_registers (int regno)
/* Store register REGNO back into the child process. If REGNO is -1,
do this for all registers (including the floating point and SSE
registers). */
-void
-store_inferior_registers (int regno)
+static void
+m32r_linux_store_inferior_registers (int regno)
{
int tid;
@@ -233,3 +234,21 @@ store_inferior_registers (int regno)
internal_error (__FILE__, __LINE__,
_("Got request to store bad register number %d."), regno);
}
+
+void _initialize_m32r_linux_nat (void);
+
+void
+_initialize_m32r_linux_nat (void)
+{
+ struct target_ops *t;
+
+ /* Fill in the generic GNU/Linux methods. */
+ t = linux_target ();
+
+ /* Add our register access methods. */
+ t->to_fetch_registers = m32r_linux_fetch_inferior_registers;
+ t->to_store_registers = m32r_linux_store_inferior_registers;
+
+ /* Register the target. */
+ add_target (t);
+}