]> Git Repo - qemu.git/commit
python/qemu: Add ConsoleSocket for optional use in QEMUMachine
authorRobert Foley <[email protected]>
Wed, 1 Jul 2020 13:56:24 +0000 (14:56 +0100)
committerAlex Bennée <[email protected]>
Sat, 11 Jul 2020 14:53:00 +0000 (15:53 +0100)
commit0fc8f660c5c0d7b4513805f4798e97e4c371e486
tree6746a8c269a2fdae2d4a8a3dbcd46e0512c6a7cf
parentdf00168039c8a58db3c33456db2c00da51043ee2
python/qemu: Add ConsoleSocket for optional use in QEMUMachine

We add the ConsoleSocket object, which has a socket interface
and which will consume all arriving characters on the
socket, placing them into an in memory buffer.
This will also provide those chars via recv() as
would a regular socket.
ConsoleSocket also has the option of dumping
the console bytes to a log file.

We also give QEMUMachine the option of using ConsoleSocket
to drain and to use for logging console to a file.
By default QEMUMachine does not use ConsoleSocket.

This is added in preparation for use by basevm.py in a later commit.
This is a workaround we found was needed for basevm.py since
there is a known issue where QEMU will hang waiting
for console characters to be consumed.

Cc: Eduardo Habkost <[email protected]>
Cc: Cleber Rosa <[email protected]>
Signed-off-by: Robert Foley <[email protected]>
Reviewed-by: Peter Puhov <[email protected]>
Acked-by: Alex Bennée <[email protected]>
Tested-by: Philippe Mathieu-Daudé <[email protected]>
Signed-off-by: Alex Bennée <[email protected]>
Message-Id: <20200601211421[email protected]>
Message-Id: <20200701135652[email protected]>
python/qemu/console_socket.py [new file with mode: 0644]
python/qemu/machine.py
This page took 0.024698 seconds and 4 git commands to generate.