omap mmc host: Use disable_irq_nosync() from within irq handlers.
Subsystems (2)
PATCH 9/9 omap mmc host: Use disable_irq_nosync() from within irq handlers.
disable_irq() should wait for all running handlers to complete before returning. As such, if it's used to disable an interrupt from that interrupt's handler it will deadlock. This replaces the dangerous instances with the _nosync() variant which doesn't have this problem.
---
drivers/mmc/host/omap.c +1 -1
@@ -824,7 +824,7 @@ static irqreturn_t mmc_omap_irq(int irq, void *dev_id)del_timer (&host->cmd_abort_timer); host->abort =1 ;OMAP_MMC_WRITE (host,IE ,0 ); -disable_irq (host->irq); +disable_irq_nosync (host->irq);schedule_work (&host->cmd_abort_work);return IRQ_HANDLED ; }
Signature · 1 line
1.6.0.2
Should I queue this up or do you want to do something differently for this?
Quoted 22 lines · On Thu, 16 Apr 2009 15:55:21 +1000 Ben Nizette <[email protected]> wrote:
disable_irq()should wait for all running handlers to complete before returning. As such, if it's used to disable an interrupt from that interrupt's handler it will deadlock. This replaces the dangerous instances with the_nosync()variant which doesn't have this problem.Signed-off-by Ben Nizette <[email protected]>---
drivers/mmc/host/omap.c +1
-1@@ -824,7 +824,7 @@ static irqreturn_t mmc_omap_irq(int irq, void *dev_id)del_timer (&host->cmd_abort_timer); host->abort =1 ;OMAP_MMC_WRITE (host,IE ,0 ); -disable_irq (host->irq); +disable_irq_nosync (host->irq);schedule_work (&host->cmd_abort_work);return IRQ_HANDLED ; }
Signature · 6 lines
-- Pierre Ossman WARNING: This correspondence is being monitored by the Swedish government. Make sure your server uses encryption for SMTP traffic and consider using PGP for end-to-end encryption.
Tony Lindgren
Acked-byQuoted 2 lines · Pierre Ossman
Should I queue this up or do you want to do something differently for this?
Looks like a valid fix to me.
Quoted 34 lines
Quoted 22 lines · On Thu, 16 Apr 2009 15:55:21 +1000 Ben Nizette <[email protected]> wrote:
disable_irq()should wait for all running handlers to complete before returning. As such, if it's used to disable an interrupt from that interrupt's handler it will deadlock. This replaces the dangerous instances with the_nosync()variant which doesn't have this problem.Signed-off-by Ben Nizette <[email protected]>---
drivers/mmc/host/omap.c +1
-1@@ -824,7 +824,7 @@ static irqreturn_t mmc_omap_irq(int irq, void *dev_id)del_timer (&host->cmd_abort_timer); host->abort =1 ;OMAP_MMC_WRITE (host,IE ,0 ); -disable_irq (host->irq); +disable_irq_nosync (host->irq);schedule_work (&host->cmd_abort_work);return IRQ_HANDLED ; }Signature · 6 lines
-- Pierre Ossman WARNING: This correspondence is being monitored by the Swedish government. Make sure your server uses encryption for SMTP traffic and consider using PGP for end-to-end encryption.
Pierre Ossman
AppliedQuoted 8 lines · On Thu, 14 May 2009 10:22:26 -0700 Tony Lindgren <[email protected]> wrote:
Quoted 2 lines · Pierre Ossman
Should I queue this up or do you want to do something differently for this?
Looks like a valid fix to me.
Acked-by Tony Lindgren <[email protected]>
Applied.
Signature · 6 lines
-- Pierre Ossman WARNING: This correspondence is being monitored by the Swedish government. Make sure your server uses encryption for SMTP traffic and consider using PGP for end-to-end encryption.