diff options
author | Pedro Alves <palves@redhat.com> | 2012-05-24 16:39:15 +0000 |
---|---|---|
committer | Pedro Alves <palves@redhat.com> | 2012-05-24 16:39:15 +0000 |
commit | 2ea286498fd2ddceaf074bfbc9a2986777ea0396 (patch) | |
tree | 4360c24b1ef43fad4fa8143e65435c33f053617c /gdb/gdbserver | |
parent | b09846a918b74f0371149f730f8b391548b11a8d (diff) | |
download | gdb-2ea286498fd2ddceaf074bfbc9a2986777ea0396.zip gdb-2ea286498fd2ddceaf074bfbc9a2986777ea0396.tar.gz gdb-2ea286498fd2ddceaf074bfbc9a2986777ea0396.tar.bz2 |
gdb/
2012-05-24 Pedro Alves <palves@redhat.com>
PR gdb/7205
Replace target_signal with gdb_signal throughout.
gdb/gdbserver/
2012-05-24 Pedro Alves <palves@redhat.com>
PR gdb/7205
Replace target_signal with gdb_signal throughout.
include/gdb/
2012-05-24 Pedro Alves <palves@redhat.com>
PR gdb/7205
Replace target_signal with gdb_signal throughout.
sim/common/
2012-05-24 Pedro Alves <palves@redhat.com>
PR gdb/7205
Replace target_signal with gdb_signal throughout.
Diffstat (limited to 'gdb/gdbserver')
-rw-r--r-- | gdb/gdbserver/ChangeLog | 6 | ||||
-rw-r--r-- | gdb/gdbserver/linux-low.c | 20 | ||||
-rw-r--r-- | gdb/gdbserver/lynx-low.c | 6 | ||||
-rw-r--r-- | gdb/gdbserver/nto-low.c | 4 | ||||
-rw-r--r-- | gdb/gdbserver/server.c | 14 | ||||
-rw-r--r-- | gdb/gdbserver/spu-low.c | 4 | ||||
-rw-r--r-- | gdb/gdbserver/target.c | 8 | ||||
-rw-r--r-- | gdb/gdbserver/target.h | 4 | ||||
-rw-r--r-- | gdb/gdbserver/win32-low.c | 4 |
9 files changed, 38 insertions, 32 deletions
diff --git a/gdb/gdbserver/ChangeLog b/gdb/gdbserver/ChangeLog index 1976a42..ed146eb 100644 --- a/gdb/gdbserver/ChangeLog +++ b/gdb/gdbserver/ChangeLog @@ -1,3 +1,9 @@ +2012-05-24 Pedro Alves <palves@redhat.com> + + PR gdb/7205 + + Replace target_signal with gdb_signal throughout. + 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com> * linux-low.c (linux_store_registers): Avoid the copying sequence diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c index 5fe19fd..e3c6ed6 100644 --- a/gdb/gdbserver/linux-low.c +++ b/gdb/gdbserver/linux-low.c @@ -1062,7 +1062,7 @@ linux_kill (int pid) static int get_detach_signal (struct thread_info *thread) { - enum target_signal signo = TARGET_SIGNAL_0; + enum gdb_signal signo = TARGET_SIGNAL_0; int status; struct lwp_info *lp = get_thread_lwp (thread); @@ -1102,7 +1102,7 @@ get_detach_signal (struct thread_info *thread) return 0; } - signo = target_signal_from_host (WSTOPSIG (status)); + signo = gdb_signal_from_host (WSTOPSIG (status)); if (program_signals_p && !program_signals[signo]) { @@ -1110,7 +1110,7 @@ get_detach_signal (struct thread_info *thread) fprintf (stderr, "GPS: lwp %s had signal %s, but it is in nopass state\n", target_pid_to_str (ptid_of (lp)), - target_signal_to_string (signo)); + gdb_signal_to_string (signo)); return 0; } else if (!program_signals_p @@ -1124,7 +1124,7 @@ get_detach_signal (struct thread_info *thread) "GPS: lwp %s had signal %s, " "but we don't know if we should pass it. Default to not.\n", target_pid_to_str (ptid_of (lp)), - target_signal_to_string (signo)); + gdb_signal_to_string (signo)); return 0; } else @@ -1133,7 +1133,7 @@ get_detach_signal (struct thread_info *thread) fprintf (stderr, "GPS: lwp %s has pending signal %s: delivering it.\n", target_pid_to_str (ptid_of (lp)), - target_signal_to_string (signo)); + gdb_signal_to_string (signo)); return WSTOPSIG (status); } @@ -2265,7 +2265,7 @@ linux_stabilize_threads (void) if (ourstatus.value.sig != TARGET_SIGNAL_0 || current_inferior->last_resume_kind == resume_stop) { - wstat = W_STOPCODE (target_signal_to_host (ourstatus.value.sig)); + wstat = W_STOPCODE (gdb_signal_to_host (ourstatus.value.sig)); enqueue_one_deferred_signal (lwp, &wstat); } } @@ -2386,7 +2386,7 @@ retry: else { ourstatus->kind = TARGET_WAITKIND_SIGNALLED; - ourstatus->value.sig = target_signal_from_host (WTERMSIG (w)); + ourstatus->value.sig = gdb_signal_from_host (WTERMSIG (w)); if (debug_threads) fprintf (stderr, @@ -2585,7 +2585,7 @@ Check if we're already there.\n", || WSTOPSIG (w) == __SIGRTMIN + 1)) || #endif - (pass_signals[target_signal_from_host (WSTOPSIG (w))] + (pass_signals[gdb_signal_from_host (WSTOPSIG (w))] && !(WSTOPSIG (w) == SIGSTOP && current_inferior->last_resume_kind == resume_stop)))) { @@ -2738,11 +2738,11 @@ Check if we're already there.\n", { /* A thread that has been requested to stop by GDB with vCont;t, but, it stopped for other reasons. */ - ourstatus->value.sig = target_signal_from_host (WSTOPSIG (w)); + ourstatus->value.sig = gdb_signal_from_host (WSTOPSIG (w)); } else { - ourstatus->value.sig = target_signal_from_host (WSTOPSIG (w)); + ourstatus->value.sig = gdb_signal_from_host (WSTOPSIG (w)); } gdb_assert (ptid_equal (step_over_bkpt, null_ptid)); diff --git a/gdb/gdbserver/lynx-low.c b/gdb/gdbserver/lynx-low.c index aaed07d..2c6ed14 100644 --- a/gdb/gdbserver/lynx-low.c +++ b/gdb/gdbserver/lynx-low.c @@ -450,7 +450,7 @@ retry: if (WIFSTOPPED (wstat)) { status->kind = TARGET_WAITKIND_STOPPED; - status->value.integer = target_signal_from_host (WSTOPSIG (wstat)); + status->value.integer = gdb_signal_from_host (WSTOPSIG (wstat)); lynx_debug ("process stopped with signal: %d", status->value.integer); } @@ -463,7 +463,7 @@ retry: else if (WIFSIGNALED (wstat)) { status->kind = TARGET_WAITKIND_SIGNALLED; - status->value.integer = target_signal_from_host (WTERMSIG (wstat)); + status->value.integer = gdb_signal_from_host (WTERMSIG (wstat)); lynx_debug ("process terminated with code: %d", status->value.integer); } @@ -473,7 +473,7 @@ retry: in fact get here. But if we do, handle the event the best we can. */ status->kind = TARGET_WAITKIND_STOPPED; - status->value.integer = target_signal_from_host (0); + status->value.integer = gdb_signal_from_host (0); lynx_debug ("unknown event ????"); } diff --git a/gdb/gdbserver/nto-low.c b/gdb/gdbserver/nto-low.c index bfff825..22cd612 100644 --- a/gdb/gdbserver/nto-low.c +++ b/gdb/gdbserver/nto-low.c @@ -550,7 +550,7 @@ nto_wait (ptid_t ptid, TRACE (" SIGNALLED\n"); ourstatus->kind = TARGET_WAITKIND_STOPPED; ourstatus->value.sig = - target_signal_from_host (status.info.si_signo); + gdb_signal_from_host (status.info.si_signo); nto_inferior.exit_signo = ourstatus->value.sig; break; case _DEBUG_WHY_FAULTED: @@ -564,7 +564,7 @@ nto_wait (ptid_t ptid, else { ourstatus->value.sig = - target_signal_from_host (status.info.si_signo); + gdb_signal_from_host (status.info.si_signo); nto_inferior.exit_signo = ourstatus->value.sig; } break; diff --git a/gdb/gdbserver/server.c b/gdb/gdbserver/server.c index b3d1b41..9b8107e 100644 --- a/gdb/gdbserver/server.c +++ b/gdb/gdbserver/server.c @@ -1935,9 +1935,9 @@ handle_v_cont (char *own_buf) goto err; p = q; - if (!target_signal_to_host_p (sig)) + if (!gdb_signal_to_host_p (sig)) goto err; - resume_info[i].sig = target_signal_to_host (sig); + resume_info[i].sig = gdb_signal_to_host (sig); } else { @@ -3213,8 +3213,8 @@ process_serial_event (void) case 'C': require_running (own_buf); convert_ascii_to_int (own_buf + 1, &sig, 1); - if (target_signal_to_host_p (sig)) - signal = target_signal_to_host (sig); + if (gdb_signal_to_host_p (sig)) + signal = gdb_signal_to_host (sig); else signal = 0; myresume (own_buf, 0, signal); @@ -3222,8 +3222,8 @@ process_serial_event (void) case 'S': require_running (own_buf); convert_ascii_to_int (own_buf + 1, &sig, 1); - if (target_signal_to_host_p (sig)) - signal = target_signal_to_host (sig); + if (gdb_signal_to_host_p (sig)) + signal = gdb_signal_to_host (sig); else signal = 0; myresume (own_buf, 1, signal); @@ -3476,7 +3476,7 @@ handle_target_event (int err, gdb_client_data client_data) resume_info.thread = last_ptid; resume_info.kind = resume_continue; - resume_info.sig = target_signal_to_host (last_status.value.sig); + resume_info.sig = gdb_signal_to_host (last_status.value.sig); (*the_target->resume) (&resume_info, 1); } else if (debug_threads) diff --git a/gdb/gdbserver/spu-low.c b/gdb/gdbserver/spu-low.c index 1ecd60c..f3a5645 100644 --- a/gdb/gdbserver/spu-low.c +++ b/gdb/gdbserver/spu-low.c @@ -455,7 +455,7 @@ spu_wait (ptid_t ptid, struct target_waitstatus *ourstatus, int options) { fprintf (stderr, "\nChild terminated with signal = %x \n", WTERMSIG (w)); ourstatus->kind = TARGET_WAITKIND_SIGNALLED; - ourstatus->value.sig = target_signal_from_host (WTERMSIG (w)); + ourstatus->value.sig = gdb_signal_from_host (WTERMSIG (w)); clear_inferiors (); return pid_to_ptid (ret); } @@ -470,7 +470,7 @@ spu_wait (ptid_t ptid, struct target_waitstatus *ourstatus, int options) } ourstatus->kind = TARGET_WAITKIND_STOPPED; - ourstatus->value.sig = target_signal_from_host (WSTOPSIG (w)); + ourstatus->value.sig = gdb_signal_from_host (WSTOPSIG (w)); return ptid_build (ret, ret, 0); } diff --git a/gdb/gdbserver/target.c b/gdb/gdbserver/target.c index 998d6c1..7539476 100644 --- a/gdb/gdbserver/target.c +++ b/gdb/gdbserver/target.c @@ -87,8 +87,8 @@ mywait (ptid_t ptid, struct target_waitstatus *ourstatus, int options, "\nChild exited with status %d\n", ourstatus->value.integer); else if (ourstatus->kind == TARGET_WAITKIND_SIGNALLED) fprintf (stderr, "\nChild terminated with signal = 0x%x (%s)\n", - target_signal_to_host (ourstatus->value.sig), - target_signal_to_name (ourstatus->value.sig)); + gdb_signal_to_host (ourstatus->value.sig), + gdb_signal_to_name (ourstatus->value.sig)); if (connected_wait) server_waiting = 0; @@ -157,11 +157,11 @@ target_waitstatus_to_string (const struct target_waitstatus *ws) break; case TARGET_WAITKIND_STOPPED: sprintf (buf, "%sstopped, signal = %s", - kind_str, target_signal_to_name (ws->value.sig)); + kind_str, gdb_signal_to_name (ws->value.sig)); break; case TARGET_WAITKIND_SIGNALLED: sprintf (buf, "%ssignalled, signal = %s", - kind_str, target_signal_to_name (ws->value.sig)); + kind_str, gdb_signal_to_name (ws->value.sig)); break; case TARGET_WAITKIND_LOADED: sprintf (buf, "%sloaded", kind_str); diff --git a/gdb/gdbserver/target.h b/gdb/gdbserver/target.h index dcf0230..0cf5687 100644 --- a/gdb/gdbserver/target.h +++ b/gdb/gdbserver/target.h @@ -53,7 +53,7 @@ struct thread_resume thread. If stopping a thread, and this is 0, the target should stop the thread however it best decides to (e.g., SIGSTOP on linux; SuspendThread on win32). This is a host signal value (not - enum target_signal). */ + enum gdb_signal). */ int sig; }; @@ -97,7 +97,7 @@ struct target_waitstatus union { int integer; - enum target_signal sig; + enum gdb_signal sig; ptid_t related_pid; char *execd_pathname; } diff --git a/gdb/gdbserver/win32-low.c b/gdb/gdbserver/win32-low.c index 315d449..86e7e35 100644 --- a/gdb/gdbserver/win32-low.c +++ b/gdb/gdbserver/win32-low.c @@ -74,7 +74,7 @@ static int attaching = 0; static HANDLE current_process_handle = NULL; static DWORD current_process_id = 0; static DWORD main_thread_id = 0; -static enum target_signal last_sig = TARGET_SIGNAL_0; +static enum gdb_signal last_sig = TARGET_SIGNAL_0; /* The current debug event from WaitForDebugEvent. */ static DEBUG_EVENT current_event; @@ -806,7 +806,7 @@ static void win32_resume (struct thread_resume *resume_info, size_t n) { DWORD tid; - enum target_signal sig; + enum gdb_signal sig; int step; win32_thread_info *th; DWORD continue_status = DBG_CONTINUE; |