提交 d941fba0 编写于 作者: M Marcel Apfelbaum 提交者: Peter Maydell

hw/ppc/spapr: simplify usb controller creation logic

Signed-off-by: NMarcel Apfelbaum <marcel@redhat.com>
Reviewed-by: NPaolo Bonzini <pbonzini@redhat.com>
Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: NAlexander Graf <agraf@suse.de>
Message-id: 1420550957-22337-6-git-send-email-marcel@redhat.com
Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
上级 b1c2fb9b
......@@ -1484,9 +1484,10 @@ static void ppc_spapr_init(MachineState *machine)
/* Graphics */
if (spapr_vga_init(phb->bus)) {
spapr->has_graphics = true;
machine->usb |= defaults_enabled();
}
if ((spapr->has_graphics && defaults_enabled()) || usb_enabled()) {
if (machine->usb) {
pci_create_simple(phb->bus, -1, "pci-ohci");
if (spapr->has_graphics) {
usbdevice_create("keyboard");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册