drivers: uart: esp32: fix driver initialization id number

The select uart instance used in uart driver initialization won't
work as expected because the index used was not correct. This
fixes the macro call to use proper index value.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
This commit is contained in:
Sylvio Alves 2022-02-17 15:22:06 -03:00 committed by Anas Nashif
commit bf08b5f0ed

View file

@ -575,7 +575,7 @@ static struct uart_esp32_data uart_esp32_data_##idx = { \
}, \
.hal = { \
.dev = \
(uart_dev_t *)DT_REG_ADDR(DT_NODELABEL(uart##idx)), \
(uart_dev_t *)DT_INST_REG_ADDR(idx), \
}, \
}; \
\