zephyr/drivers/serial
Sebastien Griffoul 300dee8a26 serial: fix ns16550 set_baud_rate()
In order to change the baudrate the DLAB bit of the LCR register has to
be set to 1 (This bit is used to enable reading and writing of the 
divisor latch register). This bit must be cleared after the baudrate
setup in order to access other registers.

The set_baud_rate function correctly sets the DLAB bit of the LCR reg but
never clears it. Therefore the ns16550 doesn't properly work any more
after updating the initial baud rate.

In order to fix this issue the LCR reg has to be temporary saved
(because it contains other important settings). After switching to a new
baud rate the LCR reg value has to be restored. 

Change-Id: Ied4db683cbf40ba3125e747552968ddf1a66e2be
Signed-off-by: Jeremie GARCIA <jeremie.garcia@intel.com>
Signed-off-by: Sebastien GRIFFOUL <sebastien.griffoul@intel.com>
2016-06-22 01:35:37 +00:00
..
Kconfig drivers: Add basic GPIO and UART support for nRF52 2016-05-27 01:38:21 +00:00
Kconfig.atmel_sam3
Kconfig.k20
Kconfig.nrf5 More cleanup whitespace in Kconfig files 2016-06-01 22:39:54 +00:00
Kconfig.ns16550
Kconfig.nsim
Kconfig.qmsi drivers: uart_qmsi: Re-enable HW FC for arduino_101 & quark_se_devboard 2016-04-25 11:42:50 +00:00
Kconfig.stellaris
Kconfig.stm32 stm32: rename CONFIG_SOC_STM32 -> CONFIG_SOC_FAMILY_STM32 2016-04-18 21:24:58 +00:00
Makefile drivers: Add basic GPIO and UART support for nRF52 2016-05-27 01:38:21 +00:00
uart_atmel_sam3.c
uart_k20_priv.h
uart_k20.c
uart_k20.h
uart_nrf5.c drivers: Add basic GPIO and UART support for nRF52 2016-05-27 01:38:21 +00:00
uart_ns16550.c serial: fix ns16550 set_baud_rate() 2016-06-22 01:35:37 +00:00
uart_ns16550.h
uart_nsim.c
uart_qmsi.c uart: qmsi: do not include ioapic.h on non x86 systems 2016-05-23 21:32:10 +00:00
uart_stellaris.c serial/stellaris: convert to use DEVICE_AND_API_INIT() 2016-04-15 22:06:16 +00:00
uart_stellaris.h
uart_stm32.c stm32: rename SOC_STM32F1X -> SOC_SERIES_STM32F1X 2016-04-18 21:24:58 +00:00
uart_stm32.h