mirror of
git://git.yoctoproject.org/poky.git
synced 2025-07-19 12:59:02 +02:00
runqemu: add qmp socket support
Add support for qmp sockets and defaults to unix:qmp.sock if unspecified (From OE-Core rev: 380631797f0d63124a8c21efa93ab672dbd79283) Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Eilís 'pidge' Ní Fhlannagáin <pidge@baylibre.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
parent
524255ad26
commit
942f0909f3
|
@ -84,6 +84,7 @@ of the following environment variables (in any order):
|
|||
publicvnc - enable a VNC server open to all hosts
|
||||
audio - enable audio
|
||||
guestagent - enable guest agent communication
|
||||
qmp=<path> - create a QMP socket (defaults to unix:qmp.sock if unspecified)
|
||||
[*/]ovmf* - OVMF firmware file or base name for booting with UEFI
|
||||
tcpserial=<port> - specify tcp serial port number
|
||||
qemuparams=<xyz> - specify custom parameters to QEMU
|
||||
|
@ -221,6 +222,7 @@ class BaseConfig(object):
|
|||
self.cleaned = False
|
||||
# Files to cleanup after run
|
||||
self.cleanup_files = []
|
||||
self.qmp = None
|
||||
self.guest_agent = False
|
||||
self.guest_agent_sockpath = '/tmp/qga.sock'
|
||||
|
||||
|
@ -536,6 +538,10 @@ to your build configuration.
|
|||
self.qemu_opt_script += ' -vnc :0'
|
||||
elif arg == 'guestagent':
|
||||
self.guest_agent = True
|
||||
elif arg == "qmp":
|
||||
self.qmp = "unix:qmp.sock"
|
||||
elif arg.startswith("qmp="):
|
||||
self.qmp = arg[len('qmp='):]
|
||||
elif arg.startswith('guestagent-sockpath='):
|
||||
self.guest_agent_sockpath = '%s' % arg[len('guestagent-sockpath='):]
|
||||
elif arg.startswith('tcpserial='):
|
||||
|
@ -1406,6 +1412,10 @@ to your build configuration.
|
|||
self.qemu_opt += ' -device virtio-serial '
|
||||
self.qemu_opt += ' -device virtserialport,chardev=qga0,name=org.qemu.guest_agent.0 '
|
||||
|
||||
def setup_qmp(self):
|
||||
if self.qmp:
|
||||
self.qemu_opt += " -qmp %s,server,nowait" % self.qmp
|
||||
|
||||
def setup_vga(self):
|
||||
if self.nographic == True:
|
||||
if self.sdl == True:
|
||||
|
@ -1547,6 +1557,7 @@ to your build configuration.
|
|||
self.qemu_opt += " -snapshot"
|
||||
|
||||
self.setup_guest_agent()
|
||||
self.setup_qmp()
|
||||
self.setup_serial()
|
||||
self.setup_vga()
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user