| Index: gdb/gdbserver/spu-low.c
|
| diff --git a/gdb/gdbserver/spu-low.c b/gdb/gdbserver/spu-low.c
|
| index 2a720ae252c986e770f7dc5f4b196ac36c752614..d7283a9703f90d215ec1aa4f8181a5e5df158a43 100644
|
| --- a/gdb/gdbserver/spu-low.c
|
| +++ b/gdb/gdbserver/spu-low.c
|
| @@ -206,14 +206,14 @@ store_ppc_memory (CORE_ADDR memaddr, char *myaddr, int len)
|
| static int
|
| parse_spufs_run (int *fd, CORE_ADDR *addr)
|
| {
|
| - char buf[4];
|
| + unsigned int insn;
|
| CORE_ADDR pc = fetch_ppc_register (32); /* nip */
|
|
|
| /* Fetch instruction preceding current NIP. */
|
| - if (fetch_ppc_memory (pc-4, buf, 4) != 0)
|
| + if (fetch_ppc_memory (pc-4, (char *) &insn, 4) != 0)
|
| return 0;
|
| /* It should be a "sc" instruction. */
|
| - if (*(unsigned int *)buf != INSTR_SC)
|
| + if (insn != INSTR_SC)
|
| return 0;
|
| /* System call number should be NR_spu_run. */
|
| if (fetch_ppc_register (0) != NR_spu_run)
|
| @@ -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);
|
| }
|
| @@ -465,12 +465,12 @@ spu_wait (ptid_t ptid, struct target_waitstatus *ourstatus, int options)
|
| if (!server_waiting)
|
| {
|
| ourstatus->kind = TARGET_WAITKIND_STOPPED;
|
| - ourstatus->value.sig = TARGET_SIGNAL_0;
|
| + ourstatus->value.sig = GDB_SIGNAL_0;
|
| return ptid_build (ret, ret, 0);
|
| }
|
|
|
| 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);
|
| }
|
|
|
|
|