qemu-riscv
[Top][All Lists]
Advanced

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

[PATCH] include/hw/char: QOMify shakti_uart


From: Vijai Kumar K
Subject: [PATCH] include/hw/char: QOMify shakti_uart
Date: Sat, 18 Jun 2022 02:55:42 +0530

Signed-off-by: Vijai Kumar K <vijai@behindbytes.com>
---
 include/hw/char/shakti_uart.h | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/include/hw/char/shakti_uart.h b/include/hw/char/shakti_uart.h
index 526c408233..2c305562e7 100644
--- a/include/hw/char/shakti_uart.h
+++ b/include/hw/char/shakti_uart.h
@@ -27,6 +27,7 @@
 
 #include "hw/sysbus.h"
 #include "chardev/char-fe.h"
+#include "qom/object.h"
 
 #define SHAKTI_UART_BAUD        0x00
 #define SHAKTI_UART_TX          0x04
@@ -48,10 +49,9 @@
 #define SHAKTI_UART_CONTROL_DEFAULT 0x0100
 
 #define TYPE_SHAKTI_UART "shakti-uart"
-#define SHAKTI_UART(obj) \
-    OBJECT_CHECK(ShaktiUartState, (obj), TYPE_SHAKTI_UART)
+OBJECT_DECLARE_SIMPLE_TYPE(ShaktiUartState, SHAKTI_UART)
 
-typedef struct {
+struct ShaktiUartState {
     /* <private> */
     SysBusDevice parent_obj;
 
@@ -69,6 +69,6 @@ typedef struct {
     uint32_t uart_rx_threshold;
 
     CharBackend chr;
-} ShaktiUartState;
+};
 
 #endif /* HW_SHAKTI_UART_H */
-- 
2.25.1





reply via email to

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