1. 07 11月, 2016 1 次提交
    • N
      i2c: bcm2835: Fix hang for writing messages larger than 16 bytes · e2474541
      Noralf Trønnes 提交于
      Writing messages larger than the FIFO size results in a hang, rendering
      the machine unusable. This is because the RXD status flag is set on the
      first interrupt which results in bcm2835_drain_rxfifo() stealing bytes
      from the buffer. The controller continues to trigger interrupts waiting
      for the missing bytes, but bcm2835_fill_txfifo() has none to give.
      In this situation wait_for_completion_timeout() apparently is unable to
      stop the madness.
      
      The BCM2835 ARM Peripherals datasheet has this to say about the flags:
        TXD: is set when the FIFO has space for at least one byte of data.
        RXD: is set when the FIFO contains at least one byte of data.
        TXW: is set during a write transfer and the FIFO is less than full.
        RXR: is set during a read transfer and the FIFO is or more full.
      
      Implementing the logic from the downstream i2c-bcm2708 driver solved
      the hang problem.
      Signed-off-by: NNoralf Trønnes <noralf@tronnes.org>
      Reviewed-by: NEric Anholt <eric@anholt.net>
      Reviewed-by: NMartin Sperl <kernel@martin.sperl.org>
      Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
      e2474541
  2. 25 10月, 2016 11 次提交
  3. 29 9月, 2016 1 次提交
  4. 24 9月, 2016 4 次提交
  5. 23 9月, 2016 3 次提交
  6. 22 9月, 2016 4 次提交
  7. 17 9月, 2016 1 次提交
  8. 16 9月, 2016 2 次提交
  9. 09 9月, 2016 13 次提交