Skip to content

Commit 4c880ba

Browse files
drivers: uart: fix IRQ Config
Fix IRQ config to recognize TI VIM interrupt-controller Signed-off-by: Shreyas Shankar <s-shankar@ti.com>
1 parent cf6170c commit 4c880ba

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

drivers/serial/uart_ns16550.c

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1808,9 +1808,15 @@ static DEVICE_API(uart, uart_ns16550_driver_api) = {
18081808
#endif
18091809
};
18101810

1811-
#define UART_NS16550_IRQ_FLAGS(n) \
1812-
COND_CODE_1(DT_INST_IRQ_HAS_CELL(n, sense), \
1813-
(DT_INST_IRQ(n, sense)), \
1811+
#ifdef CONFIG_DT_HAS_TI_VIM_ENABLED
1812+
#define UART_NS16550_IRQ_FLAGS_NAME flags
1813+
#else
1814+
#define UART_NS16550_IRQ_FLAGS_NAME sense
1815+
#endif
1816+
1817+
#define UART_NS16550_IRQ_FLAGS(n) \
1818+
COND_CODE_1(DT_INST_IRQ_HAS_CELL(n, UART_NS16550_IRQ_FLAGS_NAME), \
1819+
(DT_INST_IRQ(n, UART_NS16550_IRQ_FLAGS_NAME)), \
18141820
(0))
18151821

18161822
/* IO-port or MMIO based UART */

0 commit comments

Comments
 (0)