From 1ae3302b78081f9e5c263690856957079425f321 Mon Sep 17 00:00:00 2001 From: Marcin Niestroj Date: Fri, 13 May 2022 17:20:39 +0200 Subject: [PATCH] wifi: esp_at: use UART device pointer directly instead of label UART device pointer is already used directly when configuring modem interface. Convert the case when UART is reconfigured when 'target-speed' DT property is specified. Signed-off-by: Marcin Niestroj --- drivers/wifi/esp_at/esp.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/wifi/esp_at/esp.c b/drivers/wifi/esp_at/esp.c index 766d055efdf..fbdd4bee686 100644 --- a/drivers/wifi/esp_at/esp.c +++ b/drivers/wifi/esp_at/esp.c @@ -1004,8 +1004,7 @@ static void esp_init_work(struct k_work *work) UART_CFG_FLOW_CTRL_RTS_CTS : UART_CFG_FLOW_CTRL_NONE, }; - ret = uart_configure(device_get_binding(DT_INST_BUS_LABEL(0)), - &uart_config); + ret = uart_configure(DEVICE_DT_GET(DT_INST_BUS(0)), &uart_config); if (ret < 0) { LOG_ERR("Baudrate change failed %d", ret); return;