On Sat, Dec 03, 2005, Linus Torvalds wrote:
shemminger@osdl.org:
sk98lin: fix checksumming code
sk98lin: add permanent address support
sk98lin: avoid message confusion with skge
I have an Asus P4P800 "Deluxe" with 3c940 LOM.
If I ping the box I get the following:
Dec 4 22:57:02 abc kernel: [<c0103c00>] dump_stack+0x17/0x19
Dec 4 22:57:02 abc kernel: [<c03b99e9>] netdev_rx_csum_fault+0x27/0x2d
Dec 4 22:57:02 abc kernel: [<c03b75a9>] __skb_checksum_complete+0x5a/0x60
Dec 4 22:57:02 abc kernel: [<c0404c51>] icmp_error+0xbd/0x193
Dec 4 22:57:02 abc kernel: [<c0402291>] ip_conntrack_in+0x67/0x279
Dec 4 22:57:02 abc kernel: [<c03c8cbf>] nf_iterate+0x59/0x7d
Dec 4 22:57:02 abc kernel: [<c03c8d3a>] nf_hook_slow+0x57/0x106
Dec 4 22:57:02 abc kernel: [<c03d1074>] ip_rcv+0x1af/0x580
Dec 4 22:57:02 abc kernel: [<c03ba1ed>] netif_receive_skb+0x15a/0x1ef
Dec 4 22:57:02 abc kernel: [<c03ba301>] process_backlog+0x7f/0x10d
Dec 4 22:57:02 abc kernel: [<c03ba40c>] net_rx_action+0x7d/0x110
Dec 4 22:57:02 abc kernel: [<c01250a2>] __do_softirq+0x72/0xe1
Dec 4 22:57:02 abc kernel: [<c0104ed7>] do_softirq+0x5d/0x61
Dec 4 22:57:02 abc kernel: =======================
Dec 4 22:57:02 abc kernel: [<c01251fa>] irq_exit+0x48/0x4a
Dec 4 22:57:02 abc kernel: [<c0104d9d>] do_IRQ+0x5d/0x8f
Dec 4 22:57:02 abc kernel: [<c010372e>] common_interrupt+0x1a/0x20
Dec 4 22:57:02 abc kernel: [<c0100d51>] cpu_idle+0x49/0xa0
Dec 4 22:57:02 abc kernel: [<c01002d7>] rest_init+0x37/0x39
Dec 4 22:57:02 abc kernel: [<c057f8cf>] start_kernel+0x164/0x177
Dec 4 22:57:02 abc kernel: [<c0100210>] 0xc0100210
(once for each ICMP packet)
2.6.15-rc2 works fine.
Johannes
The checksum offsets for receive offload were not being set correctly.
Signed-off-by: Stephen Hemminger <redacted>
Index: linux-2.6/drivers/net/sk98lin/skge.c
===================================================================
--- linux-2.6.orig/drivers/net/sk98lin/skge.c
+++ linux-2.6/drivers/net/sk98lin/skge.c
@@ -818,7 +818,7 @@ uintptr_t VNextDescr; /* the virtual bus
/* set the pointers right */
pDescr->VNextRxd = VNextDescr & 0xffffffffULL;
pDescr->pNextRxd = pNextDescr;
- pDescr->TcpSumStarts = 0;
+ if (!IsTx) pDescr->TcpSumStarts = ETH_HLEN << 16 | ETH_HLEN;
/* advance one step */
pPrevDescr = pDescr;
@@ -2169,7 +2169,7 @@ rx_start:
} /* frame > SK_COPY_TRESHOLD */
#ifdef USE_SK_RX_CHECKSUM
- pMsg->csum = pRxd->TcpSums;
+ pMsg->csum = pRxd->TcpSums & 0xffff;
pMsg->ip_summed = CHECKSUM_HW;
#else
pMsg->ip_summed = CHECKSUM_NONE;
On Mon, Dec 05, 2005, Stephen Hemminger wrote:
The checksum offsets for receive offload were not being set correctly.
Signed-off-by: Stephen Hemminger <redacted>
I can confirm that this patch fixes the problem for me.
Thanks,
Johannes
quoted hunk
Index: linux-2.6/drivers/net/sk98lin/skge.c
===================================================================
--- linux-2.6.orig/drivers/net/sk98lin/skge.c
+++ linux-2.6/drivers/net/sk98lin/skge.c
@@ -818,7 +818,7 @@ uintptr_t VNextDescr; /* the virtual bus
/* set the pointers right */
pDescr->VNextRxd = VNextDescr & 0xffffffffULL;
pDescr->pNextRxd = pNextDescr;
- pDescr->TcpSumStarts = 0;
+ if (!IsTx) pDescr->TcpSumStarts = ETH_HLEN << 16 | ETH_HLEN;
/* advance one step */
pPrevDescr = pDescr;
@@ -2169,7 +2169,7 @@ rx_start:
} /* frame > SK_COPY_TRESHOLD */
#ifdef USE_SK_RX_CHECKSUM
- pMsg->csum = pRxd->TcpSums;
+ pMsg->csum = pRxd->TcpSums & 0xffff;
pMsg->ip_summed = CHECKSUM_HW;
#else
pMsg->ip_summed = CHECKSUM_NONE;
Johannes Stezenbach wrote:
On Sat, Dec 03, 2005, Linus Torvalds wrote:
quoted
shemminger@osdl.org:
sk98lin: fix checksumming code
sk98lin: add permanent address support
sk98lin: avoid message confusion with skge
I have an Asus P4P800 "Deluxe" with 3c940 LOM.
If I ping the box I get the following:
Dec 4 22:57:02 abc kernel: [<c0103c00>] dump_stack+0x17/0x19
Dec 4 22:57:02 abc kernel: [<c03b99e9>] netdev_rx_csum_fault+0x27/0x2d
Dec 4 22:57:02 abc kernel: [<c03b75a9>] __skb_checksum_complete+0x5a/0x60
Dec 4 22:57:02 abc kernel: [<c0404c51>] icmp_error+0xbd/0x193
Dec 4 22:57:02 abc kernel: [<c0402291>] ip_conntrack_in+0x67/0x279
Dec 4 22:57:02 abc kernel: [<c03c8cbf>] nf_iterate+0x59/0x7d
Dec 4 22:57:02 abc kernel: [<c03c8d3a>] nf_hook_slow+0x57/0x106
Dec 4 22:57:02 abc kernel: [<c03d1074>] ip_rcv+0x1af/0x580
Dec 4 22:57:02 abc kernel: [<c03ba1ed>] netif_receive_skb+0x15a/0x1ef
Dec 4 22:57:02 abc kernel: [<c03ba301>] process_backlog+0x7f/0x10d
Dec 4 22:57:02 abc kernel: [<c03ba40c>] net_rx_action+0x7d/0x110
Dec 4 22:57:02 abc kernel: [<c01250a2>] __do_softirq+0x72/0xe1
Dec 4 22:57:02 abc kernel: [<c0104ed7>] do_softirq+0x5d/0x61
Dec 4 22:57:02 abc kernel: =======================
Dec 4 22:57:02 abc kernel: [<c01251fa>] irq_exit+0x48/0x4a
Dec 4 22:57:02 abc kernel: [<c0104d9d>] do_IRQ+0x5d/0x8f
Dec 4 22:57:02 abc kernel: [<c010372e>] common_interrupt+0x1a/0x20
Dec 4 22:57:02 abc kernel: [<c0100d51>] cpu_idle+0x49/0xa0
Dec 4 22:57:02 abc kernel: [<c01002d7>] rest_init+0x37/0x39
Dec 4 22:57:02 abc kernel: [<c057f8cf>] start_kernel+0x164/0x177
Dec 4 22:57:02 abc kernel: [<c0100210>] 0xc0100210
(once for each ICMP packet)
2.6.15-rc2 works fine.
I can confirm that 2.6.15-rc3 works as well:
eth0: 3Com Gigabit LOM (3C940)
PrefPort:A RlmtMode:Check Link State
ip_tables: (C) 2000-2002 Netfilter core team
ip_tables: (C) 2000-2002 Netfilter core team
eth0: network connection up using port A
speed: 100
autonegotiation: yes
duplex mode: full
flowctrl: symmetric
irq moderation: disabled
scatter-gather: enabled
No messages from ping, although the pig is somewhat slower than I would expect, ~200us response time.
Looks like a regression, I can't try the latest kernel until Friday, it's 260 miles round trip to the machine if it doesn't boot cleanly.
Johannes
--
-bill davidsen (davidsen@tmr.com)
"The secret to procrastination is to put things off until the
last possible moment - but no longer" -me