All of lore.kernel.org
 help / color / mirror / Atom feed
* b44: device restarts on heavy load
@ 2009-06-16 14:47 Jean-Louis Dupond
  2009-06-16 15:11 ` Jean-Louis Dupond
  0 siblings, 1 reply; 3+ messages in thread
From: Jean-Louis Dupond @ 2009-06-16 14:47 UTC (permalink / raw)
  To: Linux Netdev List

Hello,

There seems to be a bug in the b44 driver to cause a restart/reset of 
the network card. I tried to debug it a bit, and the error is in the 
b44_poll method.

846 static int b44_poll(struct napi_struct *napi, int budget)
847 {
848         struct b44 *bp = container_of(napi, struct b44, napi);
849         int work_done;
850
851         spin_lock_irq(&bp->lock);
852
853         if (bp->istat & (ISTAT_TX | ISTAT_TO)) {
854                 /* spin_lock(&bp->tx_lock); */
855                 b44_tx(bp);
856                 /* spin_unlock(&bp->tx_lock); */
857         }
858         spin_unlock_irq(&bp->lock);
859
860         work_done = 0;
861         if (bp->istat & ISTAT_RX)
862                 work_done += b44_rx(bp, budget);
863
864         if (bp->istat & ISTAT_ERRORS) {
865                 unsigned long flags;
866
867                 spin_lock_irqsave(&bp->lock, flags);
868                 b44_halt(bp);
869                 b44_init_rings(bp);
870                 b44_init_hw(bp, B44_FULL_RESET_SKIP_PHY);
871                 netif_wake_queue(bp->dev);
872                 spin_unlock_irqrestore(&bp->lock, flags);
873                 work_done = 0;
874         }
875
876         if (work_done < budget) {
877                 napi_complete(napi);
878                 b44_enable_ints(bp);
879         }
880
881         return work_done;
882 }


It seems that suddenly bp->istat & ISTAT_ERRORS is true, so it resets 
the network card. This isn't really nice :(

There seems to be ALOT of people having this issue: 
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/279102

Sincerely
Jean-Louis Dupond

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

* Re: b44: device restarts on heavy load
  2009-06-16 14:47 b44: device restarts on heavy load Jean-Louis Dupond
@ 2009-06-16 15:11 ` Jean-Louis Dupond
  2009-07-22 15:56   ` David Miller
  0 siblings, 1 reply; 3+ messages in thread
From: Jean-Louis Dupond @ 2009-06-16 15:11 UTC (permalink / raw)
  To: Linux Netdev List

To be more precise, the error is ISTAT_RFO              0x00004000 /* 
Receive FIFO Overflow */

Jean-Louis Dupond schreef:
> Hello,
> 
> There seems to be a bug in the b44 driver to cause a restart/reset of 
> the network card. I tried to debug it a bit, and the error is in the 
> b44_poll method.
> 
> 846 static int b44_poll(struct napi_struct *napi, int budget)
> 847 {
> 848         struct b44 *bp = container_of(napi, struct b44, napi);
> 849         int work_done;
> 850
> 851         spin_lock_irq(&bp->lock);
> 852
> 853         if (bp->istat & (ISTAT_TX | ISTAT_TO)) {
> 854                 /* spin_lock(&bp->tx_lock); */
> 855                 b44_tx(bp);
> 856                 /* spin_unlock(&bp->tx_lock); */
> 857         }
> 858         spin_unlock_irq(&bp->lock);
> 859
> 860         work_done = 0;
> 861         if (bp->istat & ISTAT_RX)
> 862                 work_done += b44_rx(bp, budget);
> 863
> 864         if (bp->istat & ISTAT_ERRORS) {
> 865                 unsigned long flags;
> 866
> 867                 spin_lock_irqsave(&bp->lock, flags);
> 868                 b44_halt(bp);
> 869                 b44_init_rings(bp);
> 870                 b44_init_hw(bp, B44_FULL_RESET_SKIP_PHY);
> 871                 netif_wake_queue(bp->dev);
> 872                 spin_unlock_irqrestore(&bp->lock, flags);
> 873                 work_done = 0;
> 874         }
> 875
> 876         if (work_done < budget) {
> 877                 napi_complete(napi);
> 878                 b44_enable_ints(bp);
> 879         }
> 880
> 881         return work_done;
> 882 }
> 
> 
> It seems that suddenly bp->istat & ISTAT_ERRORS is true, so it resets 
> the network card. This isn't really nice :(
> 
> There seems to be ALOT of people having this issue: 
> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/279102
> 
> Sincerely
> Jean-Louis Dupond
> -- 
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: b44: device restarts on heavy load
  2009-06-16 15:11 ` Jean-Louis Dupond
@ 2009-07-22 15:56   ` David Miller
  0 siblings, 0 replies; 3+ messages in thread
From: David Miller @ 2009-07-22 15:56 UTC (permalink / raw)
  To: info; +Cc: netdev

From: Jean-Louis Dupond <info@dupondje.be>
Date: Tue, 16 Jun 2009 17:11:08 +0200

> To be more precise, the error is ISTAT_RFO 0x00004000 /* Receive FIFO
> Overflow */

The problem is that we need to know if a receive FIFO overflow
puts the chip into a state where it must be reset.

And until we know that, we cannot simply exclude that condition
from the reset test.

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

end of thread, other threads:[~2009-07-22 15:55 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-06-16 14:47 b44: device restarts on heavy load Jean-Louis Dupond
2009-06-16 15:11 ` Jean-Louis Dupond
2009-07-22 15:56   ` David Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.