qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] gdbstub.c gdb-get-register returns 0, breaking remote gdb call
@ 2018-02-13  2:43 Dan Kaminsky
  0 siblings, 0 replies; only message in thread
From: Dan Kaminsky @ 2018-02-13  2:43 UTC (permalink / raw)
  To: qemu-devel

Unsure the scope of this bug or the proper fix, so bringing it up here
first.

gdbstub.c:gdb_read_register will return 0, and thus E14, when a remote gdb
tries to call a function in the exposed linux kernel.  This appears to be
because the caller expects to be able to receive a generic register size by
calling one plus the number of known registers.  However,
x86_cpu_gdb_read_register() in target/i386/gdbstub.c will only provide
register sizes for known registers, since they're not always the same.

I'm dealing with this just by shimming 8 whenever gdb_read_register returns
0, but that's obviously not correct.  Suggestions?

--Dan

P.S.  call still won't work unless linux is launched with noexec=off
noexec32=off, due to NX.

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2018-02-13  2:43 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-02-13  2:43 [Qemu-devel] gdbstub.c gdb-get-register returns 0, breaking remote gdb call Dan Kaminsky

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).