summaryrefslogtreecommitdiffstats
path: root/include/serial
Commit message (Collapse)AuthorAgeFilesLines
* serial: lpuart: Avoid division by zero when requested baudrate isAndrey Smirnov2018-08-131-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | With serdev device support added there's now a corner case where: 1. There is a DT node for a serdev device on one of the UARTs 2. There is no driver that binds against serdev device's compatibility string with 1 and 2 being true it is possible to end up in a situation where a particualr UART has not been initalized to any baudrate when clock_notifier_call_chain() gets called. This effectively translates to set_baudrate(uart, 0); which for LPUART driver result in a division by zero. To avoid this problem, convert lpuart_serial_setbaudrate() to treat zero baudrate as a request to disable the UART. While we are at it add a BUG_ON() to lpuart_setbrg() to simplify finding any future bugs. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* serial: i.MX: Add i.MX8 supportSascha Hauer2018-06-111-0/+5
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* serial/lpuart: Do not enable UART FIFOAndrey Smirnov2018-04-161-16/+5
| | | | | | | | | | Using FIFO in LPUART results in subtle serial input draining issues which are quite difficult to reproduce and troubleshoot. Since the change offered only moderate performance gain revert the code to operate in no-FIFO mode to avoid FIFO-related problems alltogether. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* ARM: i.MX: Add i.MX7 base architecture supportJuergen Borleis2017-01-201-0/+5
| | | | | Signed-off-by Juergen Borleis <jbe@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/vybrid'Sascha Hauer2016-11-141-0/+281
|\
| * i.MX: Add DEBUG_LL hooks for VF610Andrey Smirnov2016-11-111-0/+281
| | | | | | | | | | | | | | Add code to support DEBUG_LL functionality on VF610/Vybrid platform. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | serial: i.MX uart: Allow DTE mode in lowlevel codeSascha Hauer2016-11-081-0/+9
|/ | | | | | | Some consoles must be configured for DTE mode. Allow to set this in lowlevel code. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Add i.MX50 supportAlexander Kurz2016-09-121-0/+5
| | | | | Signed-off-by: Alexander Kurz <akurz@blala.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* serial: imx: Support DTE modeSascha Hauer2016-02-261-0/+1
| | | | | | Based on Kernel commit 20ff2fe60a: serial: imx: add support for DTE mode Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/vincell'Sascha Hauer2015-08-071-0/+5
|\
* | ARM: i.MX: make early UART functions independent of DEBUG_LLSascha Hauer2015-07-311-0/+40
|/ | | | | | | | We have functions to setup the i.MX uart for early use, but these all depend on DEBUG_LL. Move them to imx-uart.h to make them usable for the regular PBL console. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* i.MX: serial: Add baud rate calculation convenience functionsAndrey Smirnov2015-05-071-0/+9
| | | | | | | | | | Add two functions to calculate values for UBMR and UBIR registers. This way both early serial initalization code and serial_imx.c can use them and not duplicate the code. Singed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* i.MX: serial: Add constants for UART clock divisorAndrey Smirnov2015-05-071-0/+7
| | | | | Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* i.MX: Move UART definitions into a separate fileAndrey Smirnov2015-05-071-0/+112
Move UART definitions into a separate file to avoid redefinition in <mach/debug_ll.h> and magical constants in low level UART initialization code. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>