Commit Graph

4 Commits

Author SHA1 Message Date
Simon Marchi 04248ead1f gdbserver arm: Add casts
Trivial casts for C++.

Fixes things like

In file included from /home/simark/src/binutils-gdb/gdb/gdbserver/../common/common-defs.h:39:0,
                 from /home/simark/src/binutils-gdb/gdb/gdbserver/server.h:22,
                 from /home/simark/src/binutils-gdb/gdb/gdbserver/linux-arm-low.c:19:
/home/simark/src/binutils-gdb/gdb/gdbserver/linux-arm-low.c: In function ‘int arm_get_hwcap(long unsigned int*)’:
/home/simark/src/binutils-gdb/gdb/gdbserver/../../include/libiberty.h:711:38: error: invalid conversion from ‘void*’ to ‘unsigned char*’ [-fpermissive]
 # define alloca(x) __builtin_alloca(x)
                                      ^
/home/simark/src/binutils-gdb/gdb/gdbserver/linux-arm-low.c:807:25: note: in expansion of macro ‘alloca’
   unsigned char *data = alloca (8);
                         ^

gdb/gdbserver/ChangeLog:

	* linux-aarch32-low.c (arm_fill_gregset): Add cast.
	(arm_store_gregset): Likewise.
	* linux-arm-low.c (arm_get_hwcap): Likewise.
	(arm_read_description): Likewise.
2015-11-03 13:33:13 -05:00
Simon Marchi 04b3479c3f linux-aarch32-low.c: Use NULL_REGSET
Fixes

/home/simark/src/binutils-gdb/gdb/gdbserver/linux-aarch32-low.c:124:1: error: invalid conversion from ‘int’ to ‘regset_type’ [-fpermissive]
 };
 ^

gdb/gdbserver/ChangeLog:

	* linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
2015-11-03 13:33:12 -05:00
Joel Brobecker 16d5f64295 gdbserver/linux-aarch32-low: build failure when NT_ARM_VFP not defined
On some older versions of GNU/Linux, gdbserver now fails to build
due to an undefined reference to NT_ARM_VFP. Same issue on Android,
where this macros is undefined until Android API level 21 (Android
5.0 "Lollipop").

This patch modifies linux-aarch32-low.c to define that macros when
not already defined.

gdb/gdbserver/ChangeLog:

        * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
2015-08-18 18:41:31 -04:00
Yao Qi bd9e6534b7 New regs_info for aarch32
This patch adds a new regs_info regs_info_aarch32 for aarch32, which
can be used by both aarch64 and arm backend.

gdb/gdbserver:

2015-08-04  Yao Qi  <yao.qi@linaro.org>

	* configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
	* linux-aarch32-low.c: New file.
	* linux-aarch32-low.h: New file.
	* linux-arm-low.c (arm_fill_gregset): Move it to
	linux-aarch32-low.c.
	(arm_store_gregset): Likewise.
	(arm_fill_vfpregset): Call arm_fill_vfpregset_num
	(arm_store_vfpregset): Caa arm_store_vfpregset_num.
	(arm_arch_setup): Check if PTRACE_GETREGSET works.
	(regs_info): Rename to regs_info_arm.
	(arm_regs_info): Return regs_info_aarch32 if
	have_ptrace_getregset is 1 and target description is
	arm_with_neon or arm_with_vfpv3.
	(initialize_low_arch): Don't call init_registers_arm_with_neon.
	Call initialize_low_arch_aarch32 instead.
2015-08-04 14:34:14 +01:00