From: Yao Qi Date: Tue, 4 Aug 2015 13:34:14 +0000 (+0100) Subject: Move have_ptrace_getregset to linux-low.c X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ded48a5ef34314f7af698b7ec7916b084c94b18d;p=binutils-gdb.git Move have_ptrace_getregset to linux-low.c This patch moves variable have_ptrace_getregset from linux-x86-low.c to linux-low.c, so that arm can use it too. gdb/gdbserver: 2015-08-04 Yao Qi * linux-x86-low.c (have_ptrace_getregset): Move it to ... * linux-low.c: ... here. * linux-low.h (have_ptrace_getregset): Declare it. --- diff --git a/gdb/gdbserver/ChangeLog b/gdb/gdbserver/ChangeLog index 443c25e2530..f653d774091 100644 --- a/gdb/gdbserver/ChangeLog +++ b/gdb/gdbserver/ChangeLog @@ -1,3 +1,9 @@ +2015-08-04 Yao Qi + + * linux-x86-low.c (have_ptrace_getregset): Move it to ... + * linux-low.c: ... here. + * linux-low.h (have_ptrace_getregset): Declare it. + 2015-08-04 Pedro Alves * thread-db.c (struct thread_db): Use new typedefs. diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c index 82fb7f9bb25..f1e1d7271d7 100644 --- a/gdb/gdbserver/linux-low.c +++ b/gdb/gdbserver/linux-low.c @@ -139,6 +139,9 @@ typedef struct } Elf64_auxv_t; #endif +/* Does the current host support PTRACE_GETREGSET? */ +int have_ptrace_getregset = -1; + /* LWP accessors. */ /* See nat/linux-nat.h. */ diff --git a/gdb/gdbserver/linux-low.h b/gdb/gdbserver/linux-low.h index 5a3697b7be1..24fb0158d5f 100644 --- a/gdb/gdbserver/linux-low.h +++ b/gdb/gdbserver/linux-low.h @@ -373,3 +373,5 @@ int thread_db_handle_monitor_command (char *); int thread_db_get_tls_address (struct thread_info *thread, CORE_ADDR offset, CORE_ADDR load_module, CORE_ADDR *address); int thread_db_look_up_one_symbol (const char *name, CORE_ADDR *addrp); + +extern int have_ptrace_getregset; diff --git a/gdb/gdbserver/linux-x86-low.c b/gdb/gdbserver/linux-x86-low.c index ec2d9068a0f..73fe6cd56c2 100644 --- a/gdb/gdbserver/linux-x86-low.c +++ b/gdb/gdbserver/linux-x86-low.c @@ -1142,9 +1142,6 @@ int have_ptrace_getfpxregs = #endif ; -/* Does the current host support PTRACE_GETREGSET? */ -static int have_ptrace_getregset = -1; - /* Get Linux/x86 target description from running target. */ static const struct target_desc *