-----Original Message----- From: Pedro Alves [mailto:palves@redhat.com] Sent: Wednesday, October 15, 2014 6:57 PM To: Ajit Kumar Agarwal; Michael Eager; Joel Brobecker Cc: gdb-patches@sourceware.org; Vinod Kathail; Vidhumouli Hunsigida; Nagaraju Mekala Subject: Re: [Patch] Microblaze: Port of Linux gdbserver On 10/09/2014 07:54 PM, Ajit Kumar Agarwal wrote: > > Pedro: >> > Did this kernel port make it upstream without PTRACE_GETREGSET? >> > If there's support for that, can you please switch to using it? >>> >>Please answer all questions. > Sure. The Kernel code(ptrace.h) for Microblaze doesn't have upstream code without PTRACE_GETREGSET. > > Pedro: >> > PTRACE_GETREGS is supposed to an old way of doing things... >>> >>And address all comments. > The Microblaze Kernel code PTRACE_GETREGS is always defined and there is no conditional compilation which is without the PTRACE_GETREGS. So I agree with Pedro comment of not using #ifdef PTRACE_GETREGS and in the patch submitted I have removed if #ifdef PTRACE_GETREGS which is not required. >>PTRACE_GETREGSET != PTRACE_GETREGS >>I'm asking for using the PTRACE_GETREGSET instead of PTRACE_GETREGS in new ports. See background here: >>https://sourceware.org/ml/archer/2010-q3/msg00193.html The changes are incorporated. >> +#define microblaze_breakpoint_len 4 >> >> Use CAPS for macros. The changes are incorporated. >>+ (*the_target->read_memory) (where, (unsigned char *) &insn, 4); >>+ >>+ if (insn == microblaze_breakpoint) >>Why use the explicit length rather than the macro you just defined? >>Why not use sizeof (insn)? The changes are incorporated. The below patch incorporated all the above feedbacks. [PATCH] Microblaze: Port of Linux gdbserver This patch is the port of Linux gdbserver. Tested with gdb regression testsuite with this patch of gdbserver. gdb/: 2014-10-18 Ajit Agarwal * configure.tgt (build_gdbserver): New Definition. gdb/gdbserver/: * gdbserver/Makefile.in (microblaze-linux.c): New target. * gdbserver/configure.srv (microblaze*-*-linux*): New target. * gdbserver/linux-microblaze-low.c: New file. Signed-off-by:Ajit Agarwal ajitkum@xilinx.com Gdb.base gdb testsuite is run and here is the status of gdb testsuite run for gdb.base. === gdb Summary === # of expected passes 7804 # of unexpected failures 2263 # of unexpected successes 2 # of expected failures 5 # of known failures 22 # of unresolved testcases 29 # of untested testcases 41 # of unsupported tests 125 Thanks & Regards Ajit Thanks, Pedro Alves