linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* bcm43xx-mac80211: a fix for the shared interrupt problem
@ 2007-07-28  3:36 Larry Finger
  2007-07-28 16:48 ` Michael Buesch
  0 siblings, 1 reply; 6+ messages in thread
From: Larry Finger @ 2007-07-28  3:36 UTC (permalink / raw)
  To: Michael Buesch; +Cc: Bcm43xx-dev, linux-wireless

Michael,

I was in the right area with my previous fix to the "irq 11: nobody cared"
message. I think for shared interrupts, skipping out if the status is not
BCM43xx_STAT_STARTED is too severe. I added a message printing out the status
whenever it skipped out, and found many thousands of interrupts with the
status equal to BCM43xx_STAT_INITIALIZED. The patch below makes the necessary
change and modifies a couple of asserts that depend on it.

This patch has been tested on BCM4306 and BCM4318 with shared interrupts,
and BCM4311 without.

Thanks,

Larry
----


Index: wireless-mb/drivers/net/wireless/bcm43xx-mac80211/bcm43xx_main.c
===================================================================
--- wireless-mb.orig/drivers/net/wireless/bcm43xx-mac80211/bcm43xx_main.c
+++ wireless-mb/drivers/net/wireless/bcm43xx-mac80211/bcm43xx_main.c
@@ -1374,7 +1374,7 @@ static void bcm43xx_interrupt_tasklet(st
 
 	spin_lock_irqsave(&dev->wl->irq_lock, flags);
 
-	assert(bcm43xx_status(dev) == BCM43xx_STAT_STARTED);
+	assert(bcm43xx_status(dev) >= BCM43xx_STAT_INITIALIZED);
 
 	reason = dev->irq_reason;
 	for (i = 0; i < ARRAY_SIZE(dma_reason); i++) {
@@ -1512,7 +1512,7 @@ static irqreturn_t bcm43xx_interrupt_han
 
 	spin_lock(&dev->wl->irq_lock);
 
-	if (bcm43xx_status(dev) < BCM43xx_STAT_STARTED)
+	if (bcm43xx_status(dev) < BCM43xx_STAT_INITIALIZED)
 		goto out;
 	reason = bcm43xx_read32(dev, BCM43xx_MMIO_GEN_IRQ_REASON);
 	if (reason == 0xffffffff) /* shared IRQ */
@@ -1522,7 +1522,7 @@ static irqreturn_t bcm43xx_interrupt_han
 	if (!reason)
 		goto out;
 
-	assert(bcm43xx_status(dev) == BCM43xx_STAT_STARTED);
+	assert(bcm43xx_status(dev) >= BCM43xx_STAT_INITIALIZED);
 
 	dev->dma_reason[0] = bcm43xx_read32(dev, BCM43xx_MMIO_DMA0_REASON)
 			     & 0x0001DC00;

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2007-07-29  8:54 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-07-28  3:36 bcm43xx-mac80211: a fix for the shared interrupt problem Larry Finger
2007-07-28 16:48 ` Michael Buesch
2007-07-28 20:53   ` Larry Finger
2007-07-28 23:03     ` Michael Buesch
2007-07-28 23:58       ` Larry Finger
2007-07-29  8:54         ` Michael Buesch

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).