qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH] functional ARM semihosting under GDB


From: Liviu Ionescu
Subject: [Qemu-devel] [PATCH] functional ARM semihosting under GDB
Date: Fri, 14 Nov 2014 01:55:53 +0200

The shortcomings addressed by this patch:
- the semihosting trace messages disapeared when the GDB session was started
- the semihosting exit code was not passed back to the host
- the semihosting command line was not passed properly, because it generated a
very large string, including the image full path
- the stelaris/armv7m code did not pass the semihosting command line at all
- the GDB use case, although allowed the image to be loaded via GDB, it still
required the presence of the -kernel option on the command line
- the -kernel option was not appropriate for usual applications


The behaviour of semihosting code was enhanced, to select at run-time where
the semihosting calls will be forwarded.

For this a new command line option was added:

    -semihosting-target native|gdb|auto

To specify the semihosting command line, the following command was added:

    -semihosting-cmdline args

The application exit code is now passed to the host.

A more generic option was added to specify the application file to be emulated

    -image file-path

If the -gdb option is used, it is no longer mandatory to specify an image file,
since it can be loaded via the GDB "load" command.

The MachineState was propagated from the board initialisation functions up to
armv7m_init().


Liviu Ionescu (1):
  functional ARM semihosting under GDB

 gdbstub.c               | 12 +++++++++++
 hw/arm/armv7m.c         | 27 +++++++++++++++++++-----
 hw/arm/stellaris.c      | 14 +++++--------
 include/hw/arm/arm.h    |  8 ++++---
 include/hw/boards.h     |  1 +
 include/sysemu/sysemu.h |  7 +++++++
 qemu-options.hx         | 42 ++++++++++++++++++++++++++++++++++---
 target-arm/arm-semi.c   | 54 ++++++++++++++++++++++++++++++++++++++++--------
 vl.c                    | 55 ++++++++++++++++++++++++++++++++++++++++++++++---
 9 files changed, 188 insertions(+), 32 deletions(-)

-- 
1.9.3 (Apple Git-50)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]