History | View | Annotate | Download (68.1 kB)
sparc: Fix lazy flag calculation on interrupts, refactor
Recalculate Sparc64 CPU flags on interrupts, otherwise some earlierflags could be stored to pstate.
Refactor PSR/CCR/CWP handling: concentrate the actualfunctions to op_helper.c.
Thanks to Igor Kovalenko for reporting....
target-sh4: Fix gdb read/write register
cpu_gdb_read_register(): Fix n={8...15} case.cpu_gdb_write_register(): Fix n={8...15} case and runaway "case:".
Signed-off-by: Takashi YOSHII <takasi-y@ops.dti.ne.jp>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Fix to 'gdb detach' stub
With this patch, 'gdb detach' correctly resumes the inferior executionafter detaching the debugger.The bug was caused by qemu asking gdb to execute a syscall (isatty)after the detach, and then waiting (forever) for the reply. I fixed this...
target-alpha: Fix gdb access to fpcr and unique.
cpu_gdb_read/write_register need to access the fpcr via thecpu_alpha_load/store_fpcr functions.
The unique register is number 66 in the gdb remote protocol.
Signed-off-by: Richard Henderson <rth@twiddle.net>...
cris: Add CRISv10 gdbstub support.
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
target-m68k: fix a typo in 'P' packet processing
Attached is a patch to fix a typo in 'P' packet processing for M68K.
Without this patch, QEMU fails to honor GDB's P packets from GDB(writing to registers) for the address registers (A0 - A7).
The problem is because of an obvious typo. Notice that the second...
gdbstub: add MIPS16 support
The only thing to do here is to expose the current processor mode to GDBand to set the processor mode properly when we change the PC.
Signed-off-by: Nathan Froyd <froydnj@codesourcery.com>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
S390 GDB stub
In order to debug funny kernel breakages it's always good to have a workinggdb stub around.
While Uli's patches don't include one one, I needed one that's at least goodenough for 'bt' and some variable examinations during early bootup.
So here it is - the absolute basics to get the qemu gdb stub running with s390x...
Don't leak file descriptors
We're leaking file descriptors to child processes. Set FD_CLOEXEC on filedescriptors that don't need to be passed to children to stop this misbehaviour.
Signed-off-by: Kevin Wolf <kwolf@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
char: rename CHR_EVENT_RESET to CHR_EVENT_OPENED
The char event RESET is emitted when a char device is opened.Give it a better name.
Patchworks-ID: 35287Signed-off-by: Amit Shah <amit.shah@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
gdbstub: x86: Switch 64/32 bit registers dynamically
Commit 56aebc891674cd2d07b3f64183415697be200084 changed gdbstub in waythat debugging 32 or 16-bit guest code is no longer possible with qemufor x86_64 guest CPUs. Since that commit, qemu only provides registers...
gdbstub: fix coding style nit
Put space between = and * when dereferencing a pointer,to avoid confusion with old-style "*="
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
kvm: Simplify cpu_synchronize_state()
cpu_synchronize_state() is a little unreadable since the 'modified'argument isn't self-explanatory. Simplify it by making it alwayssynchronize the kernel state into qemu, and automatically flush theregisters back to the kernel if they've been synchronized on this...
rename USE_NPTL to CONFIG_USE_NPTL
Signed-off-by: Juan Quintela <quintela@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Update to a hopefully more future proof FSF address
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
gdbstub: Add vCont support
This patch adds support for the vCont remote gdb command. It is used bygdb 6.8 or better to switch the debugging focus for single-steppingmulti-threaded targets, ie. multi-threaded application in user modeemulation or VCPUs in system emulation....
gdbstub: x86: Refactor register access
Clarify gdb's register set layout by using constants forcpu_gdb_read/write_register.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
gdbstub: x86: Support for setting segment registers
This allows to set segment registers via gdb also in system emulationmode. Basic sanity checks are applied and nothing is changed if theyfail. But screwing up the target via this interface will never be...
fix gdbstub support for multiple threads in usermode, v3
When debugging multi-threaded programs, QEMU's gdb stub would report thecorrect number of threads (the qfThreadInfo and qsThreadInfo packets).However, the stub was unable to actually switch between threads (the T...
microblaze: Add GDB stub support.
Add 'static' to avoid a sparse warning
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7175 c046a42c-6fe2-441c-8c8c-71466251a162
Fix ppc-softmmu warnings on OpenBSD host
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7099 c046a42c-6fe2-441c-8c8c-71466251a162
factor out setting pc in gdbstub
The code for handling the c and s packets both contain code for settingthe pc. Move that code out to a common function.
Signed-off-by: Nathan Froyd <froydnj@codesourcery.com>Acked-by: Jan Kiszka <jan.kiszka@siemens.com>...
gdbstub: Rework configuration via command line and monitor (Jan Kiszka)
Introduce a more canonical gdbstub configuration (system emulation only)via the new switch '-gdb dev'. Keep '-s' as shorthand for'-gdb tcp::1234'. Use the same syntax also for the corresponding monitor...
gdbstub: Allow re-instantiation (Jan Kiszka)
[ Note: depends on char closing fixes ]
Properly clean up the gdbstub when the user tries to re-open it(possibly under a different address). Moreover, allow to shut it downfrom the monitor via 'gdbserver none'....
gdbstub: Drop redundant memset after qemu_mallocz (Jan Kiszka)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6897 c046a42c-6fe2-441c-8c8c-71466251a162
Guest debugging support for KVM (Jan Kiszka)
This is a backport of the guest debugging support for the KVMaccelerator that is now part of the KVM tree. It implements the reworkedKVM kernel API for guest debugging (KVM_CAP_SET_GUEST_DEBUG) which isnot yet part of any mainline kernel but will probably be 2.6.30 stuff....
Use a dedicated function to request exit from execution loop
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6762 c046a42c-6fe2-441c-8c8c-71466251a162
Fix BSD user
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6734 c046a42c-6fe2-441c-8c8c-71466251a162
monitor: Pass-through for gdbstub (Jan Kiszka)
Create a monitor terminal and pass it through the gdbstub. This allowsto use gdb's monitor command to access the QEMU monitor. Works for allcommands except for non-detached migration and password retrieval (user...
toplevel: remove error handling from qemu_malloc() callers (Avi Kivity)
Signed-off-by: Avi Kivity <avi@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6531 c046a42c-6fe2-441c-8c8c-71466251a162
target-ppc: Change core powerpc gdbstub bits to be XML-aware
Define GDB_CORE_XML and hack things similarly to ARM so that despite theFP registers coming in between the GPRs and some status registers,everything works out OK no matter which kind of GDB we're communicating...
Rework vm_state_change notifiers (Jan Kiszka)
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6402 c046a42c-6fe2-441c-8c8c-71466251a162
add an init function parameter to qemu_chr_open()
And use it for the malta emulation. Fix segfault introduced inrevision 6352.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6365 c046a42c-6fe2-441c-8c8c-71466251a162
Fix bsd-user build
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6312 c046a42c-6fe2-441c-8c8c-71466251a162
Fix gdbserver number of registers (Tristan Gingold)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6280 c046a42c-6fe2-441c-8c8c-71466251a162
gdbstub: fix gdbserver_fork
As reported by Martin Mohring fork doesn't work with NPTL.A fix is attached that makes the also attached test run(tested with ARM CodeSourcery 2008q3 on an x86_64Fedora Core with kernel 2.6.23).
Signed-off-by: Laurent Desnogues <laurent.desnogues@gmail.com>...
Update FSF address in GPL/LGPL boilerplate
The attached patch updates the FSF address in the GPL/LGPL boilerplatein most GPL/LGPLed files, and also in COPYING.LIB.
Signed-off-by: Stuart Brady <stuart.brady@gmail.com>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>...
User-mode GDB stub improvements - handle signals
Handle signals in the user-mode GDB stub. Report them to GDB, andallow it to change or cancel them. Also correct the protocol numbering;it happens to match Linux numbering for SIGINT and SIGTRAP, but that's...
User-mode GDB stub improvements - handle fork
Close gdbserver in child processes, so that only one stub tries to talkto GDB at a time. Updated from an earlier patch by Paul Brook.
Signed-off-by: Daniel Jacobowitz <dan@codesourcery.com>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>...
target-alpha: gdb-stub support
(Vince Weaver)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5945 c046a42c-6fe2-441c-8c8c-71466251a162
gdbstub: kill a warning
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5943 c046a42c-6fe2-441c-8c8c-71466251a162
Fix some new warnings introduced after r5022
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5933 c046a42c-6fe2-441c-8c8c-71466251a162
gdbstub: Fix access to PPC FPRs
Obviously, someone forgot to rebase the index before accessing one ofthe 32 FPRs.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5821 c046a42c-6fe2-441c-8c8c-71466251a162
gdbstub: manage CPUs as threads (Jan Kiszka)
This patch enhances QEMU's built-in debugger for SMP guest debugging.Using the thread support of the gdb remote protocol, each VCPU is mappedon a pseudo thread and exposed to the gdb frontend. This way you can...
Refactor and enhance break/watchpoint API (Jan Kiszka)
This patch prepares the QEMU cpu_watchpoint/breakpoint API to allow thesucceeding enhancements this series comes with.
First of all, it overcomes MAX_BREAKPOINTS/MAX_WATCHPOINTS by switchingto dynamically allocated data structures that are kept in linked lists....
gdbstub: Return appropriate watch message to gdb (Jan Kiszka)
Return the appropriate type prefix (r, a, none) when reportingwatchpoint hits to the gdb front-end.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>...
Implement "info chardev" command. (Gerd Hoffmann)
This patch makes qemu keep track of the character devices in use andimplements a "info chardev" monitor command to print a list.
qemu_chr_open() sticks the devices into a linked list now. It got a newargument (label), so there is a name for each device. It also assigns a...
Use snprintf to please OpenBSD linker
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5529 c046a42c-6fe2-441c-8c8c-71466251a162
target-ppc: Convert XER accesses to TCG
Define XER bits as a single register and access them individually toavoid defining 5 32-bit registers (TCG doesn't permit to map 8-bitregisters).
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5500 c046a42c-6fe2-441c-8c8c-71466251a162
gdbstub: remove unused local variable
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5489 c046a42c-6fe2-441c-8c8c-71466251a162
CRIS: Handle GDB writes to pregs.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5461 c046a42c-6fe2-441c-8c8c-71466251a162
Add GDB XML register description support.
Signed-off-by: Paul Brook <paul@codesourcery.com>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5459 c046a42c-6fe2-441c-8c8c-71466251a162
Move the active FPU registers into env again, and use more TCG registersto access them.
Signed-off-by: Thiemo Seufer <ths@networkno.de>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5252 c046a42c-6fe2-441c-8c8c-71466251a162
Fix warnings that would be caused by gcc flag -Wwrite-strings
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5206 c046a42c-6fe2-441c-8c8c-71466251a162
Fix OpenBSD linker warnings
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5044 c046a42c-6fe2-441c-8c8c-71466251a162
More efficient target register / TC accesses.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4794 c046a42c-6fe2-441c-8c8c-71466251a162
Clean up MMIO TLB handling.The IO index is now stored in its own field, instead of being wedgedinto the vaddr field. This eliminates the ROMD and watchpoint hostpointer weirdness. The IO index space is expanded by 1 bit, andseveral additional bits are made available in the TLB vaddr field....
Fix Sparc32plus GDBstub support
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4689 c046a42c-6fe2-441c-8c8c-71466251a162
Support signal reception in user-mode. Handle when the peer terminates or aborts the connection.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4483 c046a42c-6fe2-441c-8c8c-71466251a162
Add support for the 'k' (kill) and 'D' (detach) packets (Jason Wessel).
Implement the 'k' gdbserial packet which kills the qemu instance viathe debugger stub.
Implement the 'D' detach packet for the gdb stub such that you candisconnect gdb with the "detach" command. This required implementing...
x86_64 and better i386 support
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4394 c046a42c-6fe2-441c-8c8c-71466251a162
Remove x86-64 specific reg fillers.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4392 c046a42c-6fe2-441c-8c8c-71466251a162
Debugger single step without interrupts (Jason Wessel).
This patch allows the qemu backend debugger to single step aninstruction without running the hardware interrupts.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4391 c046a42c-6fe2-441c-8c8c-71466251a162
Add x86_64 gdb stub for qemu (Jason Wessel).
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4390 c046a42c-6fe2-441c-8c8c-71466251a162
Improve readability by moving the continue operation into aseparate function.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4059 c046a42c-6fe2-441c-8c8c-71466251a162
More consistent naming for CRIS register-number macros.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3996 c046a42c-6fe2-441c-8c8c-71466251a162
Make MIPS MT implementation more cache friendly.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3981 c046a42c-6fe2-441c-8c8c-71466251a162
Fix char* signedness, by Andre Przywara.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3816 c046a42c-6fe2-441c-8c8c-71466251a162
Fix wrong signedness, by Andre Przywara.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3815 c046a42c-6fe2-441c-8c8c-71466251a162
Break up vl.h.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3674 c046a42c-6fe2-441c-8c8c-71466251a162
Fix format mismatch.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3589 c046a42c-6fe2-441c-8c8c-71466251a162
x86_64 support in cpu_gdb_read_registers(), by Goran Weinholt.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3491 c046a42c-6fe2-441c-8c8c-71466251a162
Gprof prooved the PowerPC emulation spent too much time in MSR load and storeroutines. Coming back to a raw MSR storage model then speed-up the emulation.Improve fast MSR updates (wrtee wrteei and mtriee cases).Share rfi family instructions helpers code to avoid bug in duplicated code....
Fix gdb stub for MIPS64.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3435 c046a42c-6fe2-441c-8c8c-71466251a162
CRIS support in toplevel, by Edgar E. Iglesias.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3363 c046a42c-6fe2-441c-8c8c-71466251a162
find -type f | xargs sed -i 's/[\t ]*$//g' # Yes, again. Note the star in the regex.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3177 c046a42c-6fe2-441c-8c8c-71466251a162
find -type f | xargs sed -i 's/[\t ]$//g' # on most files
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3173 c046a42c-6fe2-441c-8c8c-71466251a162
Partial support for 34K multithreading, not functional yet.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3156 c046a42c-6fe2-441c-8c8c-71466251a162
Ensure string is properly terminated.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3113 c046a42c-6fe2-441c-8c8c-71466251a162
Improve handling of gdb's single-step / continue arguments.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3075 c046a42c-6fe2-441c-8c8c-71466251a162
Spelling fixes, by Stefan Weil.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3066 c046a42c-6fe2-441c-8c8c-71466251a162
Report normalised CWP values to userland and GDB, not internal representation
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3052 c046a42c-6fe2-441c-8c8c-71466251a162
Proper target format for qOffsets.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2934 c046a42c-6fe2-441c-8c8c-71466251a162
GDB stub for MIPS64, by Jason Wessel.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2909 c046a42c-6fe2-441c-8c8c-71466251a162
M68k system mode semihosting.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2861 c046a42c-6fe2-441c-8c8c-71466251a162
Add fpu register support to the gdb code, by Magnus Damm.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2817 c046a42c-6fe2-441c-8c8c-71466251a162
MIPS 64-bit FPU support, plus some collateral bugfixes in theconditional branch handling.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2779 c046a42c-6fe2-441c-8c8c-71466251a162
Fix format specified for watchpoint address.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2667 c046a42c-6fe2-441c-8c8c-71466251a162
Fix Sparc64 double float gdb protocol (initial version by Paul Brook)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2666 c046a42c-6fe2-441c-8c8c-71466251a162
Watchpoint support (previous commit got eaten by Savannah server crash).
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2479 c046a42c-6fe2-441c-8c8c-71466251a162
Great PowerPC emulation code resynchronisation and improvments:- Add status file to make regression tracking easier- Move all micro-operations helpers definitions into a separate header: should never be seen outside of op.c- Update copyrights- Add new / missing PowerPC CPU definitions...
MIPS FPU dynamic activation, part 1, by Herve Poussineau.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2463 c046a42c-6fe2-441c-8c8c-71466251a162
Allow gdbstub to connect over any serial device.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2448 c046a42c-6fe2-441c-8c8c-71466251a162
gdbserver fix
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2393 c046a42c-6fe2-441c-8c8c-71466251a162
GDB hosted syscalls.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2364 c046a42c-6fe2-441c-8c8c-71466251a162
Use standard character device interface for gdbstub.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2363 c046a42c-6fe2-441c-8c8c-71466251a162
Don't resume guest when gdb connection terminates and -S specified.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2343 c046a42c-6fe2-441c-8c8c-71466251a162
Darwin userspace emulation, by Pierre d'Herbemont.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2332 c046a42c-6fe2-441c-8c8c-71466251a162
MIPS FPU support for the gdb stub, by Daniel Jacobowitz.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2242 c046a42c-6fe2-441c-8c8c-71466251a162