Skip to content

Commit

Permalink
smsc9420: fix big endian rx checksum offload
Browse files Browse the repository at this point in the history
The cpu_to_le16 here looks suspicious to me, I don't think we need it
because put_unaligned_le16 also does this.

I don't currently have any big endian hardware with a PCI bus available
to test on, so I haven't been able to verify this.

Signed-off-by: Steve Glendinning <steve.glendinning@smsc.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Steve Glendinning authored and David S. Miller committed Mar 20, 2009
1 parent 8fd17f2 commit cd7a3b7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/smsc9420.c
Original file line number Diff line number Diff line change
Expand Up @@ -807,7 +807,7 @@ static void smsc9420_rx_handoff(struct smsc9420_pdata *pd, const int index,
if (pd->rx_csum) {
u16 hw_csum = get_unaligned_le16(skb_tail_pointer(skb) +
NET_IP_ALIGN + packet_length + 4);
put_unaligned_le16(cpu_to_le16(hw_csum), &skb->csum);
put_unaligned_le16(hw_csum, &skb->csum);
skb->ip_summed = CHECKSUM_COMPLETE;
}

Expand Down

0 comments on commit cd7a3b7

Please sign in to comment.