diff mbox

3c59x: shared interrupt problem

Message ID 20090309164927.6eb12aff@nehalam
State Accepted, archived
Delegated to: David Miller
Headers show

Commit Message

stephen hemminger March 9, 2009, 11:49 p.m. UTC
On Mon, 09 Mar 2009 23:42:53 +0100
"Gerhard Pircher" <gerhard_pircher@gmx.net> wrote:

> Hi!
> 
> Large network transfers fail on my machine (with kernel versions
> >v2.6.26) with the kernel oops below. eth0 (3c59x driver) normally
> shares its IRQ line with 3 OHCI USB ports (IRQ 7), as the excerpt of
> /proc/interrupt shows. Removing USB support from the kernel makes it
> work again. I wasn't able to do a full git bisect run yet, as v2.6.27
> didn't produce a bootable kernel image for my machine. The machine is
> an AmigaOne PowerPC G4 with an onboard 3c920 network chip.
> 
> Any idea?

Does this help, it looks like boomerang_interrupt was not doing
shared irq stuff correctly.


--
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

Comments

Steffen Klassert March 10, 2009, 8:16 a.m. UTC | #1
On Mon, Mar 09, 2009 at 04:49:27PM -0700, Stephen Hemminger wrote:
> On Mon, 09 Mar 2009 23:42:53 +0100
> "Gerhard Pircher" <gerhard_pircher@gmx.net> wrote:
> 
> > Hi!
> > 
> > Large network transfers fail on my machine (with kernel versions
> > >v2.6.26) with the kernel oops below. eth0 (3c59x driver) normally
> > shares its IRQ line with 3 OHCI USB ports (IRQ 7), as the excerpt of
> > /proc/interrupt shows. Removing USB support from the kernel makes it
> > work again. I wasn't able to do a full git bisect run yet, as v2.6.27
> > didn't produce a bootable kernel image for my machine. The machine is
> > an AmigaOne PowerPC G4 with an onboard 3c920 network chip.
> > 
> > Any idea?
> 
> Does this help, it looks like boomerang_interrupt was not doing
> shared irq stuff correctly.
> 
> --- a/drivers/net/3c59x.c	2009-03-09 16:07:13.372670015 -0700
> +++ b/drivers/net/3c59x.c	2009-03-09 16:08:50.214357441 -0700
> @@ -2301,6 +2301,7 @@ boomerang_interrupt(int irq, void *dev_i
>  	void __iomem *ioaddr;
>  	int status;
>  	int work_done = max_interrupt_work;
> +	int handled = 0;
>  
>  	ioaddr = vp->ioaddr;
>  
> @@ -2323,6 +2324,7 @@ boomerang_interrupt(int irq, void *dev_i
>  			printk(KERN_DEBUG "boomerang_interrupt(1): status = 0xffff\n");
>  		goto handler_exit;
>  	}
> +	handled = 1;
>  
>  	if (status & IntReq) {
>  		status |= vp->deferred;
> @@ -2417,7 +2419,7 @@ boomerang_interrupt(int irq, void *dev_i
>  			   dev->name, status);
>  handler_exit:
>  	spin_unlock(&vp->lock);
> -	return IRQ_HANDLED;
> +	return IRQ_RETVAL(handled);
>  }
>  
>  static int vortex_rx(struct net_device *dev)
> 

This basically reverts a patch from akpm (bitkeeper cset 1.1046.95.8)
This patch was to workaround lots of "nobody cared" warnings generated by
boomerang_interrupt(). 
I added Andrew to the Cc, perhaps he can remember some details on this.

Steffen
--
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
Andrew Morton March 10, 2009, 9:55 p.m. UTC | #2
On Tue, 10 Mar 2009 09:16:28 +0100
Steffen Klassert <klassert@mathematik.tu-chemnitz.de> wrote:

> On Mon, Mar 09, 2009 at 04:49:27PM -0700, Stephen Hemminger wrote:
> > On Mon, 09 Mar 2009 23:42:53 +0100
> > "Gerhard Pircher" <gerhard_pircher@gmx.net> wrote:
> > 
> > > Hi!
> > > 
> > > Large network transfers fail on my machine (with kernel versions
> > > >v2.6.26) with the kernel oops below. eth0 (3c59x driver) normally
> > > shares its IRQ line with 3 OHCI USB ports (IRQ 7), as the excerpt of
> > > /proc/interrupt shows. Removing USB support from the kernel makes it
> > > work again. I wasn't able to do a full git bisect run yet, as v2.6.27
> > > didn't produce a bootable kernel image for my machine. The machine is
> > > an AmigaOne PowerPC G4 with an onboard 3c920 network chip.
> > > 
> > > Any idea?
> > 
> > Does this help, it looks like boomerang_interrupt was not doing
> > shared irq stuff correctly.
> > 
> > --- a/drivers/net/3c59x.c	2009-03-09 16:07:13.372670015 -0700
> > +++ b/drivers/net/3c59x.c	2009-03-09 16:08:50.214357441 -0700
> > @@ -2301,6 +2301,7 @@ boomerang_interrupt(int irq, void *dev_i
> >  	void __iomem *ioaddr;
> >  	int status;
> >  	int work_done = max_interrupt_work;
> > +	int handled = 0;
> >  
> >  	ioaddr = vp->ioaddr;
> >  
> > @@ -2323,6 +2324,7 @@ boomerang_interrupt(int irq, void *dev_i
> >  			printk(KERN_DEBUG "boomerang_interrupt(1): status = 0xffff\n");
> >  		goto handler_exit;
> >  	}
> > +	handled = 1;
> >  
> >  	if (status & IntReq) {
> >  		status |= vp->deferred;
> > @@ -2417,7 +2419,7 @@ boomerang_interrupt(int irq, void *dev_i
> >  			   dev->name, status);
> >  handler_exit:
> >  	spin_unlock(&vp->lock);
> > -	return IRQ_HANDLED;
> > +	return IRQ_RETVAL(handled);
> >  }
> >  
> >  static int vortex_rx(struct net_device *dev)
> > 
> 
> This basically reverts a patch from akpm (bitkeeper cset 1.1046.95.8)
> This patch was to workaround lots of "nobody cared" warnings generated by
> boomerang_interrupt(). 
> I added Andrew to the Cc, perhaps he can remember some details on this.
> 

Beats me.  Do you havea full copy of that patch, including changelog?

Thanks.
--
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
diff mbox

Patch

--- a/drivers/net/3c59x.c	2009-03-09 16:07:13.372670015 -0700
+++ b/drivers/net/3c59x.c	2009-03-09 16:08:50.214357441 -0700
@@ -2301,6 +2301,7 @@  boomerang_interrupt(int irq, void *dev_i
 	void __iomem *ioaddr;
 	int status;
 	int work_done = max_interrupt_work;
+	int handled = 0;
 
 	ioaddr = vp->ioaddr;
 
@@ -2323,6 +2324,7 @@  boomerang_interrupt(int irq, void *dev_i
 			printk(KERN_DEBUG "boomerang_interrupt(1): status = 0xffff\n");
 		goto handler_exit;
 	}
+	handled = 1;
 
 	if (status & IntReq) {
 		status |= vp->deferred;
@@ -2417,7 +2419,7 @@  boomerang_interrupt(int irq, void *dev_i
 			   dev->name, status);
 handler_exit:
 	spin_unlock(&vp->lock);
-	return IRQ_HANDLED;
+	return IRQ_RETVAL(handled);
 }
 
 static int vortex_rx(struct net_device *dev)