drivers: uart_pl011: Fix compilation when CONFIG_UART_INTERRUPT_DRIVEN=n
The driver fails to compile when CONFIG_UART_INTERRUPT_DRIVEN=n. This is due to a nested ifdef on CONFIG_UART_INTERRUPT_DRIVEN that is excluding pieces of code unrelated to the uart interrupts management. Signed-off-by: Carlo Caione <ccaione@baylibre.com>
This commit is contained in:
parent
a76a74c541
commit
26ff7603f1
1 changed files with 3 additions and 0 deletions
|
@ -327,6 +327,7 @@ static void pl011_irq_callback_set(struct device *dev,
|
||||||
DEV_DATA(dev)->irq_cb = cb;
|
DEV_DATA(dev)->irq_cb = cb;
|
||||||
DEV_DATA(dev)->irq_cb_data = cb_data;
|
DEV_DATA(dev)->irq_cb_data = cb_data;
|
||||||
}
|
}
|
||||||
|
#endif /* CONFIG_UART_INTERRUPT_DRIVEN */
|
||||||
|
|
||||||
static const struct uart_driver_api pl011_driver_api = {
|
static const struct uart_driver_api pl011_driver_api = {
|
||||||
.poll_in = pl011_poll_in,
|
.poll_in = pl011_poll_in,
|
||||||
|
@ -392,6 +393,8 @@ static int pl011_init(struct device *dev)
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef CONFIG_UART_INTERRUPT_DRIVEN
|
||||||
void pl011_isr(void *arg)
|
void pl011_isr(void *arg)
|
||||||
{
|
{
|
||||||
struct device *dev = arg;
|
struct device *dev = arg;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue