script: Support mouse with build-efi/qemu scripts
Provide arguments to QEMU to enable a mouse. Note that this does not work with EFI at present. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
@@ -112,6 +112,9 @@ class BuildEfi:
|
||||
extra += ['-device', 'qemu-xhci', '-device', 'usb-kbd',
|
||||
'-device', 'usb-tablet']
|
||||
extra += ['-display', 'default,show-cursor=on']
|
||||
else: # x86
|
||||
extra += ['-device', 'qemu-xhci', '-device', 'usb-kbd',
|
||||
'-device', 'usb-tablet']
|
||||
extra += ['-serial', 'mon:stdio']
|
||||
serial_msg = ''
|
||||
if self.args.kvm:
|
||||
|
||||
@@ -274,7 +274,11 @@ class BuildQemu:
|
||||
elif self.args.arch == 'arm':
|
||||
qemu_cmd.extend(['-device', 'virtio-gpu-pci'])
|
||||
qemu_cmd.extend(['-device', 'qemu-xhci', '-device', 'usb-kbd',
|
||||
'-device', 'usb-tablet'])
|
||||
'-device', 'usb-tablet', '-device', 'usb-mouse'])
|
||||
qemu_cmd.extend(['-display', 'default,show-cursor=on'])
|
||||
elif self.args.arch == 'x86':
|
||||
qemu_cmd.extend(['-device', 'qemu-xhci'])
|
||||
qemu_cmd.extend(['-device', 'usb-kbd', '-device', 'usb-tablet'])
|
||||
qemu_cmd.extend(['-display', 'default,show-cursor=on'])
|
||||
if not any(item.startswith('-serial') for item in self.qemu_extra):
|
||||
qemu_cmd.extend(['-serial', 'mon:stdio'])
|
||||
|
||||
Reference in New Issue
Block a user