summaryrefslogtreecommitdiff
path: root/drivers/tty/serial/mxs-auart.c
AgeCommit message (Collapse)Author
2016-04-30serial: mxs-auart: Use generic uart-has-rtscts DT propertyGeert Uytterhoeven
Convert the Freescale MXS AUART driver from using the vendor-specific "fsl,uart-has-rtscts" to the generic "uart-has-rtscts" DT property, as documented by the Generic Serial DT Bindings. The old vendor-specific property is still recognized by the driver for backwards compatibility, but it is deprecated. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-04-30serial: mxs-auart: add Alphascale ASM9260 supportOleksij Rempel
Alphascale ASM9260 uart IP has some common registers with Freescale STMP37XX. This patch provide changes which allow to reuse mxs-auart.c code for ASM9260. Reviewed-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Oleksij Rempel <linux@rempel-privat.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-04serial: mctrl-gpio: rename init functionUwe Kleine-König
This is done before adding more functionality to the init function with the existing name. As this new functionality conflicts with stuff drivers are required to implement themselves up to I want to convert them one by one to make reviewing and reverting more easy in case I broke something. Once mctrl_gpio_init is there and all drivers are converted mctrl_gpio_init_noauto can be removed again. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-15serial: mxs-auart: fix baud rate rangeStefan Wahren
Currently mxs-auart doesn't care correctly about the baud rate divisor. According to reference manual the baud rate divisor must be between 0x000000EC and 0x003FFFC0. So calculate the possible baud rate range and use it for uart_get_baud_rate(). Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com> Reviewed-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-15serial: mxs-auart: keep the AUART unit in reset state when not in useJuergen Borleis
Whenever the UART device driver gets closed from userland, the driver disables the UART unit and then stops the clocks to save power. The bit which disabled the UART unit is described as:  "UART Enable. If this bit is set to 1, the UART is enabled. Data transmission and reception occurs for the UART signals. When the UART is disabled in the middle of transmission or reception, it completes the current character before stopping." The important part is the "it completes the current character". Whenever a reception is ongoing when the UART gets disabled (including the clock off) the statemachine freezes and "remembers" this state on the next open() when re-enabling the unit's clock. In this case we end up receiving an additional bogus character immediately. The solution in this change is to switch the AUART unit into its reset state on close() and only release it from its reset state on the next open(). Note: when the unit is also used as system console it is always 'in use', so we cannot reset it on close(). Signed-off-by: Juergen Borleis <jbe@pengutronix.de> Reviewed-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-15serial: mxs-auart: use a function name to reflect what it really doesJuergen Borleis
This function clears the reset the AUART unit is in after system start to make it work. Signed-off-by: Juergen Borleis <jbe@pengutronix.de> Reviewed-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10serial: mxs: Constify platform_device_idKrzysztof Kozlowski
The platform_device_id is not modified by the driver and core uses it as const. Signed-off-by: Krzysztof Kozlowski <k.kozlowski.k@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-26tty: constify of_device_id arrayFabian Frederick
of_device_id is always used as const. (See driver.of_match_table and open firmware functions) Signed-off-by: Fabian Frederick <fabf@skynet.be> Acked-by: Peter Korsgaard <peter@korsgaard.com> Acked-by: Timur Tabi <timur@tabi.org> Acked-by: Patrice Chotard <patrice.chotard@st.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-11serial: mxs-auart: Fix build errorFabio Estevam
Commit 343fda95481a7254f ("serial: mxs-auart: properly handle mctrl_gpio failing") introduced the following build error: CC drivers/tty/serial/mxs-auart.o drivers/tty/serial/mxs-auart.c: In function 'mxs_auart_probe': drivers/tty/serial/mxs-auart.c:1282:3: error: unknown type name 'got' Fix it by providing a proper return code. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-07serial: mxs-auart: properly handle mctrl_gpio failingUwe Kleine-König
If mctrl_gpio_init returns an error code this value should be forwarded and the driver must not simply ignore this failure. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-02-02serial: mxs-auart: Remove unneeded zeroing of 'ret'Fabio Estevam
There is no need to explicitly zero the 'ret' variable as it is properly initialized in a few lines below as: ret = serial_mxs_probe_dt(s, pdev); Remove the unneeded zeroing of 'ret'. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-02-02serial: mxs-auart: Check for platform_get_irq() errorFabio Estevam
We should check whether platform_get_irq() failed, and in the case of error this needs to be propagated. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-02-02serial: mxs-auart: Remove irq from private structureFabio Estevam
The irq number is only used inside the probe function, so there is no need to keep it in the private mxs_auart_port structure. Use a local 'irq' variable for storing the irq number instead. Also make its type of 'int' as platform_get_irq() may fail and return a negative number. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-01-09serial: mxs-auart: Use devm_request_irq()Fabio Estevam
By using devm_request_irq() we can have a shorter and cleaner code. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-01-09serial: mxs-auart: Use devm_clk_get()Fabio Estevam
By using devm_clk_get() we can have a shorter and cleaner code. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-01-09serial: mxs-auart: Use devm_kzalloc()Fabio Estevam
By using devm_kzalloc() we can have a shorter and cleaner code. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-01-09serial: mxs-auart: Remove unneeded goto labelFabio Estevam
Instead of jumping to the 'out' label, let's return the error immediately, which makes the code shorter and cleaner. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-12-15Merge tag 'driver-core-3.19-rc1' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core Pull driver core update from Greg KH: "Here's the set of driver core patches for 3.19-rc1. They are dominated by the removal of the .owner field in platform drivers. They touch a lot of files, but they are "simple" changes, just removing a line in a structure. Other than that, a few minor driver core and debugfs changes. There are some ath9k patches coming in through this tree that have been acked by the wireless maintainers as they relied on the debugfs changes. Everything has been in linux-next for a while" * tag 'driver-core-3.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (324 commits) Revert "ath: ath9k: use debugfs_create_devm_seqfile() helper for seq_file entries" fs: debugfs: add forward declaration for struct device type firmware class: Deletion of an unnecessary check before the function call "vunmap" firmware loader: fix hung task warning dump devcoredump: provide a one-way disable function device: Add dev_<level>_once variants ath: ath9k: use debugfs_create_devm_seqfile() helper for seq_file entries ath: use seq_file api for ath9k debugfs files debugfs: add helper function to create device related seq_file drivers/base: cacheinfo: remove noisy error boot message Revert "core: platform: add warning if driver has no owner" drivers: base: support cpu cache information interface to userspace via sysfs drivers: base: add cpu_device_create to support per-cpu devices topology: replace custom attribute macros with standard DEVICE_ATTR* cpumask: factor out show_cpumap into separate helper function driver core: Fix unbalanced device reference in drivers_probe driver core: fix race with userland in device_add() sysfs/kernfs: make read requests on pre-alloc files use the buffer. sysfs/kernfs: allow attributes to request write buffer be pre-allocated. fs: sysfs: return EGBIG on write if offset is larger than file size ...
2014-11-26serial: mxs-auart: fix tx_empty against shift registerJanusz Uzycki
tx_empty() should test whether both the transmitter fifo and shifter for the port is empty, ie. the whole last char was transmitted. The shift register is empty if AUART_STAT_BUSY is cleared. The patch fixes the function against the shift register. According to i.MX23 and i.MX28 Reference Manual: AUART_STAT_TXFE: TX FIFO or transmit holding register is empty. AUART_STAT_BUSY: AUART still transmits bits. The BUSY signal goes HIGH as soon as the data is written to the transmit FIFO (that is, the FIFO is non-empty) and remains asserted HIGH while data is being transmitted. BUSY is negated only when the transmit FIFO is empty, and the last character has been transmitted from the shift register, including the stop bits. Signed-off-by: Janusz Uzycki <j.uzycki@elproma.com.pl> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26serial: mxs-auart: fix gpio change detection on interruptJanusz Uzycki
mxs_auart_modem_status() did't detect gpio's state change because s->mctrl_prev was modified before by mctrl_gpio_get(). The patch introduces mctrl_temp variable to fix the bug. Signed-off-by: Janusz Uzycki <j.uzycki@elproma.com.pl> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26serial: mxs-auart: Fix mxs_auart_set_ldisc()Fabio Estevam
Commit 732a84a037a4 ("serial: core: Pass termios to set_ldisc() notifications") changed the set_ldisc prototype. At the time of this commit the mxs_auart driver did not implement set_ldisc, so that's why it has not been converted. Adapt also mxs_auart_set_ldisc() so that the following build warning can be fixed: drivers/tty/serial/mxs-auart.c:962:2: warning: initialization from incompatible pointer type .set_ldisc = mxs_auart_set_ldisc, ^ drivers/tty/serial/mxs-auart.c:962:2: warning: (near initialization for 'mxs_auart_ops.set_ldisc') Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Tested-by: Janusz Uzycki <j.uzycki@elproma.com.pl> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-06serial: mxs-auart: enable PPS supportJanusz Uzycki
Enables PPS support in mxs-auart serial driver to make PPS API working. Signed-off-by: Janusz Uzycki <j.uzycki@elproma.com.pl> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-06serial: mxs-auart: add interrupts for modem control linesJanusz Uzycki
Handle CTS/DSR/RI/DCD GPIO interrupts in mxs-auart. Signed-off-by: Janusz Uzycki <j.uzycki@elproma.com.pl> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-06serial: mxs-auart: use mctrl_gpio helpers for handling modem signalsJanusz Uzycki
Dedicated CTS and RTS pins are unusable together with a lot of other peripherals because they share the same line. Pinctrl is limited. Moreover, the AUART controller doesn't handle DTR/DSR/DCD/RI signals, so we have to control them via GPIO. This patch permits to use GPIOs to control the CTS/RTS/DTR/DSR/DCD/RI signals. Signed-off-by: Janusz Uzycki <j.uzycki@elproma.com.pl> Reviewed-by: Richard Genoud <richard.genoud@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-06serial: mxs-auart: clean get_mctrl and set_mctrlJanusz Uzycki
Russell King: The only thing which the .get_mctrl method is supposed to do is to return the state of the /input/ lines, which are CTS, DCD, DSR, RI. The output line state is stored in port->mctrl, and is added to the returned value by serial_core when it's required. RTS output state should not be returned from the .get_mctrl method. This patch removes ctrl variable from mxs_auart_port and removes useless reading back RTS line. The ctrl variable in mxs_auart_port duplicated mctrl, member of uart_port structure in serial_core.h. The removed code from mxs_auart_set_mctrl() and mxs_auart_get_mctrl duplicated uart_update_mctrl() and uart_tiocmget() in serial_core.c. Signed-off-by: Janusz Uzycki <j.uzycki@elproma.com.pl> Reviewed-by: Richard Genoud <richard.genoud@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-06serial: mxs-auart: add sysrq supportJanusz Uzycki
When using mxs-auart based console, sometime we need the sysrq function to help debugging kernel. The sysrq code is basically there, this patch just simply enable it. Signed-off-by: Janusz Uzycki <j.uzycki@elproma.com.pl> Reviewed-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-10-20tty: serial: drop owner assignment from platform_driversWolfram Sang
A platform_driver does not need to set an owner, it will be populated by the driver core. Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
2014-09-24serial: core: Privatize modem status enable flagsPeter Hurley
The serial core uses the tty port flags, ASYNC_CTS_FLOW and ASYNC_CD_CHECK, to track whether CTS and DCD changes should be ignored or handled. However, the tty port flags are not safe for atomic bit operations and no lock provides serialized updates. Introduce the struct uart_port status field to track CTS and DCD enable states, and serialize access with uart port lock. Substitute uart_cts_enabled() helper for tty_port_cts_enabled(). Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-07-10serial: treewide: Remove empty implementations of enable_ms()Alexander Shiyan
Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-19serial: Fix IGNBRK handlingPeter Hurley
If IGNBRK is set without either BRKINT or PARMRK set, some uart drivers send a 0x00 byte for BREAK without the TTYBREAK flag to the line discipline, when it should send either nothing or the TTYBREAK flag set. This happens because the read_status_mask masks out the BI condition, which uart_insert_char() then interprets as a normal 0x00 byte. SUS v3 is clear regarding the meaning of IGNBRK; Section 11.2.2, General Terminal Interface - Input Modes, states: "If IGNBRK is set, a break condition detected on input shall be ignored; that is, not put on the input queue and therefore not read by any process." Fix read_status_mask to include the BI bit if IGNBRK is set; the lsr status retains the BI bit if a BREAK is recv'd, which is subsequently ignored in uart_insert_char() when masked with the ignore_status_mask. Affected drivers: 8250 - all serial_txx9 mfd amba-pl010 amba-pl011 atmel_serial bfin_uart dz ip22zilog max310x mxs-auart netx-serial pnx8xxx_uart pxa sb1250-duart sccnxp serial_ks8695 sirfsoc_uart st-asc vr41xx_siu zs sunzilog fsl_lpuart sunsab ucc_uart bcm63xx_uart sunsu efm32-uart pmac_zilog mpsc msm_serial m32r_sio Unaffected drivers: omap-serial rp2 sa1100 imx icom Annotated for fixes: altera_uart mcf Drivers without break detection: 21285 xilinx-uartps altera_jtaguart apbuart arc-uart clps711x max3100 uartlite msm_serial_hs nwpserial lantiq vt8500_serial Unknown: samsung mpc52xx_uart bfin_sport_uart cpm_uart/core Fixes: Bugzilla #71651, '8250_core.c incorrectly handles IGNBRK flag' Reported-by: Ivan <athlon_@mail.ru> Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-04-18arch: Mass conversion of smp_mb__*()Peter Zijlstra
Mostly scripted conversion of the smp_mb__* barriers. Signed-off-by: Peter Zijlstra <peterz@infradead.org> Acked-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Link: http://lkml.kernel.org/n/tip-55dhyhocezdw1dg7u19hmh1u@git.kernel.org Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: linux-arch@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org>
2013-12-09tty: serial: mxs-auart: Check the return value from clk_prepare_enable()Fabio Estevam
clk_prepare_enable() may fail, so let's check its return value and propagate it in the case of error. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-10-06serial: mxs-auart: set the FIFO size to DMA buffer sizeHector Palacios
When DMA is enabled (with hardware flow control enabled) the FIFO size must be set to the size of the DMA buffer, as this is the size the tty subsystem can use. Signed-off-by: Hector Palacios <hector.palacios@digi.com> Reviewed-by: Marek Vasut <marex@denx.de> Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-08-05serial: mxs: remove the MXS_AUART_DMA_CONFIGHuang Shijie
The MXS_AUART_DMA_CONFIG is originally used to check if the DT node is configured with the DMA property. But now, the MXS_AUART_DMA_CONFIG is set unconditionally in the serial_mxs_probe_dt(), so the check in the mxs_auart_settermios() is not necessary anymore. This patch removes this macro. Signed-off-by: Huang Shijie <shijie8@gmail.com> Acked-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-08-05serial: mxs: enable the DMA only when the RTS/CTS is validHuang Shijie
The original DMA support works only when RTS/CTS is enabled. (see the "e800163 serial: mxs-auart: add the DMA support for mx28") But after several patches, DMA support has lost this limit. (see the "bcc20f9 serial: mxs-auart: move to use generic DMA helper") So an UART without the RTS/CTS lines may also enables the DMA support, in which case the UART may gets unpredictable results. This patch adds an optional property for the UART DT node which indicates the UART has RTS and CTS lines, and it also means you enable the DMA support for this UART. This patch also adds a macro MXS_AUART_RTSCTS, and uses it to check RTS/CTS before we enable the DMA for the UART. Signed-off-by: Huang Shijie <b32955@freescale.com> Signed-off-by: Huang Shijie <shijie8@gmail.com> Acked-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-08-04Merge 3.11-rc4 into tty-nextGreg Kroah-Hartman
We want the tty fixes in here as well. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-07-26serial/mxs-auart: increase time to wait for transmitter to become idleUwe Kleine-König
Without this patch the driver waits ~1 ms for the UART to become idle. At 115200n8 this time is (theoretically) enough to transfer 11.5 characters (= 115200 bits/s / (10 Bits/char) * 1ms). As the mxs-auart has a fifo size of 16 characters the clock is gated too early. The problem is worse for lower baud rates. This only happens to really shut down the transmitter in the middle of a transfer if /dev/ttyAPPx isn't opened in userspace (e.g. by a getty) but was at least once (because the bootloader doesn't disable the transmitter). So increase the timeout to 20 ms which should be enough for 9600n8, too. Moreover skip gating the clock if the timeout is elapsed. Cc: stable@vger.kernel.org # v2.6.39+ Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-07-26serial/mxs-auart: fix race condition in interrupt handlerUwe Kleine-König
The handler needs to ack the pending events before actually handling them. Otherwise a new event might come in after it it considered non-pending or handled and is acked then without being handled. So this event is only noticed when the next interrupt happens. Without this patch an i.MX28 based machine running an rt-patched kernel regularly hangs during boot. Cc: stable@vger.kernel.org # v2.6.39+ Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-07-24drivers/tty/serial: don't use devm_pinctrl_get_select_default() in probeWolfram Sang
Since commit ab78029 (drivers/pinctrl: grab default handles from device core), we can rely on device core for setting the default pins. Compile tested only. Acked-by: Linus Walleij <linus.walleij@linaro.org> (personally at LCE13) Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-05-07Merge tag 'dt-for-linus-2' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM SoC device tree updates (part 2) from Arnd Bergmann: "These are mostly new device tree bindings for existing drivers, as well as changes to the device tree source files to add support for those devices, and a couple of new boards, most notably Samsung's Exynos5 based Chromebook. The changes depend on earlier platform specific updates and touch the usual platforms: omap, exynos, tegra, mxs, mvebu and davinci." * tag 'dt-for-linus-2' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (169 commits) ARM: exynos: dts: cros5250: add EC device ARM: dts: Add sbs-battery for exynos5250-snow ARM: dts: Add i2c-arbitrator bus for exynos5250-snow ARM: dts: add mshc controller node for Exynos4x12 SoCs ARM: dts: Add chip-id controller node on Exynos4/5 SoC ARM: EXYNOS: Create virtual I/O mapping for Chip-ID controller using device tree ARM: davinci: da850-evm: add SPI flash support ARM: davinci: da850: override SPI DT node device name ARM: davinci: da850: add SPI1 DT node spi/davinci: add DT binding documentation spi/davinci: no wildcards in DT compatible property ARM: dts: mvebu: Convert mvebu device tree files to 64 bits ARM: dts: mvebu: introduce internal-regs node ARM: dts: mvebu: Convert all the mvebu files to use the range property ARM: dts: mvebu: move all peripherals inside soc ARM: dts: mvebu: fix cpus section indentation ARM: davinci: da850: add EHRPWM & ECAP DT node ARM/dts: OMAP3: fix pinctrl-single configuration ARM: dts: Add OMAP3430 SDP NOR flash memory binding ARM: dts: Add NOR flash bindings for OMAP2420 H4 ...
2013-04-22serial: mxs: drop superfluous {get|put}_deviceWolfram Sang
Driver core already takes care of refcounting, no need to do this on driver level again. Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-04-22serial: mxs: fix buffer overflowWolfram Sang
SMATCH correctly found an off-by-one error: drivers/tty/serial/mxs-auart.c:889 auart_console_write() error: buffer overflow 'auart_port' 5 <= 5 Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-04-04serial: mxs-auart: move to use generic DMA helperShawn Guo
With the generic DMA device tree helper supported by mxs-dma driver, client devices only need to call dma_request_slave_channel() for requesting a DMA channel from dmaengine. Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Reviewed-by: Arnd Bergmann <arnd@arndb.de>
2013-01-25Merge 3.8-rc5 into tty-nextGreg Kroah-Hartman
This resolves a number of tty driver merge issues found in linux-next Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-01-16TTY: switch tty_flip_buffer_pushJiri Slaby
Now, we start converting tty buffer functions to actually use tty_port. This will allow us to get rid of the need of tty in many call sites. Only tty_port will needed and hence no more tty_port_tty_get in those paths. Now, the one where most of tty_port_tty_get gets removed: tty_flip_buffer_push. IOW we also closed all the races in drivers not using tty_port_tty_get at all yet. Also we move tty_flip_buffer_push declaration from include/linux/tty.h to include/linux/tty_flip.h to all others while we are changing it anyway. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-01-16TTY: switch tty_insert_flip_stringJiri Slaby
Now, we start converting tty buffer functions to actually use tty_port. This will allow us to get rid of the need of tty in many call sites. Only tty_port will needed and hence no more tty_port_tty_get in those paths. tty_insert_flip_string this time. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-01-16serial: mxs-auart: Fix typo in sanity checkThomas Jarosch
Detected by cppcheck: [others/linux/drivers/tty/serial/mxs-auart.c:553]: (style) Same expression on both sides of '||'. Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-01-16serial: mxs-auart: Index is unsignedfabio.estevam@freescale.com
Fix the following warning when building with W=1 option: drivers/tty/serial/mxs-auart.c: In function 'mxs_auart_tx_chars': drivers/tty/serial/mxs-auart.c:272:10: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Acked-by: Marek Vasut <marex@denx.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-01-16mxs: uart: fix setting RTS from softwareSteffen Trumtrar
With the patch "serial: mxs-auart: fix the wrong RTS hardware flow control" the mainline mxs-uart driver now sets RTSEN only when hardware flow control is enabled via software. It is not possible any longer to set RTS manually via software. However, the manual modification is a valid operation. Regain the possibility to set RTS via software and only set RTSEN when hardware flow control is explicitly enabled via settermios cflag CRTSCTS. Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de> Cc: stable <stable@vger.kernel.org> Reviewed-by: Huang Shijie <b32955@freescale.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-11-26serial: mxs-auart: unmap the scatter list before we copy the dataHuang Shijie
We should first unmap the DMA scatter list for receiving data, and then copy the data from the DMA buffer. The old code misses unmap the scatter list for RX. This patch fixes it. Signed-off-by: Huang Shijie <b32955@freescale.com> Tested-by: Lauri Hintsala <lauri.hintsala@bluegiga.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>