summaryrefslogtreecommitdiff
path: root/drivers/serial/serial_mxc.c
AgeCommit message (Collapse)Author
2017-04-04imx: serial_mxc: disable ri and dcd irq in dte modeMax Krummenacher
If the UART is used in DTE mode the RI and DCD bits in UCR3 become irq enable bits. Both are set to enabled after reset and both likely are pending. Disable the bits to prevent an interrupt storm when Linux enables the UART interrupts. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2016-10-07dm: imx: serial: support device treeStefan Agner
Support instatiation through device tree. Also parse the fsl,dte-mode property to determine whether DTE mode shall be used. Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2016-07-21serial_mxc: Remove unconditional DCE settingBreno Lima
Commit 83fd908f28c ("dm: imx: serial: Support DTE mode when using driver model") breaks the serial output for the imx boards that do not use the serial driver model. The reason for the breakage is that it's setting UFCR_DCEDTE unconditionally for the non-dm case. So keep the original behavior by removing UFCR_DCEDTE setting in the non-dm case. Tested on mx7sabresd and mx6wandboard. Signed-off-by: Breno Lima <breno.lima@nxp.com> Acked-by: Stefan Agner <stefan.agner@toradex.com> Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>
2016-07-19dm: imx: serial: Support DTE mode when using driver modelStefan Agner
The MXC UART IP can be run in DTE or DCE mode. This depends on the board wiring and the pinmux used and hence is board specific. This extends platform data with a new field to choose wheather DTE mode shall be used. Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2016-03-14serial: Move carriage return before line feed for some serial driversAlison Wang
In general, a carriage return needs to execute before a line feed. The patch is to change some serial drivers based on this rule, such as serial_mxc.c, serial_pxa.c, serial_s3c24x0.c and usbtty.c. Signed-off-by: Alison Wang <alison.wang@nxp.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
2016-01-03serial_mxc: Fix setup of UARTx_UFCR registerMaximilian Schwerin
This patch writes the default values for TXTL and RXTL to UARTx_UFCR. Without this patch some older kernel versions crash as UARTx_UFCR was not always correctly initialized. Signed-off-by: Maximilian Schwerin <maximilian.schwerin@tigris.de>
2014-10-23dm: move platform data headers to include/dm/platform_dataMasahiro Yamada
The platform_data definitions are generally referenced from both drivers and board files. That is why header files defining platform_data sturectures are placed in "include" directory, but our top level "include" directory is already too cluttered. Let's collect platform_data definitions under the directory "include/dm/platform_data" like Linux gathers ones around under "include/linux/platform_data". This commit moves two header files: include/serial_mxc.h -> include/dm/platform_data/serial_mxc.h include/serial_pl01x.h -> include/dm/platform_data/serial_pl01x.h Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
2014-10-22dm: imx: serial: Support driver model in the MXC serial driverSimon Glass
Add driver model support with this driver. Boards which use this driver should define platform data in their board files. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-05-28serial_mxc: disable new features of autobaud detectionEric Nelson
Bit 7 of UCR3 is described in the i.MX3x/i.MX5x/i.MX6x reference manuals as follows: Autobaud Detection Not Improved-. Disables new features of autobaud detection (See Baud Rate Automatic Detection Protocol, for more details). 0 Autobaud detection new features selected 1 Keep old autobaud detection mechanism On at least i.MX6DQ, i.MX6DLS and i.MX53, the "new features" occasionally cause the receiver to get out of sync and continuously produce received characters of '\xff'. This patch disables the "new feature" on all boards, since there's no support for auto-baud in U-Boot on any of them. More details are available in this post on i.MX Community: https://community.freescale.com/message/403254 Signed-off-by: Eric Nelson <eric.nelson@boundarydevices.com> Tested-by: Fabio Estevam <fabio.estevam@freescale.com> Acked-by: Stefano Babic <sbabic@denx.de>
2013-07-24Add GPL-2.0+ SPDX-License-Identifier to source filesWolfgang Denk
Signed-off-by: Wolfgang Denk <wd@denx.de> [trini: Fixup common/cmd_io.c] Signed-off-by: Tom Rini <trini@ti.com>
2012-10-17serial: Use default_serial_puts() in driversMarek Vasut
Replace the in-place ad-hoc implementation of serial_puts() within the drivers with default_serial_puts() call. This cuts down on the code duplication quite a bit. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Marek Vasut <marek.vasut@gmail.com> Cc: Tom Rini <trini@ti.com>
2012-10-15serial: Remove CONFIG_SERIAL_MULTI from serial driversMarek Vasut
Remove the support for not-CONFIG_SERIAL_MULTI part from serial port drivers and some board files. Since CONFIG_SERIAL_MULTI is now enabled by default, that part is a dead code. Remove it. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Marek Vasut <marek.vasut@gmail.com> Cc: Anatolij Gustschin <agust@denx.de> Cc: Stefan Roese <sr@denx.de> Signed-off-by: Tom Rini <trini@ti.com>
2012-10-15serial: arm: Implement CONFIG_SERIAL_MULTI into mxc serial driverMarek Vasut
Implement support for CONFIG_SERIAL_MULTI into mxc serial driver. This driver was so far only usable directly, but this patch also adds support for the multi method. This allows using more than one serial driver alongside the mxc driver. Also, add a weak implementation of default_serial_console() returning this driver. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Marek Vasut <marek.vasut@gmail.com> Cc: Tom Rini <trini@ti.com> Cc: Stefano Babic <sbabic@denx.de>
2011-12-06MX: serial_mxc: cleanup removing nasty #ifdefStefano Babic
The serial driver for iMX SOCs is continuosly changed if a new SOC or not yet used port is used. CONFIG_SYS_<SOC>_<UART Port> defines were used only to find the base address for the selected UART. Instead of that, move the base address to the board configuration file and drop all #ifdef from driver. Signed-off-by: Stefano Babic <sbabic@denx.de> CC: Marek Vasut <marek.vasut@gmail.com> CC: Wolfgang Denk <wd@denx.de> CC: Fabio Estevam <fabio.estevam@freescale.com> CC: Helmut Raiger <helmut.raiger@hale.at> CC: John Rigby <jcrigby@gmail.com> CC: Matthias Weisser <weisserm@arcor.de> CC: Jason Liu <jason.hui@linaro.org> Acked-by: Jason Liu <jason.hui@linaro.org>
2011-04-27IMX: MX31: Cleanup include files and drop nasty #ifdef in driversStefano Babic
As exception among the i.MX processors, the i.MX31 has headers without general names (mx31-regs.h, mx31.h instead of imx-regs.h and clock.h). This requires several nasty #ifdef in the drivers to include the correct header. The patch cleans up the driver and renames the header files as for the other i.MX processors. Signed-off-by: Stefano Babic <sbabic@denx.de>
2011-02-02serial_mxc: add support for Freescale's i.MX35 processorStefano Babic
The patch adds UART support for the i.MX35 processor. Signed-off-by: Stefano Babic <sbabic@denx.de>
2011-02-02serial_mxc: add support for MX53 processorLiu Hui-R64343
This patch add UART support for Freescale MX53 processor Signed-off-by: Jason Liu <r64343@freescale.com>
2010-09-29MXC: Add watchdog support to serial driverStefano Babic
Calls WATCHDOG_RESET() inside serial driver for boards enabling watchdog. Signed-off-by: Stefano Babic <sbabic@denx.de>
2010-03-07Add support for Freescale MX25 SOCJohn Rigby
ARM926EJS core with MX31 peripherals. Signed-off-by: John Rigby <jcrigby@gmail.com> Earlier Version Signed-off-by: Wolfgang Denk <wd@denx.de> CC: Fred Fan <fanyefeng@gmail.com> CC: Tom <Tom.Rix@windriver.com>
2010-03-07serial_mxc: add support for MX51 processorStefano Babic
The patch adds support for the Freescale mx51 processor. Signed-off-by: Stefano Babic <sbabic@denx.de> Signed-off-by: Fred Fan <fanyefeng@gmail.com>
2009-06-21serial_mx31: allow it to work with mx27 too and rename to serial_mxcIlya Yanok
UART hardware on i.MX27 is the same as on the i.MX31 so we just need to provide the driver with correct address of the registers. Signed-off-by: Ilya Yanok <yanok@emcraft.com>