Re: [PATCH] drm/bridge: lt9611uxc: fix the race in the error path

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 12 Oct 2023 01:00:02 +0300, Dmitry Baryshkov wrote:
> If DSI host attachment fails, the LT9611UXC driver will remove the
> bridge without ensuring that there is no outstanding HPD work being
> done. In rare cases this can result in the warnings regarding the mutex
> being incorrect. Fix this by forcebly freing IRQ and flushing the work.
> 
> DEBUG_LOCKS_WARN_ON(lock->magic != lock)
> WARNING: CPU: 0 PID: 10 at kernel/locking/mutex.c:582 __mutex_lock+0x468/0x77c
> Modules linked in:
> CPU: 0 PID: 10 Comm: kworker/0:1 Tainted: G     U             6.6.0-rc5-next-20231011-gd81f81c2b682-dirty #1206
> Hardware name: Qualcomm Technologies, Inc. Robotics RB5 (DT)
> Workqueue: events lt9611uxc_hpd_work
> pstate: 60400005 (nZCv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
> pc : __mutex_lock+0x468/0x77c
> lr : __mutex_lock+0x468/0x77c
> sp : ffff8000800a3c70
> x29: ffff8000800a3c70 x28: 0000000000000000 x27: ffffd595fe333000
> x26: ffff7c2f0002c005 x25: ffffd595ff1b3000 x24: ffffd595fccda5a0
> x23: 0000000000000000 x22: 0000000000000002 x21: ffff7c2f056d91c8
> x20: 0000000000000000 x19: ffff7c2f056d91c8 x18: fffffffffffe8db0
> x17: 000000040044ffff x16: 005000f2b5503510 x15: 0000000000000000
> x14: 000000000006efb8 x13: 0000000000000000 x12: 0000000000000037
> x11: 0000000000000001 x10: 0000000000001470 x9 : ffff8000800a3ae0
> x8 : ffff7c2f0027f8d0 x7 : ffff7c2f0027e400 x6 : ffffd595fc702b54
> x5 : 0000000000000000 x4 : ffff8000800a0000 x3 : 0000000000000000
> x2 : 0000000000000000 x1 : 0000000000000000 x0 : ffff7c2f0027e400
> Call trace:
>  __mutex_lock+0x468/0x77c
>  mutex_lock_nested+0x24/0x30
>  drm_bridge_hpd_notify+0x2c/0x5c
>  lt9611uxc_hpd_work+0x6c/0x80
>  process_one_work+0x1ec/0x51c
>  worker_thread+0x1ec/0x3e4
>  kthread+0x120/0x124
>  ret_from_fork+0x10/0x20
> irq event stamp: 15799
> hardirqs last  enabled at (15799): [<ffffd595fc702ba4>] finish_task_switch.isra.0+0xa8/0x278
> hardirqs last disabled at (15798): [<ffffd595fd5a1580>] __schedule+0x7b8/0xbd8
> softirqs last  enabled at (15794): [<ffffd595fc690698>] __do_softirq+0x498/0x4e0
> softirqs last disabled at (15771): [<ffffd595fc69615c>] ____do_softirq+0x10/0x1c
> 
> [...]

Applied, thanks!

[1/1] drm/bridge: lt9611uxc: fix the race in the error path
      https://cgit.freedesktop.org/drm/drm-misc/commit/?id=15fe53be46ea



Rob




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux