[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 02/10] hw/mips: Improve the default USB settings in the loongson3-
From: |
Philippe Mathieu-Daudé |
Subject: |
[PULL 02/10] hw/mips: Improve the default USB settings in the loongson3-virt machine |
Date: |
Tue, 25 Jul 2023 16:58:21 +0200 |
From: Thomas Huth <thuth@redhat.com>
It's possible to compile QEMU without the USB devices (e.g. when using
"--without-default-devices" as option for the "configure" script).
To be still able to run the loongson3-virt machine in default mode with
such a QEMU binary, we have to check here for the availability of the
OHCI controller first before instantiating the USB devices.
Signed-off-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230714104903.284845-1-thuth@redhat.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
---
hw/mips/loongson3_virt.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/mips/loongson3_virt.c b/hw/mips/loongson3_virt.c
index 4018b8c1d3..3ad0a223df 100644
--- a/hw/mips/loongson3_virt.c
+++ b/hw/mips/loongson3_virt.c
@@ -447,7 +447,7 @@ static inline void loongson3_virt_devices_init(MachineState
*machine,
pci_vga_init(pci_bus);
- if (defaults_enabled()) {
+ if (defaults_enabled() && object_class_by_name("pci-ohci")) {
pci_create_simple(pci_bus, -1, "pci-ohci");
usb_create_simple(usb_bus_find(-1), "usb-kbd");
usb_create_simple(usb_bus_find(-1), "usb-tablet");
--
2.38.1
- [PULL 00/10] Misc fixes for 2023-07-25, Philippe Mathieu-Daudé, 2023/07/25
- [PULL 01/10] hw/sd/sdhci: Do not force sdhci_mmio_*_ops onto all SD controllers, Philippe Mathieu-Daudé, 2023/07/25
- [PULL 02/10] hw/mips: Improve the default USB settings in the loongson3-virt machine,
Philippe Mathieu-Daudé <=
- [PULL 03/10] hw/char/escc: Implement loopback mode, Philippe Mathieu-Daudé, 2023/07/25
- [PULL 04/10] target/mips/mxu: Replace magic array size by its definition, Philippe Mathieu-Daudé, 2023/07/25
- [PULL 05/10] target/mips/mxu: Avoid overrun in gen_mxu_S32SLT(), Philippe Mathieu-Daudé, 2023/07/25
- [PULL 06/10] target/mips/mxu: Avoid overrun in gen_mxu_q8adde(), Philippe Mathieu-Daudé, 2023/07/25
- [PULL 07/10] target/mips: Pass directory/leaf shift values to walk_directory(), Philippe Mathieu-Daudé, 2023/07/25
- [PULL 08/10] target/mips: Avoid shift by negative number in page_table_walk_refill(), Philippe Mathieu-Daudé, 2023/07/25
- [PULL 09/10] target/sparc: Handle FPRS correctly on big-endian hosts, Philippe Mathieu-Daudé, 2023/07/25
- [PULL 10/10] target/tricore: Rename tricore_feature, Philippe Mathieu-Daudé, 2023/07/25