Skip to content

Commit

Permalink
[PATCH] bcm43xx: Fix assertion failures in interrupt handler
Browse files Browse the repository at this point in the history
In the bcm43xx interrupt handler, sanity checks are wrongly done before the
verification that the interrupt is for the bcm43xx.

Signed-off-by: Pavel Roskin <proski@gnu.org>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Pavel Roskin authored and John W. Linville committed Mar 8, 2007
1 parent d632f9f commit 7d9f3e8
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions drivers/net/wireless/bcm43xx/bcm43xx_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1858,9 +1858,6 @@ static irqreturn_t bcm43xx_interrupt_handler(int irq, void *dev_id)

spin_lock(&bcm->irq_lock);

assert(bcm43xx_status(bcm) == BCM43xx_STAT_INITIALIZED);
assert(bcm->current_core->id == BCM43xx_COREID_80211);

reason = bcm43xx_read32(bcm, BCM43xx_MMIO_GEN_IRQ_REASON);
if (reason == 0xffffffff) {
/* irq not for us (shared irq) */
Expand All @@ -1871,6 +1868,9 @@ static irqreturn_t bcm43xx_interrupt_handler(int irq, void *dev_id)
if (!reason)
goto out;

assert(bcm43xx_status(bcm) == BCM43xx_STAT_INITIALIZED);
assert(bcm->current_core->id == BCM43xx_COREID_80211);

bcm->dma_reason[0] = bcm43xx_read32(bcm, BCM43xx_MMIO_DMA0_REASON)
& 0x0001DC00;
bcm->dma_reason[1] = bcm43xx_read32(bcm, BCM43xx_MMIO_DMA1_REASON)
Expand Down

0 comments on commit 7d9f3e8

Please sign in to comment.