aboutsummaryrefslogtreecommitdiff
path: root/drivers/tty/serial
AgeCommit message (Collapse)AuthorFilesLines
2014-07-10serial: tegra: update tx_circular buffer only when TX_DMA is in progressPradeep Goudagunta1-0/+3
When channel is require to stop transmit then update the Tx circular buffer only when DMA based transfer is in progress. If there is no DMA based transfer then no need to update the Tx buffer. Signed-off-by: Pradeep Goudagunta <[email protected]> Signed-off-by: Laxman Dewangan <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-10serial: lpc32xx uart module can't do consoleArnd Bergmann1-1/+1
Every uart driver that provides a console driver needs to be built-in for the console code to work, we get a build error for modular console drivers. This changes the SERIAL_HS_LPC32XX_CONSOLE symbol to depend on the SERIAL_HS_LPC32XX driver being built-in, just like we do for all the other uart drivers. Signed-off-by: Arnd Bergmann <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-10serial: pxa: fix build with !SERIAL_PXA_CONSOLEArnd Bergmann1-1/+1
When CONFIG_SERIAL_PXA_CONSOLE is disabled, the serial_pxa_get_poll_char and serial_pxa_put_poll_char functions are not defined, and we can't reference them. Signed-off-by: Arnd Bergmann <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-10serial/arc: Enable DT based earlyconVineet Gupta1-0/+1
This allows a param less earlycon to pick up the earlyconsole from chosen/stdout-path Signed-off-by: Vineet Gupta <[email protected]> Reviewed-by: Rob Herring <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-10serial/arc: inline the probe helperVineet Gupta1-50/+40
Signed-off-by: Vineet Gupta <[email protected]> Reviewed-by: Rob Herring <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-10serial/arc: remove last remanants of platform dataVineet Gupta1-16/+6
Signed-off-by: Vineet Gupta <[email protected]> Reviewed-by: Rob Herring <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-10serial/arc: remove earlyprintk support and switch to earlyconVineet Gupta1-75/+12
Signed-off-by: Vineet Gupta <[email protected]> Reviewed-by: Rob Herring <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-10serial/arc: Use generic earlycon infrastructureVineet Gupta2-0/+31
With this change both earlyprintk and earlycon coexist We switch over to latter in next patch Signed-off-by: Vineet Gupta <[email protected]> Reviewed-by: Rob Herring <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-10serial/arc: Remove the workaround for legacy ISSVineet Gupta1-14/+0
Signed-off-by: Vineet Gupta <[email protected]> Reviewed-by: Rob Herring <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-10serial/arc: Refactor by referencing to uart_port where possibleVineet Gupta1-86/+69
The ARC UART MMIO helpers would take arc_uart_port and then reference generic uart_port->membase member. So change them to difrectly refer to uart_port and fix call sites accordingly. This removes the need for to_arc_port() converion almost eveeywhere and makes code a bit easier to read. Signed-off-by: Vineet Gupta <[email protected]> Reviewed-by: Rob Herring <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-10serial/arc: use uart_console_write() helperVineet Gupta1-14/+4
Signed-off-by: Vineet Gupta <[email protected]> Reviewed-by: Rob Herring <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-10serial: 8250_dw: add ability to handle the peripheral clockHeiko Stübner1-3/+28
First try to find the named clock variants then fall back to the already existing handling of a nameless declared baudclk. This also adds the missing documentation for this already existing variant. Signed-off-by: Heiko Stuebner <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-10serial: 8250_dw: use UPF_* constants when define flagsAndy Shevchenko1-1/+1
The flags member has upf_t type and corresponding macros to define them. This patch converts ASYNC_SKIP_TEST to UPF_SKIP_TEST in 8250_dw.c. Otherwise we got a sparse warning: drivers/tty/serial/8250/8250_dw.c:302:46: warning: restricted upf_t degrades to integer drivers/tty/serial/8250/8250_dw.c:302:62: warning: restricted upf_t degrades to integer drivers/tty/serial/8250/8250_dw.c:302:26: warning: incorrect type in assignment (different base types) drivers/tty/serial/8250/8250_dw.c:302:26: expected restricted upf_t [usertype] flags drivers/tty/serial/8250/8250_dw.c:302:26: got unsigned int Signed-off-by: Andy Shevchenko <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-10serial: 8250_dw: clock rate handling for all ACPI platformsHeikki Krogerus1-75/+28
This replaces the Baytrail specific custom set_termios hook with a more generic one where the clock framework is used to set the rate. The method also doesn't need to be limited to just Baytrail, so it's used with all ACPI platforms. Signed-off-by: Heikki Krogerus <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-10serial: samsung: Use %pa to print 'resource_size_t' typeFabio Estevam1-2/+2
When building multi_v7_defconfig with CONFIG_ARM_LPAE=y the following warning is seen: drivers/tty/serial/samsung.c: In function 's3c24xx_serial_init_port': drivers/tty/serial/samsung.c:1229:2: warning: format '%x' expects argument of type 'unsigned int', but argument 2 has type 'resource_size_t' [-Wformat] Use %pa to print 'resource_size_t' type to fix the warning. Reported-by: Olof's autobuilder <[email protected]> Signed-off-by: Fabio Estevam <[email protected]> Reviewed-by: Jingoo Han <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-09tty: serial: msm_serial.c: Cleaning up uninitialized variablesRickard Strandqvist1-1/+1
There is a risk that the variable will be used without being initialized. This was largely found by using a static code analysis program called cppcheck. Signed-off-by: Rickard Strandqvist <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-09serial: sirf: transfer more bytes once to decrease interruptsQipan Li2-2/+3
the current codes send 1 bytes, then after getting TX done interrupt, send subsequent bytes. it causes redundant interrupts. for example, if we have 3 bytes in TX buffer, the TX flow is: 1. send 1 byte 2. get TX down interrupt 3. send the left 2 bytes 4. get TX down interrupt this patch moves to send more bytes and decrease interrupts, the new flow is: 1. send 3 bytes 2. get TX down interrupt Signed-off-by: Qipan Li <[email protected]> Signed-off-by: Barry Song <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-09tty: serial: men_z135_uart: Wakeup UART after transmittingJohannes Thumshirn1-3/+3
Call uart_write_wakeup() after writing the hardware FIFO and updateing the FIFO pointers. This fixes high latency and jitter on PPP over Serial links. Reported-by: Jun Shih <[email protected]> Tested-by: Jun Shih <[email protected]> Signed-off-by: Johannes Thumshirn <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-09serial: treewide: Remove empty implementations of enable_ms()Alexander Shiyan40-239/+0
Signed-off-by: Alexander Shiyan <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-09serial: core: Make enable_ms() optionalAlexander Shiyan1-6/+11
This patch makes enable_ms() optional, so we can eliminate a lot of empty enable_ms() implementations from driver code. Signed-off-by: Alexander Shiyan <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-09serial: samsung: no more support for S5PC100 SoCKukjin Kim1-2/+1
This patch removes s5pc100 related serial. Signed-off-by: Kukjin Kim <[email protected]> Cc: Greg Kroah-Hartman <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-09serial: samsung: no more support for S5P6440 and S5P6450 SoCsKukjin Kim2-2/+0
This patch removes s5p64x0 related serial because of removing support for s5p64x0 SoCs. Signed-off-by: Kukjin Kim <[email protected]> Cc: Greg Kroah-Hartman <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-09serial: samsung: Consider DT alias when probing portsTomasz Figa1-3/+10
Current driver code relies on probe order of particular samsung-uart instances, which makes it impossible to get proper initialization of ports when not all ports are available on board, not even saying of deterministic device naming. This patch fixes this on DT-enabled systems by using DT aliases for ports as instance ID, if specified, or falling back to legacy method otherwise to provide backwards compatibility. Signed-off-by: Tomasz Figa <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-09serial: amba-pl010: Use devres APIsTushar Behera1-32/+16
Migrating to use devres managed APIs devm_kzalloc, devm_ioremap and devm_clk_get. Signed-off-by: Tushar Behera <[email protected]> Reviewed-by: Daniel Thompson <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-09serial: amba-pl011: Remove redundant labelTushar Behera1-20/+10
The label 'out' is only used to return the error code. We can return the error code directly and remove 'out' label. Signed-off-by: Tushar Behera <[email protected]> Reviewed-by: Daniel Thompson <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-07-09serial: samsung: Remove redundant labelTushar Behera1-4/+1
probe_err label only returns the error code. This label can be removed and the error code can be returned directly. Signed-off-by: Tushar Behera <[email protected]> Reviewed-by: Sachin Kamat <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-06-26of: Migrate of_find_node_by_name() users to for_each_node_by_name()Grant Likely1-6/+3
There are a bunch of users open coding the for_each_node_by_name() by calling of_find_node_by_name() directly instead of using the macro. This is getting in the way of some cleanups, and the possibility of removing of_find_node_by_name() entirely. Clean it up so that all the users are consistent. Signed-off-by: Grant Likely <[email protected]> Cc: Rob Herring <[email protected]> Cc: Benjamin Herrenschmidt <[email protected]> Cc: "Rafael J. Wysocki" <[email protected]> Cc: Greg Kroah-Hartman <[email protected]> Cc: Takashi Iwai <[email protected]>
2014-06-26of: Enable console on serial ports specified by /chosen/stdout-pathGrant Likely1-0/+3
If the devicetree specifies a serial port as a stdout device, then the kernel can use it as the default console if nothing else was selected on the command line. For any serial port that uses the uart_add_one_port() feature, the uart_add_one_port() has all the information needed to automatically enable the console device, which is what this patch does. With this change applied, a device tree platform can be booted without any console= parameters on the command line and the kernel will still be able to determine its console. Tested on QEMU Versatile model and i.MX Signed-off-by: Grant Likely <[email protected]> Tested-by: Sascha Hauer <[email protected]>
2014-06-25Merge tag 'fixes-for-linus' of ↵Linus Torvalds1-1/+1
git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM SoC fixes from Arnd Bergmann: "A new set of bug fixes for 3.16, containing patches for seven platforms: at91: - drivers/misc fix for Kconfig PWM symbol - correction of several values in DT after conversion to CCF - fix at91sam9261/at91sam9261ek mistake in slow crystal vs. slow RC osc imx: - Use GPIO for card CD/WP on imx51-babbage and eukrea-mbimxsd51, because controller base CD/WP is not working in esdhc driver due to runtime PM support - A couple of random ventana gw5xxx board fixes - Add IMX_IPUV3_CORE back to defconfig, which gets lost when moving IPUv3 driver out of staging tree - Fix enet/fec clock selection on imx6sl - Fix display node on imx53-m53evk board - A couple of Cubox-i updates from Russell, which were omitted from the merge window due to dependency integrator: - fix an OF-related regression against 3.15 mvebu: - mvebu (v7) - Fix broken SoC ID detection - Select ARM_CPU_SUSPEND for v7 - Remove armada38x compatible string (no users yet) - Enable Dove SoC in mvebu_v7_defconfig - kirkwood - Fix phy-connection-type on GuruPlug board qcom: - enable gsbi driver in defconfig - fix section mismatch warning in serial driver samsung: - use WFI macro in platform_do_lowpower because exynos cpuhotplug includes a hardcoded WFI instruction and it causes compile error in Thumb-2 mode. - fix GIC reg sizes for exynos4 SoCs - remove reset timer counter value during boot and resume for mct to fix a big jump in printk timestamps - fix pm code to check cortex-A9 for another exynos SoCs - don't rely on firmware's secondary_cpu_start for mcpm sti: - Ethernet clocks were wrongly defined for STiH415/416 platforms - STiH416 B2020 revision E DTS file name contained uppercase, change to lowercase" * tag 'fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (33 commits) ARM: at91/dt: sam9261: remove slow RC osc ARM: at91/dt: define sam9261ek slow crystal frequency ARM: at91/dt: sam9261: correctly define mainck ARM: at91/dt: sam9n12: correct PLLA ICPLL and OUT values ARM: at91/dt: sam9x5: correct PLLA ICPLL and OUT values misc: atmel_pwm: fix Kconfig symbols ARM: integrator: fix OF-related regression ARM: mvebu: Fix the improper use of the compatible string armada38x using a wildcard ARM: dts: kirkwood: fix phy-connection-type for Guruplug ARM: EXYNOS: Don't rely on firmware's secondary_cpu_start for mcpm ARM: dts: imx51-eukrea-mbimxsd51-baseboard: unbreak esdhc. ARM: dts: imx51-babbage: Fix esdhc setup ARM: dts: mx5: Move the display out of soc {} node ARM: dts: mx5: Fix IPU port node placement ARM: mvebu: select ARM_CPU_SUSPEND for Marvell EBU v7 platforms ARM: mvebu: Fix broken SoC ID detection ARM: imx_v6_v7_defconfig: Enable CONFIG_IMX_IPUV3_CORE ARM: multi_v7_defconfig: Add QCOM GSBI driver ARM: stih41x: Rename stih416-b2020-revE.dts to stih416-b2020e.dts tty: serial: msm: Fix section mismatch warning ...
2014-06-19tty/serial: fix 8250 early console option passing to regular consoleRob Herring2-2/+5
In the conversion to generic early console, the passing of options from the early 8250 console to the regular ttyS console was broken. This resulted in the baud rate changing when switching consoles during boot. This feature allows specifying a single console option on the kernel command line rather than both an early console and regular serial tty console. It would be nice to generalize this feature. However, it only works if the correct baud rate can be probed early which is not the case on many platforms which have non-standard UART clock rates. So for now, this is left as an 8250 specific feature. Reported-and-tested-by: Tony Luck <[email protected]> Signed-off-by: Rob Herring <[email protected]> Cc: Jiri Slaby <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-06-19serial: Fix IGNBRK handlingPeter Hurley34-32/+44
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 <[email protected]> Signed-off-by: Peter Hurley <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-06-18tty: serial: msm: Fix section mismatch warningKumar Gala1-1/+1
WARNING: drivers/tty/built-in.o(.data+0x3544): Section mismatch in reference from the variable msm_platform_driver to the function .init.text:msm_serial_probe() The variable msm_platform_driver references the function __init msm_serial_probe() If the reference is valid then annotate the variable with __init* or __refdata (see linux/init.h) or name the variable: *_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_console Signed-off-by: Kumar Gala <[email protected]> Signed-off-by: Arnd Bergmann <[email protected]>
2014-06-17serial: samsung: Fix build errorSachin Kamat1-1/+1
Fixes the following build error due to a typo introduced by commit e4ac92df27 ("serial: samsung: Neaten dbg uses"): drivers/tty/serial/samsung.c:69:26: error: ‘buf’ undeclared (first use in this function) Reported-by: Arun Kumar K <[email protected]> Signed-off-by: Sachin Kamat <[email protected]> Signed-off-by: Arnd Bergmann <[email protected]> Signed-off-by: Christian Engelmayer <[email protected]> Acked-by: Joe Perches <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-06-04Merge branch 'irq-core-for-linus' of ↵Linus Torvalds1-4/+4
git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip into next Pull core irq updates from Thomas Gleixner: "The irq department delivers: - Another tree wide update to get rid of the horrible create_irq interface along with its even more horrible variants. That also gets rid of the last leftovers of the initial sparse irq hackery. arch/driver specific changes have been either acked or ignored. - A fix for the spurious interrupt detection logic with threaded interrupts. - A new ARM SoC interrupt controller - The usual pile of fixes and improvements all over the place" * 'irq-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (40 commits) Documentation: brcmstb-l2: Add Broadcom STB Level-2 interrupt controller binding irqchip: brcmstb-l2: Add Broadcom Set Top Box Level-2 interrupt controller genirq: Improve documentation to match current implementation ARM: iop13xx: fix msi support with sparse IRQ genirq: Provide !SMP stub for irq_set_affinity_notifier() irqchip: armada-370-xp: Move the devicetree binding documentation irqchip: gic: Use mask field in GICC_IAR genirq: Remove dynamic_irq mess ia64: Use irq_init_desc genirq: Replace dynamic_irq_init/cleanup genirq: Remove irq_reserve_irq[s] genirq: Replace reserve_irqs in core code s390: Avoid call to irq_reserve_irqs() s390: Remove pointless arch_show_interrupts() s390: pci: Check return value of alloc_irq_desc() proper sh: intc: Remove pointless irq_reserve_irqs() invocation x86, irq: Remove pointless irq_reserve_irqs() call genirq: Make create/destroy_irq() ia64 private tile: Use SPARSE_IRQ tile: pci: Use irq_alloc/free_hwirq() ...
2014-06-04Merge tag 'devicetree-for-3.16' of ↵Linus Torvalds2-0/+29
git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux into next Pull DeviceTree updates from Rob Herring: - Another round of clean-up of FDT related code in architecture code. This removes knowledge of internal FDT details from most architectures except powerpc. - Conversion of kernel's custom FDT parsing code to use libfdt. - DT based initialization for generic serial earlycon. The introduction of generic serial earlycon support went in through the tty tree. - Improve the platform device naming for DT probed devices to ensure unique naming and use parent names instead of a global index. - Fix a race condition in of_update_property. - Unify the various linker section OF match tables and fix several function prototype errors. - Update platform_get_irq_byname to work in deferred probe cases. - 2 binding doc updates * tag 'devicetree-for-3.16' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux: (58 commits) of: handle NULL node in next_child iterators of/irq: provide more wrappers for !CONFIG_OF devicetree: bindings: Document micrel vendor prefix dt: bindings: dwc2: fix required value for the phy-names property of_pci_irq: kill useless variable in of_irq_parse_pci() of/irq: do irq resolution in platform_get_irq_byname() of: Add a testcase for of_find_node_by_path() of: Make of_find_node_by_path() handle /aliases of: Create unlocked version of for_each_child_of_node() lib: add glibc style strchrnul() variant of: Handle memory@0 node on PPC32 only pci/of: Remove dead code of: fix race between search and remove in of_update_property() of: Use NULL for pointers of: Stop naming platform_device using dcr address of: Ensure unique names without sacrificing determinism tty/serial: pl011: add DT based earlycon support of/fdt: add FDT serial scanning for earlycon of/fdt: add FDT address translation support serial: earlycon: add DT support ...
2014-06-03Merge branch 'locking-core-for-linus' of ↵Linus Torvalds1-2/+2
git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip into next Pull core locking updates from Ingo Molnar: "The main changes in this cycle were: - reduced/streamlined smp_mb__*() interface that allows more usecases and makes the existing ones less buggy, especially in rarer architectures - add rwsem implementation comments - bump up lockdep limits" * 'locking-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (33 commits) rwsem: Add comments to explain the meaning of the rwsem's count field lockdep: Increase static allocations arch: Mass conversion of smp_mb__*() arch,doc: Convert smp_mb__*() arch,xtensa: Convert smp_mb__*() arch,x86: Convert smp_mb__*() arch,tile: Convert smp_mb__*() arch,sparc: Convert smp_mb__*() arch,sh: Convert smp_mb__*() arch,score: Convert smp_mb__*() arch,s390: Convert smp_mb__*() arch,powerpc: Convert smp_mb__*() arch,parisc: Convert smp_mb__*() arch,openrisc: Convert smp_mb__*() arch,mn10300: Convert smp_mb__*() arch,mips: Convert smp_mb__*() arch,metag: Convert smp_mb__*() arch,m68k: Convert smp_mb__*() arch,m32r: Convert smp_mb__*() arch,ia64: Convert smp_mb__*() ...
2014-06-03Merge tag 'tty-3.16-rc1' of ↵Linus Torvalds35-1000/+3720
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty into next Pull tty/serial driver updates from Greg KH: "Here is the big tty / serial driver pull request for 3.16-rc1. A variety of different serial driver fixes and updates and additions, nothing huge, and no real major core tty changes at all. All have been in linux-next for a while" * tag 'tty-3.16-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty: (84 commits) Revert "serial: imx: remove the DMA wait queue" serial: kgdb_nmi: Improve console integration with KDB I/O serial: kgdb_nmi: Switch from tasklets to real timers serial: kgdb_nmi: Use container_of() to locate private data serial: cpm_uart: No LF conversion in put_poll_char() serial: sirf: Fix compilation failure console: Remove superfluous readonly check console: Use explicit pointer type for vc_uni_pagedir* fields vgacon: Fix & cleanup refcounting ARM: tty: Move HVC DCC assembly to arch/arm tty/hvc/hvc_console: Fix wakeup of HVC thread on hvc_kick() drivers/tty/n_hdlc.c: replace kmalloc/memset by kzalloc vt: emulate 8- and 24-bit colour codes. printk/of_serial: fix serial console cessation part way through boot. serial: 8250_dma: check the result of TX buffer mapping serial: uart: add hw flow control support configuration tty/serial: at91: add interrupts for modem control lines tty/serial: at91: use mctrl_gpio helpers tty/serial: Add GPIOLIB helpers for controlling modem lines ARM: at91: gpio: implement get_direction ...
2014-06-02Merge tag 'drivers-for-3.16' of ↵Linus Torvalds2-51/+2
git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc into next Pull ARM SoC driver changes from Olof Johansson: "SoC-near driver changes that we're merging through our tree. Mostly because they depend on other changes we have staged, but in some cases because the driver maintainers preferred that we did it this way. This contains a largeish cleanup series of the omap_l3_noc bus driver, cpuidle rework for Exynos, some reset driver conversions and a long branch of TI EDMA fixes and cleanups, with more to come next release. The TI EDMA cleanups is a shared branch with the dmaengine tree, with a handful of Davinci-specific fixes on top. After discussion at last year's KS (and some more on the mailing lists), we are here adding a drivers/soc directory. The purpose of this is to keep per-vendor shared code that's needed by different drivers but that doesn't fit into the MFD (nor drivers/platform) model. We expect to keep merging contents for this hierarchy through arm-soc so we can keep an eye on what the vendors keep adding here and not making it a free-for-all to shove in crazy stuff" * tag 'drivers-for-3.16' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (101 commits) cpufreq: exynos: Fix driver compilation with ARCH_MULTIPLATFORM tty: serial: msm: Remove direct access to GSBI power: reset: keystone-reset: introduce keystone reset driver Documentation: dt: add bindings for keystone pll control controller Documentation: dt: add bindings for keystone reset driver soc: qcom: fix of_device_id table ARM: EXYNOS: Fix kernel panic when unplugging CPU1 on exynos ARM: EXYNOS: Move the driver to drivers/cpuidle directory ARM: EXYNOS: Cleanup all unneeded headers from cpuidle.c ARM: EXYNOS: Pass the AFTR callback to the platform_data ARM: EXYNOS: Move S5P_CHECK_SLEEP into pm.c ARM: EXYNOS: Move the power sequence call in the cpu_pm notifier ARM: EXYNOS: Move the AFTR state function into pm.c ARM: EXYNOS: Encapsulate the AFTR code into a function ARM: EXYNOS: Disable cpuidle for exynos5440 ARM: EXYNOS: Encapsulate boot vector code into a function for cpuidle ARM: EXYNOS: Pass wakeup mask parameter to function for cpuidle ARM: EXYNOS: Remove ifdef for scu_enable in pm ARM: EXYNOS: Move scu_enable in the cpu_pm notifier ARM: EXYNOS: Use the cpu_pm notifier for pm ...
2014-05-30Merge tag 'qcom-drivers-for-3.16-2' of ↵Olof Johansson2-51/+2
git://git.kernel.org/pub/scm/linux/kernel/git/galak/linux-qcom into next/drivers Merge "Qualcomm ARM Based driver Updates for v3.16-2" from Kumar Gala: * Updated MSM uart driver to not access GSBI control registers * tag 'qcom-drivers-for-3.16-2' of git://git.kernel.org/pub/scm/linux/kernel/git/galak/linux-qcom: tty: serial: msm: Remove direct access to GSBI Signed-off-by: Olof Johansson <[email protected]>
2014-05-29Revert "serial: imx: remove the DMA wait queue"Greg Kroah-Hartman1-14/+28
This reverts commit e2f2786606d49d3aae545c61c04757a64cf7e5f0. Huang reports that this patch is broken and should be reverted. Cc: Huang Shijie <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-05-29serial: kgdb_nmi: Improve console integration with KDB I/ODaniel Thompson1-3/+13
kgdb_nmi_tty_enabled is used for two unrelated purposes, namely to suppress normal TTY input handling and to suppress console output (although it has no effect at all on TTY output). A much better way to handle muting the console is to not have to mute it in the first place! That's what this patch does. Signed-off-by: Daniel Thompson <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-05-29serial: kgdb_nmi: Switch from tasklets to real timersDaniel Thompson1-21/+9
kgdb_nmi uses tasklets on the assumption they will not be scheduled until the next timer tick. This assumption is invalid and can lead to live lock, continually servicing the kgdb_nmi tasklet. This is fixed by using the timer API instead. Signed-off-by: Daniel Thompson <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-05-29serial: kgdb_nmi: Use container_of() to locate private dataDaniel Thompson1-8/+5
This corrects a crash in kgdb_nmi_tty_shutdown() which occurs when the function is called with port->tty set to NULL. All conversions between struct tty_port and struct kgdb_nmi_tty_priv have been switched to direct calls to container_of() to improve code clarity and consistancy. Signed-off-by: Daniel Thompson <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-05-29serial: cpm_uart: No LF conversion in put_poll_char()Daniel Thompson1-4/+4
In (c7d44a02a serial_core: Commonalize crlf when working w/ a non open console port) the core was modified to make the UART poll_put_char() automatically convert LF to CRLF. This driver's poll_put_char() adds a CR itself and this was not disabled by the above patch meaning currently it sends two CR characters. The code to issue a character is shared by the console write code (where driver must do LF to CRLF conversion, although it can make use of the uart_console_write() helper function) and the poll_put_char (where driver must not do the conversion). For that reason we add a flag rather than simply rip out the conversion code. Signed-off-by: Daniel Thompson <[email protected]> Cc: Doug Anderson <[email protected]> Cc: Jiri Slaby <[email protected]> Cc: Christophe Leroy <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-05-29serial: sirf: Fix compilation failureDaniel Thompson1-1/+1
After 07d410e0) serial: sirf: fix spinlock deadlock issue it is no longer possiblet to compile this driver. The rename of one of the spinlocks is faulty. After looking at the original patch I believe this is the correct fix. Compile tested using ARM's multi_v7_defconfig Reported-by: Stephen Rothwell <[email protected]> Cc: Jiri Slaby <[email protected]> Cc: Qipan Li <[email protected]> Signed-off-by: Daniel Thompson <[email protected]> Acked-by: Barry Song <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-05-29tty: serial: msm: Remove direct access to GSBIAndy Gross2-51/+2
This patch removes direct access of the GSBI registers. GSBI configuration should be done through the GSBI driver directly. Signed-off-by: Andy Gross <[email protected]> Signed-off-by: Kumar Gala <[email protected]>
2014-05-28printk/of_serial: fix serial console cessation part way through boot.Stephen Chivers1-0/+1
Commit 5f5c9ae56c38942623f69c3e6dc6ec78e4da2076 "serial_core: Unregister console in uart_remove_one_port()" fixed a crash where a serial port was removed but not deregistered as a console. There is a side effect of that commit for platforms having serial consoles and of_serial configured (CONFIG_SERIAL_OF_PLATFORM). The serial console is disabled midway through the boot process. This cessation of the serial console affects PowerPC computers such as the MVME5100 and SAM440EP. The sequence is: bootconsole [udbg0] enabled .... serial8250/16550 driver initialises and registers its UARTS, one of these is the serial console. console [ttyS0] enabled .... of_serial probes "platform" devices, registering them as it goes. One of these is the serial console. console [ttyS0] disabled. The disabling of the serial console is due to: a. unregister_console in printk not clearing the CONS_ENABLED bit in the console flags, even though it has announced that the console is disabled; and b. of_platform_serial_probe in of_serial not setting the port type before it registers with serial8250_register_8250_port. This patch ensures that the serial console is re-enabled when of_serial registers a serial port that corresponds to the designated console. Signed-off-by: Stephen Chivers <[email protected]> Tested-by: Stephen Chivers <[email protected]> Acked-by: Geert Uytterhoeven <[email protected]> [unregister_console] Cc: stable <[email protected]> # 3.15 === The above failure was identified in Linux-3.15-rc2. Tested using MVME5100 and SAM440EP PowerPC computers with kernels built from Linux-3.15-rc5 and tty-next. The continued operation of the serial console is vital for computers such as the MVME5100 as that Single Board Computer does not have any grapical/display hardware. Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-05-28serial: 8250_dma: check the result of TX buffer mappingHeikki Krogerus1-5/+12
Using dma_mapping_error() to make sure the mapping did not fail. Signed-off-by: Heikki Krogerus <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-05-28serial: uart: add hw flow control support configurationMurali Karicheri3-5/+17
8250 uart driver currently supports only software assisted hw flow control. The software assisted hw flow control maintains a hw_stopped flag in the tty structure to stop and start transmission and use modem status interrupt for the event to drive the handshake signals. This is not needed if hw has flow control capabilities. This patch adds a DT attribute for enabling hw flow control for a uart port. Also skip stop and start if this flag is present in flag field of the port structure. Signed-off-by: Murali Karicheri <[email protected]> CC: Rob Herring <[email protected]> CC: Pawel Moll <[email protected]> CC: Mark Rutland <[email protected]> CC: Ian Campbell <[email protected]> CC: Kumar Gala <[email protected]> CC: Randy Dunlap <[email protected]> CC: Jiri Slaby <[email protected]> CC: Santosh Shilimkar <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2014-05-28tty/serial: at91: add interrupts for modem control linesRichard Genoud1-3/+122
Handle CTS/DSR/RI/DCD GPIO interrupts in atmel_serial. Signed-off-by: Richard Genoud <[email protected]> Acked-by: Greg Kroah-Hartman <[email protected]> Acked-by: Nicolas Ferre <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>