Nuke HAS_IP_COPYSUM for net drivers
Subsystems (2)
PATCH 1/1 Nuke HAS_IP_COPYSUM for net drivers
Entirely untested, but Obviously Correct(TM). HAS_IP_COPYSUM has been utterly meaningless for a long time.
Respective patch for via-rhine follows once I know the state of its pending patches (which I wouldn't mind getting feedback on (hint, hint!)).
Roger
drivers/net/epic100.c +0 -5
@@ -1215,13 +1215,8 @@ static int epic_rx(struct net_device *de ep->rx_ring[entry].bufaddr, ep->rx_buf_sz, PCI_DMA_FROMDEVICE); -#if 1 /* HAS_IP_COPYSUM */ eth_copy_and_sum (skb, ep->rx_skbuff[entry]->tail, pkt_len,0 );skb_put (skb, pkt_len); -#else -memcpy (skb_put (skb, pkt_len), ep->rx_skbuff[entry]->tail, - pkt_len); -#endif pci_dma_sync_single_for_device(ep->pci_dev, ep->rx_ring[entry].bufaddr, ep->rx_buf_sz,
drivers/net/natsemi.c +0 -5
@@ -1798,14 +1798,9 @@ static void netdev_rx(struct net_device np->rx_dma[entry], buflen, PCI_DMA_FROMDEVICE); -#if HAS_IP_COPYSUM eth_copy_and_sum (skb, np->rx_skbuff[entry]->tail, pkt_len,0 );skb_put (skb, pkt_len); -#else -memcpy (skb_put (skb, pkt_len), - np->rx_skbuff[entry]->tail, pkt_len); -#endif pci_dma_sync_single_for_device(np->pci_dev, np->rx_dma[entry], buflen,
drivers/net/tulip/winbond-840.c +0 -6
@@ -1292,14 +1292,8 @@ static int netdev_rx(struct net_device *pci_dma_sync_single_for_cpu (np->pci_dev,np->rx_addr[entry], np->rx_skbuff[entry]->len,PCI_DMA_FROMDEVICE ); -/* Call copy + cksum if available. */ -#if HAS_IP_COPYSUM eth_copy_and_sum (skb, np->rx_skbuff[entry]->tail, pkt_len,0 );skb_put (skb, pkt_len); -#else -memcpy (skb_put (skb, pkt_len), np->rx_skbuff[entry]->tail, - pkt_len); -#endif pci_dma_sync_single_for_device (np->pci_dev,np->rx_addr[entry], np->rx_skbuff[entry]->len,PCI_DMA_FROMDEVICE );
drivers/net/yellowfin.c +0 -5
@@ -1201,13 +1201,8 @@ static int yellowfin_rx(struct net_devicbreak ; skb->dev = dev;skb_reserve (skb,2 );/* 16 byte align the IP header */ -#if HAS_IP_COPYSUM eth_copy_and_sum (skb, rx_skb->tail, pkt_len,0 );skb_put (skb, pkt_len); -#else -memcpy (skb_put (skb, pkt_len), - rx_skb->tail, pkt_len); -#endif pci_dma_sync_single_for_device (yp->pci_dev, desc->addr, yp->rx_buf_sz,PCI_DMA_FROMDEVICE );
Quoted 2 lines · Roger Luethi
Entirely untested, but Obviously Correct(TM).
HAS_IP_COPYSUMhas been utterly meaningless for a long time.
I will apply to netdev-2.6 queue, which means it will get testing and review via Andrew's -mm tree.
After 2.6.7 is released, I'll push upstream.
Quoted 3 lines
Respective patch for via-rhine follows once I know the state of its pending patches (which I wouldn't mind getting feedback on (hint, hint!)).
Working through the backlog today, yell at me if you haven't heard anything by the end of the day :)
Jeff