summaryrefslogtreecommitdiffstats
path: root/drivers/serial/serial_zynq.c
Commit message (Collapse)AuthorAgeFilesLines
* serial: zynq: Change logic in putcMichal Simek2016-02-221-2/+2
| | | | | | | | | | | | | | | | Sync logic with Linux kernel where TX empty flag is checked before char is sent. This logic is fixing problem with console on zynqmp platform. For example: DRAM: 2 GiB Enabling Caches... EL Level: �� sdhci@ff170000: 0 Using default environment Signed-off-by: Michal Simek <michal.simek@xilinx.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Moritz Fischer <moritz.fischer@ettus.com>
* serial: zynq: Fix address reading from DMMichal Simek2016-01-271-6/+1
| | | | | | | Use dev_get_addr() instead of reading reg base directly in the driver. Core function is also more robust. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* serial: zynq: Extend compatible string listMichal Simek2016-01-271-0/+1
| | | | | | | ZynqMP is using updated core with cdns,uart-r1p12 compatible string. Signed-off-by: Michal Simek <monstr@monstr.eu> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* serial: zynq: Use static inline for _debug_uart_init()Michal Simek2016-01-081-1/+1
| | | | | | | | | | | | Mark _debug_uart_init() as static to avoid sparse warning and inline it to debug_uart_init(). Reported-by: Thomas Chou <thomas@wytron.com.tw> Signed-off-by: Michal Simek <michal.simek@xilinx.com> Reviewed-by: Thomas Chou <thomas@wytron.com.tw> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Acked-by: Simon Glass <sjg@chromium.org>
* serial: zynq: Remove duplicated headerMichal Simek2015-12-071-3/+0
| | | | | | | | debug_uart.h is included twice. Signed-off-by: Michal Simek <michal.simek@xilinx.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* serial: zynq: Fix incorrect reference to s5p driverMichal Simek2015-12-071-1/+1
| | | | | | | | Remove this c&p error from s5p driver. Signed-off-by: Michal Simek <michal.simek@xilinx.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* arm: zynq: Move serial driver to driver modelSimon Glass2015-11-041-98/+65
| | | | | | | Update this driver to use driver model and change all users. Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* arm: zynq: serial: Drop non-device-tree serial driver portionsSimon Glass2015-11-041-15/+0
| | | | | | | Since we use device tree in SPL also, we can drop this code. Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* arm: zynq: Support the debug UARTSimon Glass2015-11-041-16/+61
| | | | | | | | Add support for the debug UART to assist with early debugging. Enable it for Zybo as an example. Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* of: clean up OF_CONTROL ifdef conditionalsMasahiro Yamada2015-08-181-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | We have flipped CONFIG_SPL_DISABLE_OF_CONTROL. We have cleansing devices, $(SPL_) and CONFIG_IS_ENABLED(), so we are ready to clear away the ugly logic in include/fdtdec.h: #ifdef CONFIG_OF_CONTROL # if defined(CONFIG_SPL_BUILD) && !defined(SPL_OF_CONTROL) # define OF_CONTROL 0 # else # define OF_CONTROL 1 # endif #else # define OF_CONTROL 0 #endif Now CONFIG_IS_ENABLED(OF_CONTROL) is the substitute. It refers to CONFIG_OF_CONTROL for U-boot proper and CONFIG_SPL_OF_CONTROL for SPL. Also, we no longer have to cancel CONFIG_OF_CONTROL in include/config_uncmd_spl.h and scripts/Makefile.spl. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Reviewed-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org> Acked-by: Linus Walleij <linus.walleij@linaro.org>
* serial: zynq: Add support for slow emulation platformMichal Simek2015-04-291-1/+7
| | | | | | | | On slow platforms not all baudrate setting is valid. Check it directly in the driver and setup maximum possible frequency. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* serial: Extend structure comments with register offsetMichal Simek2015-01-261-6/+6
| | | | | | This information help with debugging issues with uart. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* serial: zynq: Use global baudrate instead of hardcoded oneMichal Simek2015-01-261-17/+1
| | | | | | This change enables to change baudrate on command line. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* serial: zynq: Fix typo in suffix function nameMichal Simek2014-05-061-1/+1
| | | | | | | 's/zynq_serial_initalize/zynq_serial_initialize/g' serial_initialize is used by all serial drivers. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* serial: zynq: Remove sparse warningsMichal Simek2014-05-061-8/+8
| | | | | | | | | | | | | | | | | | | | Warnings: drivers/serial/serial_zynq.c:181:1: warning: symbol 'uart_zynq0_init' was not declared. Should it be static? drivers/serial/serial_zynq.c:181:1: warning: symbol 'uart_zynq0_setbrg' was not declared. Should it be static? drivers/serial/serial_zynq.c:181:1: warning: symbol 'uart_zynq0_getc' was not declared. Should it be static? drivers/serial/serial_zynq.c:181:1: warning: symbol 'uart_zynq0_tstc' was not declared. Should it be static? drivers/serial/serial_zynq.c:181:1: warning: symbol 'uart_zynq0_putc' was not declared. Should it be static? drivers/serial/serial_zynq.c:181:1: warning: symbol 'uart_zynq0_puts' was not declared. Should it be static? drivers/serial/serial_zynq.c:182:22: warning: symbol 'uart_zynq_serial0_device' was not declared. Should it be static? drivers/serial/serial_zynq.c:184:1: warning: symbol 'uart_zynq1_init' was not declared. Should it be static? drivers/serial/serial_zynq.c:184:1: warning: symbol 'uart_zynq1_setbrg' was not declared. Should it be static? drivers/serial/serial_zynq.c:184:1: warning: symbol 'uart_zynq1_getc' was not declared. Should it be static? drivers/serial/serial_zynq.c:184:1: warning: symbol 'uart_zynq1_tstc' was not declared. Should it be static? drivers/serial/serial_zynq.c:184:1: warning: symbol 'uart_zynq1_putc' was not declared. Should it be static? drivers/serial/serial_zynq.c:184:1: warning: symbol 'uart_zynq1_puts' was not declared. Should it be static? drivers/serial/serial_zynq.c:185:22: warning: symbol 'uart_zynq_serial1_device' was not declared. Should it be static? Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* serial: zynq: Add OF initialization supportMichal Simek2014-03-041-0/+28
| | | | | | | Add console selection from DTB which is enough to have OF driven solution. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* serial_zynq: Migrate to Zynq clock frameworkSoren Brinkmann2014-02-191-11/+2
| | | | | | | | Remove hard coded frequencies and use Zynq's clock framework to obtain the UART clock frequency. Signed-off-by: Soren Brinkmann <soren.brinkmann@xilinx.com> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* zynq: serial: Simplify serial driver initializationMichal Simek2014-02-191-14/+20
| | | | | | | | | | Define both serial uarts in the driver and return default uart based on board configuration. - Move baseaddresses to hardware.h - Define default baudrate and clock values Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* serial: zynq: Remove unused #definesSoren Brinkmann2013-12-021-4/+0
| | | | | | Signed-off-by: Soren Brinkmann <soren.brinkmann@xilinx.com> Signed-off-by: Michal Simek <michal.simek@xilinx.com> Series-to: trini, uboot
* Add GPL-2.0+ SPDX-License-Identifier to source filesWolfgang Denk2013-07-241-17/+1
| | | | | | Signed-off-by: Wolfgang Denk <wd@denx.de> [trini: Fixup common/cmd_io.c] Signed-off-by: Tom Rini <trini@ti.com>
* serial: Remove CONFIG_SERIAL_MULTI from serial driversMarek Vasut2012-10-151-32/+0
| | | | | | | | | | | | 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>
* serial: zynq: Move serial registration from serial_initialize()Tom Rini2012-10-151-0/+10
| | | | | | | | | | | | | | | | | | | Move the registration of zynq_serialN_device ports from default serial_initialize() into driver specific function called from serial_initialize(). This slims down the serial_initialize() call to a bare tracker of all possible serial port registration routines in U-Boot. The newly implemented zynq_serial_initialize() function, which is implemented inside of the serial_zynq driver allows encapsulation of zynq_serialN_device within the serial_zynq driver itself. Also, remove the exports of zynq_serialN_device from include/serial.h as they are no longer needed. This is simply because the implementation of default_serial_console() is wrapped into the serial_zynq driver and the default console is picked by CONFIG_SERIAL<N> macro in config file. Signed-off-by: Tom Rini <trini@ti.com>
* serial: Rename .init() and .uninit() in serial_deviceMarek Vasut2012-10-151-2/+2
| | | | | | | | | | | | Rename .init() to .start() and .uninit() to .stop() in struct serial_device. This allows aligning struct serial_device with closer to struct stdio_dev. The real goal here is to allow these two structures to converge together and eventually make one to be a superset of the other. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Marek Vasut <marek.vasut@gmail.com> Signed-off-by: Tom Rini <trini@ti.com>
* serial: Add Zynq serial driverMichal Simek2012-10-041-0/+247
The driver is used on Xilinx Zynq platform. Signed-off-by: Michal Simek <monstr@monstr.eu> CC: Joe Hershberger <joe.hershberger@gmail.com> CC: Marek Vasut <marex@denx.de> Acked-by: Marek Vasut <marex@denx.de>
OpenPOWER on IntegriCloud