From 1c3b46daffea01fe9234697ea974caf10f3f60b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timo=20Ter=C3=A4s?= Date: Wed, 11 Mar 2020 16:13:05 +0200 Subject: [PATCH] driver: uart: ns16550: store active configuration in dev data MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Update device data with the activated configuration, so that it will be remembered for follow up configuration get requests. Signed-off-by: Timo Teräs --- drivers/serial/uart_ns16550.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/serial/uart_ns16550.c b/drivers/serial/uart_ns16550.c index 03429396b65..3cebe566041 100644 --- a/drivers/serial/uart_ns16550.c +++ b/drivers/serial/uart_ns16550.c @@ -397,6 +397,8 @@ static int uart_ns16550_configure(struct device *dev, return -ENOTSUP; } + dev_data->uart_config = *cfg; + /* data bits, stop bits, parity, clear DLAB */ OUTBYTE(LCR(dev), uart_cfg.data_bits | uart_cfg.stop_bits | uart_cfg.parity);