summaryrefslogtreecommitdiff
path: root/gdb/remote-st.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/remote-st.c')
-rw-r--r--gdb/remote-st.c95
1 files changed, 29 insertions, 66 deletions
diff --git a/gdb/remote-st.c b/gdb/remote-st.c
index e820b28e51a..485f9414493 100644
--- a/gdb/remote-st.c
+++ b/gdb/remote-st.c
@@ -84,8 +84,7 @@ printf_stdebug (char *pattern,...)
stuff. */
static int
-readchar (timeout)
- int timeout;
+readchar (int timeout)
{
int c;
@@ -113,9 +112,7 @@ readchar (timeout)
non-zero, then discard non-matching input, else print it out.
Let the user break out immediately. */
static void
-expect (string, discard)
- char *string;
- int discard;
+expect (char *string, int discard)
{
char *p = string;
int c;
@@ -160,8 +157,7 @@ expect (string, discard)
necessary to prevent getting into states from which we can't
recover. */
static void
-expect_prompt (discard)
- int discard;
+expect_prompt (int discard)
{
#if defined (LOG_FILE)
/* This is a convenient place to do this. The idea is to do it often
@@ -174,8 +170,7 @@ expect_prompt (discard)
/* Get a hex digit from the remote system & return its value.
If ignore_space is nonzero, ignore spaces (not newline, tab, etc). */
static int
-get_hex_digit (ignore_space)
- int ignore_space;
+get_hex_digit (int ignore_space)
{
int ch;
while (1)
@@ -200,8 +195,7 @@ get_hex_digit (ignore_space)
/* Get a byte from stdebug and put it in *BYT. Accept any number
leading spaces. */
static void
-get_hex_byte (byt)
- char *byt;
+get_hex_byte (char *byt)
{
int val;
@@ -213,9 +207,7 @@ get_hex_byte (byt)
/* Get N 32-bit words from remote, each preceded by a space,
and put them in registers starting at REGNO. */
static void
-get_hex_regs (n, regno)
- int n;
- int regno;
+get_hex_regs (int n, int regno)
{
long val;
int i;
@@ -234,10 +226,7 @@ get_hex_regs (n, regno)
/* This is called not only when we first attach, but also when the
user types "run" after having attached. */
static void
-st2000_create_inferior (execfile, args, env)
- char *execfile;
- char *args;
- char **env;
+st2000_create_inferior (char *execfile, char *args, char **env)
{
int entry_pt;
@@ -276,9 +265,7 @@ static int baudrate = 9600;
static char dev_name[100];
static void
-st2000_open (args, from_tty)
- char *args;
- int from_tty;
+st2000_open (char *args, int from_tty)
{
int n;
char junk[100];
@@ -323,8 +310,7 @@ or target st2000 <host> <port>\n");
/* Close out all files and local state before this target loses control. */
static void
-st2000_close (quitting)
- int quitting;
+st2000_close (int quitting)
{
SERIAL_CLOSE (st2000_desc);
@@ -343,8 +329,7 @@ st2000_close (quitting)
Use this when you want to detach and do something else
with your gdb. */
static void
-st2000_detach (from_tty)
- int from_tty;
+st2000_detach (int from_tty)
{
pop_target (); /* calls st2000_close to do the real work */
if (from_tty)
@@ -354,9 +339,7 @@ st2000_detach (from_tty)
/* Tell the remote machine to resume. */
static void
-st2000_resume (pid, step, sig)
- int pid, step;
- enum target_signal sig;
+st2000_resume (int pid, int step, enum target_signal sig)
{
if (step)
{
@@ -376,8 +359,7 @@ st2000_resume (pid, step, sig)
storing status in STATUS just as `wait' would. */
static int
-st2000_wait (status)
- struct target_waitstatus *status;
+st2000_wait (struct target_waitstatus *status)
{
int old_timeout = timeout;
@@ -401,8 +383,7 @@ st2000_wait (status)
STDEBUG wants. Lets take advantage of that just as long as possible! */
static char *
-get_reg_name (regno)
- int regno;
+get_reg_name (int regno)
{
static char buf[50];
const char *p;
@@ -420,7 +401,7 @@ get_reg_name (regno)
/* Read the remote registers into the block REGS. */
static void
-st2000_fetch_registers ()
+st2000_fetch_registers (void)
{
int regno;
@@ -434,8 +415,7 @@ st2000_fetch_registers ()
/* Fetch register REGNO, or all registers if REGNO is -1.
Returns errno value. */
static void
-st2000_fetch_register (regno)
- int regno;
+st2000_fetch_register (int regno)
{
if (regno == -1)
st2000_fetch_registers ();
@@ -454,7 +434,7 @@ st2000_fetch_register (regno)
/* Store the remote registers from the contents of the block REGS. */
static void
-st2000_store_registers ()
+st2000_store_registers (void)
{
int regno;
@@ -467,8 +447,7 @@ st2000_store_registers ()
/* Store register REGNO, or all if REGNO == 0.
Return errno value. */
static void
-st2000_store_register (regno)
- int regno;
+st2000_store_register (int regno)
{
if (regno == -1)
st2000_store_registers ();
@@ -488,13 +467,13 @@ st2000_store_register (regno)
debugged. */
static void
-st2000_prepare_to_store ()
+st2000_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
static void
-st2000_files_info ()
+st2000_files_info (void)
{
printf ("\tAttached to %s at %d baud.\n",
dev_name, baudrate);
@@ -503,10 +482,7 @@ st2000_files_info ()
/* Copy LEN bytes of data from debugger memory at MYADDR
to inferior's memory at MEMADDR. Returns length moved. */
static int
-st2000_write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- unsigned char *myaddr;
- int len;
+st2000_write_inferior_memory (CORE_ADDR memaddr, unsigned char *myaddr, int len)
{
int i;
@@ -521,10 +497,7 @@ st2000_write_inferior_memory (memaddr, myaddr, len)
/* Read LEN bytes from inferior memory at MEMADDR. Put the result
at debugger address MYADDR. Returns length moved. */
static int
-st2000_read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+st2000_read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
int i;
@@ -591,9 +564,7 @@ st2000_xfer_inferior_memory (memaddr, myaddr, len, write, target)
}
static void
-st2000_kill (args, from_tty)
- char *args;
- int from_tty;
+st2000_kill (char *args, int from_tty)
{
return; /* Ignore attempts to kill target system */
}
@@ -605,7 +576,7 @@ st2000_kill (args, from_tty)
instructions. */
static void
-st2000_mourn_inferior ()
+st2000_mourn_inferior (void)
{
remove_breakpoints ();
unpush_target (&st2000_ops);
@@ -618,9 +589,7 @@ static CORE_ADDR breakaddr[MAX_STDEBUG_BREAKPOINTS] =
{0};
static int
-st2000_insert_breakpoint (addr, shadow)
- CORE_ADDR addr;
- char *shadow;
+st2000_insert_breakpoint (CORE_ADDR addr, char *shadow)
{
int i;
CORE_ADDR bp_addr = addr;
@@ -644,9 +613,7 @@ st2000_insert_breakpoint (addr, shadow)
}
static int
-st2000_remove_breakpoint (addr, shadow)
- CORE_ADDR addr;
- char *shadow;
+st2000_remove_breakpoint (CORE_ADDR addr, char *shadow)
{
int i;
@@ -669,9 +636,7 @@ st2000_remove_breakpoint (addr, shadow)
on the users terminal until the prompt is seen. */
static void
-st2000_command (args, fromtty)
- char *args;
- int fromtty;
+st2000_command (char *args, int fromtty)
{
if (!st2000_desc)
error ("st2000 target not open.");
@@ -689,7 +654,7 @@ st2000_command (args, fromtty)
/*static struct ttystate ttystate; */
static void
-cleanup_tty ()
+cleanup_tty (void)
{
printf ("\r\n[Exiting connect mode]\r\n");
/* SERIAL_RESTORE(0, &ttystate); */
@@ -699,9 +664,7 @@ cleanup_tty ()
/* This all should now be in serial.c */
static void
-connect_command (args, fromtty)
- char *args;
- int fromtty;
+connect_command (char *args, int fromtty)
{
fd_set readfds;
int numfds;
@@ -855,7 +818,7 @@ the speed to connect at in bits per second.";
};
void
-_initialize_remote_st2000 ()
+_initialize_remote_st2000 (void)
{
init_st2000_ops ();
add_target (&st2000_ops);