1. 23 7月, 2014 1 次提交
  2. 20 6月, 2014 1 次提交
    • P
      serial: Fix IGNBRK handling · ef8b9ddc
      Peter 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: NIvan <athlon_@mail.ru>
      Signed-off-by: NPeter Hurley <peter@hurleysoftware.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      ef8b9ddc
  3. 29 5月, 2014 2 次提交
  4. 01 3月, 2014 2 次提交
  5. 14 2月, 2014 1 次提交
  6. 14 1月, 2014 1 次提交
    • M
      tty/serial: at91: disable uart timer at start of shutdown · 8bc661bf
      Marek Roszko 提交于
      The uart timer will schedule a tasklet when it fires. It is possible that it
      can fire inside _shutdown before it is killed in the dma and pdc cleanup
      routines. This causes a tasklet that exists after the port is shutdown, so when
      the kernel finally executes it, it panics as the tty port is NULL.
      
      This is a somewhat rare condition but its possible if a program keeps on
      opening/closing the port. It has been observed in particular with systemd
      boot messages that were causing a kernel panic because of this behavior.
      
      Moving the timer deletion to the beginning of the function stops a tasklet from
      being scheduled unexpectedly.
      Signed-off-by: NMarek Roszko <mark.roszko@gmail.com>
      Cc: stable <stable@vger.kernel.org> # v3.12
      [nicolas.ferre@atmel.com: modify commit message, call setup_timer() in any case]
      Signed-off-by: NNicolas Ferre <nicolas.ferre@atmel.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      8bc661bf
  7. 08 1月, 2014 3 次提交
  8. 20 12月, 2013 1 次提交
  9. 18 10月, 2013 3 次提交
  10. 01 8月, 2013 1 次提交
  11. 30 7月, 2013 7 次提交
  12. 27 7月, 2013 1 次提交
  13. 25 7月, 2013 1 次提交
  14. 25 6月, 2013 1 次提交
  15. 16 3月, 2013 1 次提交
  16. 16 1月, 2013 2 次提交
    • J
      TTY: switch tty_flip_buffer_push · 2e124b4a
      Jiri 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: NJiri Slaby <jslaby@suse.cz>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      2e124b4a
    • J
      TTY: switch tty_insert_flip_string · 05c7cd39
      Jiri 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: NJiri Slaby <jslaby@suse.cz>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      05c7cd39
  17. 22 11月, 2012 3 次提交
  18. 16 11月, 2012 1 次提交
  19. 06 11月, 2012 1 次提交
  20. 13 10月, 2012 1 次提交
  21. 10 4月, 2012 1 次提交
    • S
      tty/serial: atmel_serial: fix RS485 half-duplex problem · 57c36868
      Siftar, Gabe 提交于
      On our custom board, we are using RS485 in half-duplex mode on an AT91SAM9G45.
      SER_RS485_RX_DURING_TX is not set as we do not want to receive the data we
      transmit (our transceiver will receive transmitted data).
      Although the current driver attempts to disable and enable the receiver at the
      appropriate points, incoming data is still loaded into the receive register
      causing our code to receive the very last byte that was sent once the receiver
      is enabled.
      
      I ran this by Atmel support and they wrote: "The issue comes from the fact
      that you disable the PDC/DMA Reception and not the USART Reception channel. In
      your case, the[n] you will still receive data into the USART_RHR register, and
      maybe you [h]ave the overrun flag set. So please disable the USART reception
      channel."
      
      The following patch should force the driver to enable/disable the receiver via
      RXEN/RXDIS fields of the USART control register. It fixed the issue I was
      having.
      Signed-off-by: NGabe Siftar <gabe.siftar@getingeusa.com>
      [nicolas.ferre@atmel.com: slightly modify commit message]
      Signed-off-by: NNicolas Ferre <nicolas.ferre@atmel.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      57c36868
  22. 23 2月, 2012 1 次提交
  23. 05 1月, 2012 1 次提交
  24. 16 11月, 2011 2 次提交