Skip to content
Snippets Groups Projects
  1. Sep 21, 2011
  2. Sep 14, 2011
  3. Aug 29, 2011
    • Takashi YOSHII's avatar
      serial: sh-sci: report CTS as active for get_mctrl · 4480a688
      Takashi YOSHII authored
      
      sh-sci.c sets hardware up and then let the HW do all flow controls.
      There is no software code, nor needs to get/set real CTS signal.
      
      But, when turning CRTSCTS on through termios, uart_set_termios() in
      serial_core.c checks CTS, and stops TX if it is inactive at the moment.
      
      Because sci_get_mctrl() returns a fixed value DTR|RTS|DSR but CTS,
      the sequence
        open -> set CRTSCTS -> write
      hit the case and stop working, no more outputs.
      
      This patch makes sci_get_mctrl() report CTS in addition.
      
      Signed-off-by: default avatarTakashi YOSHII <takashi.yoshii.zj@renesas.com>
      Signed-off-by: default avatarPaul Mundt <lethal@linux-sh.org>
      4480a688
  4. Aug 24, 2011
  5. Aug 23, 2011
    • Nick Pelly's avatar
      omap-serial: Allow IXON and IXOFF to be disabled. · b280a97d
      Nick Pelly authored
      
      Fixes logic bug that software flow control cannot be disabled, because
      serial_omap_configure_xonxoff() is not called if both IXON and IXOFF bits
      are cleared.
      
      Signed-off-by: default avatarNick Pelly <npelly@google.com>
      Acked-by: default avatarGovindraj.R <govindraj.raja@ti.com>
      Tested-by: default avatarGovindraj.R <govindraj.raja@ti.com>
      Cc: stable <stable@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      b280a97d
    • Jiri Slaby's avatar
      TTY: serial, document ignoring of uart->ops->startup error · 0055197e
      Jiri Slaby authored
      
      When a user has SYS_ADMIN capabilities and uart->ops->startup returns
      an error in uart_startup, we silently drop the error. We then return 0
      and behave as if it didn't fail. (Not quite, since we set TTY_IO_ERROR
      bit and leave ASYNC_INITIALIZED bit cleared.)
      
      This all is to allow setserial to work with improperly configured or
      unconfigured ports. User can thus set port properties and reconfigure
      properly.
      
      This patch only documents this behavior.
      
      Signed-off-by: default avatarJiri Slaby <jslaby@suse.cz>
      Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
      Cc: Russel King <linux@arm.linux.org.uk>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      0055197e
    • Jiri Slaby's avatar
      TTY: pty, fix pty counting · 24d406a6
      Jiri Slaby authored
      tty_operations->remove is normally called like:
      queue_release_one_tty
       ->tty_shutdown
         ->tty_driver_remove_tty
           ->tty_operations->remove
      
      However tty_shutdown() is called from queue_release_one_tty() only if
      tty_operations->shutdown is NULL. But for pty, it is not.
      pty_unix98_shutdown() is used there as ->shutdown.
      
      So tty_operations->remove of pty (i.e. pty_unix98_remove()) is never
      called. This results in invalid pty_count. I.e. what can be seen in
      /proc/sys/kernel/pty/nr.
      
      I see this was already reported at:
        https://lkml.org/lkml/2009/11/5/370
      
      
      But it was not fixed since then.
      
      This patch is kind of a hackish way. The problem lies in ->install. We
      allocate there another tty (so-called tty->link). So ->install is
      called once, but ->remove twice, for both tty and tty->link. The fix
      here is to count both tty and tty->link and divide the count by 2 for
      user.
      
      And to have ->remove called, let's make tty_driver_remove_tty() global
      and call that from pty_unix98_shutdown() (tty_operations->shutdown).
      
      While at it, let's document that when ->shutdown is defined,
      tty_shutdown() is not called.
      
      Signed-off-by: default avatarJiri Slaby <jslaby@suse.cz>
      Cc: Alan Cox <alan@linux.intel.com>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: stable <stable@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      24d406a6
    • Al Cooper's avatar
      8250: Fix race condition in serial8250_backup_timeout(). · dbb3b1ca
      Al Cooper authored
      
      This is to fix an issue where output will suddenly become very slow.
      The problem occurs on 8250 UARTS with the hardware bug UART_BUG_THRE.
      
      BACKGROUND
      For normal UARTs (without UART_BUG_THRE): When the serial core layer
      gets new transmit data and the transmitter is idle, it buffers the
      data and calls the 8250s' serial8250_start_tx() routine which will
      simply enable the TX interrupt in the IER register and return. This
      should immediately fire a THRE interrupt and begin transmitting the
      data.
      For buggy UARTs (with UART_BUG_THRE): merely enabling the TX interrupt
      in IER does not necessarily generate a new THRE interrupt.
      Therefore, a background timer periodically checks to see if there is
      pending data, and starts transmission if that is the case.
      
      The bug happens on SMP systems when the system has nothing to transmit,
      the transmit interrupt is disabled and the following sequence occurs:
      - CPU0: The background timer routine serial8250_backup_timeout()
        starts and saves the state of the interrupt enable register (IER)
        and then disables all interrupts in IER. NOTE: The transmit interrupt
        (TI) bit is saved as disabled.
      - CPU1: The serial core gets data to transmit, grabs the port lock and
        calls serial8250_start_tx() which enables the TI in IER.
      - CPU0: serial8250_backup_timeout() waits for the port lock.
      - CPU1: finishes (with TI enabled) and releases the port lock.
      - CPU0: serial8250_backup_timeout() calls the interrupt routine which
        will transmit the next fifo's worth of data and then restores the
        IER from the previously saved value (TI disabled).
      At this point, as long as the serial core has more transmit data
      buffered, it will not call serial8250_start_tx() again and the
      background timer routine will slowly transmit the data.
      
      The fix is to have serial8250_start_tx() get the port lock before
      it saves the IER state and release it after restoring IER. This will
      prevent serial8250_start_tx() from running in parallel.
      
      Signed-off-by: default avatarAl Cooper <alcooperx@gmail.com>
      Cc: stable <stable@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      dbb3b1ca
    • Tomoya MORINAGA's avatar
      serial/8250_pci: delete duplicate data definition · dacacc3e
      Tomoya MORINAGA authored
      
      Data definiton "VendorID=10DB, device_id=800D" is already defined.
      This patch deletes the duplicate definition.
      
      Signed-off-by: default avatarTomoya MORINAGA <tomoya-linux@dsn.okisemi.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      dacacc3e
    • Eric Smith's avatar
      8250_pci: add support for Rosewill RC-305 4x serial port card · 44178176
      Eric Smith authored
      This patch adds support for the Rosewill RC-305 four-port PCI serial
      card, and probably any other four-port serial cards based on the
      Moschip MCS9865 chip, assuming that the EEPROM on the card was
      programmed in accordance with Table 6 of the MCS9865 EEPROM
      Application Note version 0.3 dated 16-May-2008, available from the
      Moschip web site (registration required).
      
      This patch is based on an earlier patch [1] for the SYBA 6x serial
      port card by Ira W. Snyder.
      
      [1]: http://www.gossamer-threads.com/lists/linux/kernel/1162435
      
      
      
      Signed-off-by: default avatarEric Smith <eric@brouhaha.com>
      Cc: stable <stable@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      44178176
    • Axel Lin's avatar
      tty: Add "spi:" prefix for spi modalias · 8c4074cd
      Axel Lin authored
      
      Since commit e0626e38 (spi: prefix modalias with "spi:"),
      the spi modalias is prefixed with "spi:".
      
      This patch adds "spi:" prefix and removes "-spi" suffix in the modalias.
      
      Signed-off-by: default avatarAxel Lin <axel.lin@gmail.com>
      Cc: stable <stable@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      8c4074cd
  6. Aug 22, 2011
  7. Aug 08, 2011
  8. Aug 07, 2011
  9. Aug 04, 2011
    • Grant Likely's avatar
      dt: remove of_alias_get_id() reference · 9e191b22
      Grant Likely authored
      
      of_alias_get_id() is broken and being reverted.  Remove the reference
      to it and replace with a single incrementing id number.
      
      There is no risk of regression here on the imx driver since the imx
      change to use of_alias_get_id() is commit 22698aa2, "serial/imx: add
      device tree probe support" which is new for v3.1, and it won't get
      used unless CONFIG_OF is enabled and the board is booted using a
      device tree.  A single incrementing integer is sufficient for now.
      
      Signed-off-by: default avatarGrant Likely <grant.likely@secretlab.ca>
      Acked-by: default avatarShawn Guo <shawn.guo@linaro.org>
      9e191b22
  10. Aug 03, 2011
  11. Aug 02, 2011
    • Magnus Damm's avatar
      serial: sh-sci: fix DMA build by including dma-mapping.h · 5beabc7f
      Magnus Damm authored
      
      Include dma-mapping.h to fix build of the sh-sci driver on
      SH-Mobile ARM (sh73a0) when CONFIG_SERIAL_SH_SCI_DMA=y:
      
      drivers/tty/serial/sh-sci.c: In function 'sci_rx_dma_release':
      drivers/tty/serial/sh-sci.c:1182:3: error: implicit declaration of function 'dma_free_coherent'
      drivers/tty/serial/sh-sci.c: In function 'work_fn_tx':
      drivers/tty/serial/sh-sci.c:1333:2: error: implicit declaration of function 'dma_sync_sg_for_device'
      drivers/tty/serial/sh-sci.c: In function 'sci_request_dma':
      drivers/tty/serial/sh-sci.c:1498:3: error: implicit declaration of function 'dma_map_sg'
      drivers/tty/serial/sh-sci.c:1527:3: error: implicit declaration of function 'dma_alloc_coherent'
      drivers/tty/serial/sh-sci.c:1527:10: warning: assignment makes pointer from integer without a cast
      make[3]: *** [drivers/tty/serial/sh-sci.o] Error 1
      make[2]: *** [drivers/tty/serial] Error 2
      make[1]: *** [drivers/tty] Error 2
      make: *** [drivers] Error 2
      
      Signed-off-by: default avatarMagnus Damm <damm@opensource.se>
      Tested-by: default avatarSimon Horman <horms@verge.net.au>
      Signed-off-by: default avatarPaul Mundt <lethal@linux-sh.org>
      5beabc7f
    • Paul Mundt's avatar
      serial: sh-sci: Fix up default regtype probing. · ad75b88a
      Paul Mundt authored
      
      Presently the default regtype probing inadvertently bails out due to an
      inverted error check. This fixes it up, and gets platforms without
      explicit regtype specifications working again.
      
      Reported-by: default avatarMagnus Damm <damm@opensource.se>
      Signed-off-by: default avatarPaul Mundt <lethal@linux-sh.org>
      ad75b88a
  12. Jul 26, 2011
  13. Jul 20, 2011
  14. Jul 18, 2011
  15. Jul 09, 2011
  16. Jul 08, 2011
  17. Jul 06, 2011
  18. Jul 04, 2011
  19. Jul 01, 2011
Loading