lkml.org 
[lkml]   [2023]   [Oct]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] dmaengine: mediatek: Fix deadlock caused by synchronize_irq()
Date

On Sun, 06 Aug 2023 11:25:11 +0800, Duoming Zhou wrote:
> The synchronize_irq(c->irq) will not return until the IRQ handler
> mtk_uart_apdma_irq_handler() is completed. If the synchronize_irq()
> holds a spin_lock and waits the IRQ handler to complete, but the
> IRQ handler also needs the same spin_lock. The deadlock will happen.
> The process is shown below:
>
> cpu0 cpu1
> mtk_uart_apdma_device_pause() | mtk_uart_apdma_irq_handler()
> spin_lock_irqsave() |
> | spin_lock_irqsave()
> //hold the lock to wait |
> synchronize_irq() |
>
> [...]

Applied, thanks!

[1/1] dmaengine: mediatek: Fix deadlock caused by synchronize_irq()
commit: 01f1ae2733e2bb4de92fefcea5fda847d92aede1

Best regards,
--
~Vinod


\
 
 \ /
  Last update: 2023-10-04 16:19    [W:0.053 / U:0.820 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site