@samitouri / QOSamiQemu / commits / 8825853590

hw/arm: Remove hw_error() for the unimplemented CM_LMBUSCNT register

When writing to this register, QEMU currently aborts: $ echo "readl 0x10000018" | ./qemu-system-arm -audiodev none,id=snd0 \ -M integratorcp,accel=qtest,audiodev=snd0 -display none -qtest stdio [I 0.000000] OPENED [R +0.001907] readl 0x10000018 qemu: hardware error: integratorcm_read: CM_LMBUSCNT [...] Aborted (core dumped) This is bad, a guest should ideally never be able to kill QEMU like this. Now, according to the "Intergrator/CP User Guide" from: https://developer.arm.com/documentation/dui0159/b/porting-integrator-ap-and-im-pd1/registers "The Integrator/AP CM_LMBUSCNT has been removed." That means this register does not seem to be implemented on real CP boards at all, only for older AP boards. Thus it should be fine if we simply ignore this register in QEMU and handle it like all other unimplemented registers in the "default" handler of the case statement. Resolves: https://gitlab.com/qemu-project/qemu/-/work_items/3407 Signed-off-by: Thomas Huth <thuth@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Message-id: 20260420064933.64765-1-thuth@redhat.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org>

Thomas Huth committed Apr 20, 2026 at 08:49 UTC 88258535909f6939b6717beb8db31e64118b84c5
1 file changed -3
hw/arm/integratorcp.c
-3
@@ -106,9 +106,6 @@ static uint64_t integratorcm_read(void *opaque, hwaddr offset,
106 } else {
107 return s->cm_lock;
108 }
109 - case 6: /* CM_LMBUSCNT */
110 - /* ??? High frequency timer. */
111 - hw_error("integratorcm_read: CM_LMBUSCNT");
109 case 7: /* CM_AUXOSC */
110 return s->cm_auxosc;
111 case 8: /* CM_SDRAM */