]> Git Repo - qemu.git/commit
semihosting: add qemu_semihosting_console_inc for SYS_READC
authorKeith Packard <[email protected]>
Mon, 4 Nov 2019 20:42:30 +0000 (12:42 -0800)
committerAlex Bennée <[email protected]>
Thu, 9 Jan 2020 11:41:29 +0000 (11:41 +0000)
commit8de702cb677c8381fb702cae252d6b69aa4c653b
treeccfa04a054ffba8c063c4c67da4fb8f6760f1531
parent4ff5ef9e911c670ca10cdd36dd27c5395ec2c753
semihosting: add qemu_semihosting_console_inc for SYS_READC

Provides a blocking call to read a character from the console using
semihosting.chardev, if specified. This takes some careful command
line options to use stdio successfully as the serial ports, monitor
and semihost all want to use stdio. Here's a sample set of command
line options which share stdio between semihost, monitor and serial
ports:

qemu \
-chardev stdio,mux=on,id=stdio0 \
-serial chardev:stdio0 \
-semihosting-config enable=on,chardev=stdio0 \
-mon chardev=stdio0,mode=readline

This creates a chardev hooked to stdio and then connects all of the
subsystems to it. A shorter mechanism would be good to hear about.

Signed-off-by: Keith Packard <[email protected]>
Message-Id: <20191104204230[email protected]>
[AJB: fixed up deadlock, minor commit title reword]
Signed-off-by: Alex Bennée <[email protected]>
Cc: Paolo Bonzini <[email protected]>
Reviewed-by: Keith Packard <[email protected]>
Tested-by: Keith Packard <[email protected]>
Reviewed-by: Richard Henderson <[email protected]>
hw/semihosting/console.c
include/hw/semihosting/console.h
include/hw/semihosting/semihost.h
linux-user/arm/semihost.c
stubs/semihost.c
target/arm/arm-semi.c
vl.c
This page took 0.029674 seconds and 4 git commands to generate.