From: Yinghai Lu <yinghai@kernel.org> Date: 2009-02-06 05:01:20
Impact: make /proc/interrupts could show more info which irq is rx or other for msi-x
add three name fields for rx, tx, other
Signed-off-by: Yinghai Lu <yinghai@kernel.org>
---
drivers/net/forcedeth.c | 17 ++++++++++++++---
1 file changed, 14 insertions(+), 3 deletions(-)
Index: linux-2.6/drivers/net/forcedeth.c
===================================================================
@@ -812,6 +812,11 @@ struct fe_priv {/* power saved state */u32saved_config_space[NV_PCI_REGSZ_MAX/4];++/* for different msi-x irq type */+charname_rx[IFNAMSIZ+3];/* -rx */+charname_tx[IFNAMSIZ+3];/* -tx */+charname_other[IFNAMSIZ+6];/* -other */};/*
@@ -3918,21 +3923,27 @@ static int nv_request_irq(struct net_devnp->msi_flags|=NV_MSI_X_ENABLED;if(optimization_mode==NV_OPTIMIZATION_MODE_THROUGHPUT&&!intr_test){/* Request irq for rx handling */-if(request_irq(np->msi_x_entry[NV_MSI_X_VECTOR_RX].vector,&nv_nic_irq_rx,IRQF_SHARED,dev->name,dev)!=0){+sprintf(np->name_rx,"%s-rx",dev->name);+if(request_irq(np->msi_x_entry[NV_MSI_X_VECTOR_RX].vector,+&nv_nic_irq_rx,IRQF_SHARED,np->name_rx,dev)!=0){printk(KERN_INFO"forcedeth: request_irq failed for rx %d\n",ret);pci_disable_msix(np->pci_dev);np->msi_flags&=~NV_MSI_X_ENABLED;gotoout_err;}/* Request irq for tx handling */-if(request_irq(np->msi_x_entry[NV_MSI_X_VECTOR_TX].vector,&nv_nic_irq_tx,IRQF_SHARED,dev->name,dev)!=0){+sprintf(np->name_tx,"%s-tx",dev->name);+if(request_irq(np->msi_x_entry[NV_MSI_X_VECTOR_TX].vector,+&nv_nic_irq_tx,IRQF_SHARED,np->name_tx,dev)!=0){printk(KERN_INFO"forcedeth: request_irq failed for tx %d\n",ret);pci_disable_msix(np->pci_dev);np->msi_flags&=~NV_MSI_X_ENABLED;gotoout_free_rx;}/* Request irq for link and timer handling */-if(request_irq(np->msi_x_entry[NV_MSI_X_VECTOR_OTHER].vector,&nv_nic_irq_other,IRQF_SHARED,dev->name,dev)!=0){+sprintf(np->name_other,"%s-other",dev->name);+if(request_irq(np->msi_x_entry[NV_MSI_X_VECTOR_OTHER].vector,+&nv_nic_irq_other,IRQF_SHARED,np->name_other,dev)!=0){printk(KERN_INFO"forcedeth: request_irq failed for link %d\n",ret);pci_disable_msix(np->pci_dev);np->msi_flags&=~NV_MSI_X_ENABLED;
From: Yinghai Lu <yinghai@kernel.org> Date: 2009-02-06 05:02:26
Impact: fix bug
for msix, we still need that flag to enable irq respectively
Signed-off-by: Yinghai Lu <yinghai@kernel.org>
---
drivers/net/forcedeth.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
Index: linux-2.6/drivers/net/forcedeth.c
===================================================================
@@ -4057,8 +4057,6 @@ static void nv_do_nic_poll(unsigned longmask|=NVREG_IRQ_OTHER;}}-np->nic_poll_irq=0;-/* disable_irq() contains synchronize_irq, thus no irq handler can run now */if(np->recover_error){
From: Yinghai Lu <yinghai@kernel.org> Date: 2009-02-06 05:02:41
Impact: clean up
schedule it later after disable it.
Signed-off-by: Yinghai Lu <yinghai@kernel.org>
---
drivers/net/forcedeth.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
Index: linux-2.6/drivers/net/forcedeth.c
===================================================================
@@ -3708,13 +3708,13 @@ static irqreturn_t nv_nic_irq_rx(int foou32events;events=readl(base+NvRegMSIXIrqStatus)&NVREG_IRQ_RX_ALL;-writel(NVREG_IRQ_RX_ALL,base+NvRegMSIXIrqStatus);if(events){-netif_rx_schedule(&np->napi);/* disable receive interrupts on the nic */writel(NVREG_IRQ_RX_ALL,base+NvRegIrqMask);pci_push(base);+writel(NVREG_IRQ_RX_ALL,base+NvRegMSIXIrqStatus);+netif_rx_schedule(&np->napi);}returnIRQ_HANDLED;}
From: David Miller <davem@davemloft.net> Date: 2009-02-06 09:31:35
From: Yinghai Lu <yinghai@kernel.org>
Date: Thu, 05 Feb 2009 20:59:20 -0800
Impact: make /proc/interrupts could show more info which irq is rx or other for msi-x
add three name fields for rx, tx, other
Signed-off-by: Yinghai Lu <yinghai@kernel.org>
From: David Miller <davem@davemloft.net> Date: 2009-02-06 09:32:37
From: Yinghai Lu <yinghai@kernel.org>
Date: Thu, 05 Feb 2009 21:01:06 -0800
Impact: clean up
schedule it later after disable it.
Signed-off-by: Yinghai Lu <yinghai@kernel.org>
Applied to net-next-2.6
I had to edit this patch to make it apply properly. In net-next-2.6
the netix_rx_*() have been renamed to napi_*() and the former interfaces
deleted.
Please generate your patches properly against net-next-2.6 in the
future.
Thanks.
Cool cleanups!
Would you mind to also fix the following - on all my systems that have
forcedeth gigabit ethernet i've been getting these bogus warnings for
_years_, under moderate load:
eth2: too many iterations (16) in nv_nic_irq.
I think a 64 iterations limit will work much better. (i tried a limit of 50
a year ago for a while and it worked fine and had no side effects - and the
bogus warnings were done.)
Ingo
From: Yinghai Lu <yinghai@kernel.org> Date: 2009-02-06 16:59:15
Ingo Molnar wrote:
Cool cleanups!
Would you mind to also fix the following - on all my systems that have
forcedeth gigabit ethernet i've been getting these bogus warnings for
_years_, under moderate load:
eth2: too many iterations (16) in nv_nic_irq.
I think a 64 iterations limit will work much better. (i tried a limit of 50
a year ago for a while and it worked fine and had no side effects - and the
bogus warnings were done.)
you may enable CONFIG_FORCEDETH_NAPI.
we should enable NAPI for forcedeth by default, and try to squash more bugs out.
YH
Cool cleanups!
Would you mind to also fix the following - on all my systems that have
forcedeth gigabit ethernet i've been getting these bogus warnings for
_years_, under moderate load:
eth2: too many iterations (16) in nv_nic_irq.
I think a 64 iterations limit will work much better. (i tried a limit of 50
a year ago for a while and it worked fine and had no side effects - and the
bogus warnings were done.)
you may enable CONFIG_FORCEDETH_NAPI.
we should enable NAPI for forcedeth by default, and try to squash more bugs out.
i do have that:
CONFIG_FORCEDETH=y
CONFIG_FORCEDETH_NAPI=y
and the messages still come.
Ingo
From: Yinghai Lu <yinghai@kernel.org> Date: 2009-02-06 17:56:29
Ingo Molnar wrote:
* Yinghai Lu [off-list ref] wrote:
quoted
Ingo Molnar wrote:
quoted
Cool cleanups!
Would you mind to also fix the following - on all my systems that have
forcedeth gigabit ethernet i've been getting these bogus warnings for
_years_, under moderate load:
eth2: too many iterations (16) in nv_nic_irq.
I think a 64 iterations limit will work much better. (i tried a limit of 50
a year ago for a while and it worked fine and had no side effects - and the
bogus warnings were done.)
you may enable CONFIG_FORCEDETH_NAPI.
we should enable NAPI for forcedeth by default, and try to squash more bugs out.
i do have that:
CONFIG_FORCEDETH=y
CONFIG_FORCEDETH_NAPI=y
and the messages still come.
so you systems are using ioapic routing, or msi.
and those messages are from
nv_nic_irq_optimized or nv_nic_irq
for TX or OTHER (timerirq).
YH
Cool cleanups!
Would you mind to also fix the following - on all my systems that have
forcedeth gigabit ethernet i've been getting these bogus warnings for
_years_, under moderate load:
eth2: too many iterations (16) in nv_nic_irq.
I think a 64 iterations limit will work much better. (i tried a limit of 50
a year ago for a while and it worked fine and had no side effects - and the
bogus warnings were done.)
you may enable CONFIG_FORCEDETH_NAPI.
we should enable NAPI for forcedeth by default, and try to squash more bugs out.
i do have that:
CONFIG_FORCEDETH=y
CONFIG_FORCEDETH_NAPI=y
and the messages still come.
so you systems are using ioapic routing, or msi.
and those messages are from
nv_nic_irq_optimized or nv_nic_irq
for TX or OTHER (timerirq).
yes, IO-APIC:
18: 81386 306713817 0 0 1413724087 0 0
0 0 0 0 0 0 0 0
0 IO-APIC-fasteoi eth2
Those messages do come and are annoying.
Ingo
From: Yinghai Lu <yinghai@kernel.org> Date: 2009-02-09 19:15:21
Ingo Molnar wrote:
* Yinghai Lu [off-list ref] wrote:
quoted
Ingo Molnar wrote:
quoted
* Yinghai Lu [off-list ref] wrote:
quoted
Ingo Molnar wrote:
quoted
Cool cleanups!
Would you mind to also fix the following - on all my systems that have
forcedeth gigabit ethernet i've been getting these bogus warnings for
_years_, under moderate load:
eth2: too many iterations (16) in nv_nic_irq.
I think a 64 iterations limit will work much better. (i tried a limit of 50
a year ago for a while and it worked fine and had no side effects - and the
bogus warnings were done.)
you may enable CONFIG_FORCEDETH_NAPI.
we should enable NAPI for forcedeth by default, and try to squash more bugs out.
i do have that:
CONFIG_FORCEDETH=y
CONFIG_FORCEDETH_NAPI=y
and the messages still come.
so you systems are using ioapic routing, or msi.
and those messages are from
nv_nic_irq_optimized or nv_nic_irq
for TX or OTHER (timerirq).
yes, IO-APIC:
18: 81386 306713817 0 0 1413724087 0 0
0 0 0 0 0 0 0 0
0 IO-APIC-fasteoi eth2
Those messages do come and are annoying.
it seems timerirq by nic cause extra irq...
need to figure out why all devices need that workaround..., checked ck804 and mcp55 doesn't need it.
YH