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 <m.niestroj@emb.dev>
This commit is contained in:
parent
774a3cd756
commit
1ae3302b78
1 changed files with 1 additions and 2 deletions
|
@ -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;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue