summary refs log tree commit diff stats
path: root/hw/ide/atapi.c
diff options
context:
space:
mode:
authorLuiz Capitulino <lcapitulino@redhat.com>2013-04-02 15:07:33 -0400
committerLuiz Capitulino <lcapitulino@redhat.com>2013-04-05 08:42:29 -0400
commit48c043d0d1835c64b571c484a9f229fe6d220287 (patch)
tree44f8e8c78c451dba08412992c0c471b370190479 /hw/ide/atapi.c
parente1f2641b5926d20f63d36f0de45206be774da8da (diff)
downloadfocaccia-qemu-48c043d0d1835c64b571c484a9f229fe6d220287.tar.gz
focaccia-qemu-48c043d0d1835c64b571c484a9f229fe6d220287.zip
hmp: human-monitor-command: stop using the Memory chardev driver
The Memory chardev driver was added because, as the Monitor's output
buffer was static, we needed a way to accumulate the output of an
HMP commmand when ran by human-monitor-command.

However, the Monitor's output buffer is now dynamic, so it's possible
for the human-monitor-command to use it instead of the Memory chardev
driver.

This commit does that change, but there are two important
observations about it:

 1. We need a way to signal to the Monitor that it shouldn't call
    chardev functions when flushing its output. This is done
    by adding a new flag to the Monitor object called skip_flush
	(which is set to true by qmp_human_monitor_command())

 2. The current code has buffered semantics: QMP clients will
    only see a command's output if it flushes its output with
	a new-line character. This commit changes this to unbuffered,
	which means that QMP clients will see a command's output
	whenever the command prints anything.

	I don't think this will matter in practice though, as I believe
	all HMP commands print the new-line character anyway.

Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Acked-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'hw/ide/atapi.c')
0 files changed, 0 insertions, 0 deletions