qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[RFC PATCH 05/10] hw/char/avr: Reduce USART I/O size


From: Philippe Mathieu-Daudé
Subject: [RFC PATCH 05/10] hw/char/avr: Reduce USART I/O size
Date: Thu, 28 Nov 2019 02:50:25 +0100

Per the datasheet the USART uses 6 consecutive 8-bit registers.

Signed-off-by: Philippe Mathieu-Daudé <address@hidden>
---
 hw/char/avr_usart.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hw/char/avr_usart.c b/hw/char/avr_usart.c
index d039689c56..ba17bdd470 100644
--- a/hw/char/avr_usart.c
+++ b/hw/char/avr_usart.c
@@ -284,7 +284,7 @@ static void avr_usart_init(Object *obj)
     sysbus_init_irq(SYS_BUS_DEVICE(obj), &s->rxc_irq);
     sysbus_init_irq(SYS_BUS_DEVICE(obj), &s->dre_irq);
     sysbus_init_irq(SYS_BUS_DEVICE(obj), &s->txc_irq);
-    memory_region_init_io(&s->mmio, obj, &avr_usart_ops, s, TYPE_AVR_USART, 8);
+    memory_region_init_io(&s->mmio, obj, &avr_usart_ops, s, TYPE_AVR_USART, 6);
     sysbus_init_mmio(SYS_BUS_DEVICE(obj), &s->mmio);
     qdev_init_gpio_in(DEVICE(s), avr_usart_pr, 1);
     s->enabled = true;
-- 
2.21.0




reply via email to

[Prev in Thread] Current Thread [Next in Thread]