Skip to content

Commit 628592c

Browse files
herbertxDavid S. Miller
authored andcommitted
[NETDRV]: Perform missing csum_offset conversions
When csum_offset was introduced we did a conversion from csum to csum_offset where applicable. A couple of drivers were missed in this process. It was harmless to begin with since the two fields coincided. Now that we've made them different with the addition of csum_start, the missed drivers must be converted or they can't send packets out at all that require checksum offload. Signed-off-by: Herbert Xu <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 663ead3 commit 628592c

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

drivers/net/atl1/atl1_main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1328,7 +1328,7 @@ static int atl1_tx_csum(struct atl1_adapter *adapter, struct sk_buff *skb,
13281328

13291329
if (likely(skb->ip_summed == CHECKSUM_PARTIAL)) {
13301330
cso = skb_transport_offset(skb);
1331-
css = cso + skb->csum;
1331+
css = cso + skb->csum_offset;
13321332
if (unlikely(cso & 0x1)) {
13331333
printk(KERN_DEBUG "%s: payload offset != even number\n",
13341334
atl1_driver_name);

drivers/net/e1000/e1000_main.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2959,7 +2959,8 @@ e1000_tx_csum(struct e1000_adapter *adapter, struct e1000_tx_ring *tx_ring,
29592959

29602960
context_desc->lower_setup.ip_config = 0;
29612961
context_desc->upper_setup.tcp_fields.tucss = css;
2962-
context_desc->upper_setup.tcp_fields.tucso = css + skb->csum;
2962+
context_desc->upper_setup.tcp_fields.tucso =
2963+
css + skb->csum_offset;
29632964
context_desc->upper_setup.tcp_fields.tucse = 0;
29642965
context_desc->tcp_seg_setup.data = 0;
29652966
context_desc->cmd_and_length = cpu_to_le32(E1000_TXD_CMD_DEXT);

0 commit comments

Comments
 (0)