diff mbox series

[RFC,v4,7/7] DO NOT MERGE: replace TYPE_PL011 with x-pl011-rust in arm virt machine

Message ID 99604de6015556c4dc57bef0fa89e53b1c42b4c6.1720094395.git.manos.pitsidianakis@linaro.org
State New
Headers show
Series Add Rust support, implement ARM PL011 | expand

Commit Message

Manos Pitsidianakis July 4, 2024, 12:15 p.m. UTC
Convenience patch for testing the rust device.

Signed-off-by: Manos Pitsidianakis <manos.pitsidianakis@linaro.org>
---
 hw/arm/virt.c | 4 ++++
 1 file changed, 4 insertions(+)
diff mbox series

Patch

diff --git a/hw/arm/virt.c b/hw/arm/virt.c
index b0c68d66a3..49dd0b815e 100644
--- a/hw/arm/virt.c
+++ b/hw/arm/virt.c
@@ -929,7 +929,11 @@  static void create_uart(const VirtMachineState *vms, int uart,
     int irq = vms->irqmap[uart];
     const char compat[] = "arm,pl011\0arm,primecell";
     const char clocknames[] = "uartclk\0apb_pclk";
+#ifdef CONFIG_WITH_RUST
+    DeviceState *dev = qdev_new("x-pl011-rust");
+#else
     DeviceState *dev = qdev_new(TYPE_PL011);
+#endif
     SysBusDevice *s = SYS_BUS_DEVICE(dev);
     MachineState *ms = MACHINE(vms);