1. 27 6月, 2018 1 次提交
  2. 30 5月, 2018 1 次提交
  3. 14 5月, 2018 2 次提交
  4. 04 5月, 2018 1 次提交
  5. 20 4月, 2018 1 次提交
  6. 22 3月, 2018 1 次提交
  7. 27 2月, 2018 1 次提交
  8. 15 2月, 2018 1 次提交
  9. 23 1月, 2018 2 次提交
  10. 14 12月, 2017 3 次提交
  11. 11 12月, 2017 1 次提交
  12. 27 11月, 2017 1 次提交
  13. 31 10月, 2017 1 次提交
  14. 31 8月, 2017 1 次提交
  15. 20 8月, 2017 4 次提交
  16. 14 6月, 2017 1 次提交
  17. 05 6月, 2017 1 次提交
  18. 24 3月, 2017 1 次提交
  19. 31 1月, 2017 1 次提交
  20. 30 1月, 2017 6 次提交
  21. 25 10月, 2016 1 次提交
  22. 22 9月, 2016 1 次提交
    • H
      [media] media: rc: fix deadlock when module ir_lirc_codec is removed · 033919e0
      Heiner Kallweit 提交于
      When removing module ir_lirc_codec I got this deadlock warning.
      Fix this by introducing a separate mutex to protect access
      to available_protocols instead of using ir_raw_handler_lock
      for this purpose.
      
      ======================================================
      [ INFO: possible circular locking dependency detected ]
      4.7.0-next-20160729 #1 Not tainted
      -------------------------------------------------------
      rmmod/2542 is trying to acquire lock:
       (&dev->lock){+.+.+.}, at: [<ffffffffa03b1267>]
      			ir_raw_handler_unregister+0x77/0xd0 [rc_core]
      
      but task is already holding lock:
       (ir_raw_handler_lock){+.+.+.}, at: [<ffffffffa03b1212>]
      			ir_raw_handler_unregister+0x22/0xd0 [rc_core]
      
      which lock already depends on the new lock.
      
      the existing dependency chain (in reverse order) is:
      
      -> #1 (ir_raw_handler_lock){+.+.+.}:
             [<ffffffff810ab1f2>] lock_acquire+0xb2/0x1e0
             [<ffffffff815c087f>] mutex_lock_nested+0x5f/0x360
             [<ffffffffa03b1403>] ir_raw_get_allowed_protocols+0x13/0x30 [rc_core]
             [<ffffffffa03af8ea>] store_protocols+0x2fa/0x480 [rc_core]
             [<ffffffff8143e143>] dev_attr_store+0x13/0x20
             [<ffffffff81213c50>] sysfs_kf_write+0x40/0x50
             [<ffffffff81212f60>] kernfs_fop_write+0x150/0x1e0
             [<ffffffff81197613>] __vfs_write+0x23/0x120
             [<ffffffff81198740>] vfs_write+0xb0/0x190
             [<ffffffff81199a34>] SyS_write+0x44/0xa0
             [<ffffffff815c55a5>] entry_SYSCALL_64_fastpath+0x18/0xa8
      
      -> #0 (&dev->lock){+.+.+.}:
             [<ffffffff810aac8c>] __lock_acquire+0x10fc/0x1270
             [<ffffffff810ab1f2>] lock_acquire+0xb2/0x1e0
             [<ffffffff815c087f>] mutex_lock_nested+0x5f/0x360
             [<ffffffffa03b1267>] ir_raw_handler_unregister+0x77/0xd0 [rc_core]
             [<ffffffffa03c8c05>] ir_lirc_codec_exit+0x10/0x12 [ir_lirc_codec]
             [<ffffffff810e1b88>] SyS_delete_module+0x168/0x220
             [<ffffffff815c55a5>] entry_SYSCALL_64_fastpath+0x18/0xa8
      
      other info that might help us debug this:
      
       Possible unsafe locking scenario:
      
             CPU0                    CPU1
             ----                    ----
        lock(ir_raw_handler_lock);
                                     lock(&dev->lock);
                                     lock(ir_raw_handler_lock);
        lock(&dev->lock);
      
       *** DEADLOCK ***
      
      1 lock held by rmmod/2542:
       #0:  (ir_raw_handler_lock){+.+.+.}, at: [<ffffffffa03b1212>]
      			ir_raw_handler_unregister+0x22/0xd0 [rc_core]
      
      stack backtrace:
      CPU: 0 PID: 2542 Comm: rmmod Not tainted 4.7.0-next-20160729 #1
      Hardware name: ZOTAC ZBOX-CI321NANO/ZBOX-CI321NANO, BIOS B246P105 06/01/2015
       0000000000000000 ffff88006e607cc0 ffffffff812715f5 ffffffff8232b230
       ffffffff8232b230 ffff88006e607d00 ffffffff810a846e 00000000790107f0
       ffff880079010818 ffff8800790107f0 1efeb9f4f0dd2e6f ffff880079010000
      Call Trace:
       [<ffffffff812715f5>] dump_stack+0x68/0x93
       [<ffffffff810a846e>] print_circular_bug+0x1be/0x210
       [<ffffffff810aac8c>] __lock_acquire+0x10fc/0x1270
       [<ffffffff810bcead>] ? debug_lockdep_rcu_enabled+0x1d/0x20
       [<ffffffff810ab1f2>] lock_acquire+0xb2/0x1e0
       [<ffffffffa03b1267>] ? ir_raw_handler_unregister+0x77/0xd0 [rc_core]
       [<ffffffff815c087f>] mutex_lock_nested+0x5f/0x360
       [<ffffffffa03b1267>] ? ir_raw_handler_unregister+0x77/0xd0 [rc_core]
       [<ffffffff810a980e>] ? trace_hardirqs_on_caller+0xee/0x1b0
       [<ffffffffa03b1267>] ir_raw_handler_unregister+0x77/0xd0 [rc_core]
       [<ffffffffa03c8c05>] ir_lirc_codec_exit+0x10/0x12 [ir_lirc_codec]
       [<ffffffff810e1b88>] SyS_delete_module+0x168/0x220
       [<ffffffff815c55a5>] entry_SYSCALL_64_fastpath+0x18/0xa8
      Signed-off-by: NHeiner Kallweit <hkallweit1@gmail.com>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@s-opensource.com>
      033919e0
  23. 25 1月, 2016 1 次提交
    • H
      [media] media: rc: raw: improve FIFO handling · 464254e5
      Heiner Kallweit 提交于
      The FIFO is used for ir_raw_event records, however for some historic
      reason the FIFO is used on a per byte basis. IMHO this adds unneeded
      complexity. Therefore set up the FIFO for ir_raw_event records.
      
      This also allows to define the FIFO statically as part of
      ir_raw_event_ctrl instead of having to allocate the FIFO dynamically.
      In addition:
      
      - When writing into the FIFO and it's full return ENOSPC instead of
        ENOMEM thus making it easier to tell between "FIFO full" and
        "Dynamic memory allocation failed" when the error is propagated to
        a higher level.
        Also add an error message.
      
      - When reading from the FIFO check whether it's empty.
        This is not strictly needed here but kfifo_out is annotated
        "must check" anyway.
      
      Successfully tested it with the nuvoton-cir driver.
      Signed-off-by: NHeiner Kallweit <hkallweit1@gmail.com>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@osg.samsung.com>
      464254e5
  24. 04 12月, 2015 1 次提交
  25. 19 11月, 2015 3 次提交
  26. 19 8月, 2015 1 次提交