diff options
author | Simon Marchi <simon.marchi@ericsson.com> | 2015-07-29 17:15:46 -0400 |
---|---|---|
committer | Simon Marchi <simon.marchi@ericsson.com> | 2015-07-29 17:16:20 -0400 |
commit | aa58a496ed9a3ee19233af0bfb7c76ae02b9b2c1 (patch) | |
tree | c94a3c3648b5940b782e7496361a36b203d11aae /gdb/gdbserver | |
parent | d618e4c51c73f2139a1aa8903d677a4202956f21 (diff) | |
download | binutils-gdb-aa58a496ed9a3ee19233af0bfb7c76ae02b9b2c1.tar.gz |
MIPS ptrace build fixes
Since Pedro's ptrace cleanups, the MIPS buildbot compilation fails.
Code in MIPS native uses ptrace with 3 arguments, where ptrace requires
4. When looking at the definition of ptrace in
/usr/include/sys/ptrace.h, it shows that it takes a variable number of
arguments. The wrapper macro in nat/gdb_ptrace.h takes a fixed number
of arguments (4). That would explain why it used to work and stopped.
I am pushing this as obvious, tell me if there is any problem.
I built-tested this with a MIPS toolchain (ct-ng), but I don't have any
setup to test it. At least it should put back the buildbot builder in a
better shape.
gdb/ChangeLog:
* mips-linux-nat.c (write_watchpoint_regs): Add NULL as ptrace's 4th
parameter.
(mips_linux_new_thread): Likewise.
* nat/mips-linux-watch.c (mips_linux_read_watch_registers): Likewise.
gdb/gdbserver/ChangeLog:
* linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
ptrace's 4th parameter.
Diffstat (limited to 'gdb/gdbserver')
-rw-r--r-- | gdb/gdbserver/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/gdbserver/linux-mips-low.c | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/gdb/gdbserver/ChangeLog b/gdb/gdbserver/ChangeLog index 5b4236a9ab1..2e039b5479e 100644 --- a/gdb/gdbserver/ChangeLog +++ b/gdb/gdbserver/ChangeLog @@ -1,3 +1,8 @@ +2015-07-29 Simon Marchi <simon.marchi@ericsson.com> + + * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as + ptrace's 4th parameter. + 2015-07-27 Yao Qi <yao.qi@linaro.org> * configure.srv (case aarch64*-*-linux*): Don't set diff --git a/gdb/gdbserver/linux-mips-low.c b/gdb/gdbserver/linux-mips-low.c index d3b01d61f95..770f0df52d5 100644 --- a/gdb/gdbserver/linux-mips-low.c +++ b/gdb/gdbserver/linux-mips-low.c @@ -427,7 +427,7 @@ mips_linux_prepare_to_resume (struct lwp_info *lwp) int tid = ptid_get_lwp (ptid); if (-1 == ptrace (PTRACE_SET_WATCH_REGS, tid, - &priv->watch_mirror)) + &priv->watch_mirror, NULL)) perror_with_name ("Couldn't write watch register"); } |