Does uart_pl011.c support non interrupt mode


Ayan Kumar Halder <ayankuma@...>
 

Hi Zephyr Users,

When I try to compile with fvp_baser_armv8r_aarch32_defconfig and CONFIG_UART_INTERRUPT_DRIVEN=n, I get the following compilation error

/home/ayan/zephyrproject/zephyr/drivers/serial/uart_

pl011.c:474:4: error: 'struct pl011_config' has no member named 'uart'
  474 |   .uart = (volatile struct pl011_regs *)DT_INST_REG_ADDR(n),  \

I fixed this error using the following diff

ayan@ayan-Lenovo-V15-IIL:~/zephyrproject/zephyr$ git diff drivers/serial/uart_pl011.c
diff --git a/drivers/serial/uart_pl011.c b/drivers/serial/uart_pl011.c
index d00d805f..636d2fcf 100644
--- a/drivers/serial/uart_pl011.c
+++ b/drivers/serial/uart_pl011.c
@@ -49,7 +49,9 @@ struct pl011_config {
        uint32_t sys_clk_freq;
 #ifdef CONFIG_UART_INTERRUPT_DRIVEN
uart_irq_config_func_t irq_config_func;
-#endif
+#else  /* CONFIG_UART_INTERRUPT_DRIVEN */
+       volatile struct pl011_regs *uart;
+#endif  /* CONFIG_UART_INTERRUPT_DRIVEN */
 };


But I do not get any serial output.

So, does uart_pl011 support non interrupt mode ? Or is there some issue with my diff ?

Appreciate any help.

Kind regards,

Ayan

Join users@lists.zephyrproject.org to automatically receive all group messages.