diff options
author | Eric Dumazet <eric.dumazet@gmail.com> | 2010-05-10 08:01:31 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-05-10 08:01:31 -0400 |
commit | 1ae5dc342ac78d7a42965fd1f323815f6f5ef2c1 (patch) | |
tree | d1955a7639e99832590df26466a34d5786a880ae /drivers/net/tulip/de4x5.c | |
parent | 2b0b05ddc04b6d45e71cd36405df512075786f1e (diff) |
net: trans_start cleanups
Now that core network takes care of trans_start updates, dont do it
in drivers themselves, if possible. Drivers can avoid one cache miss
(on dev->trans_start) in their start_xmit() handler.
Exceptions are NETIF_F_LLTX drivers
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/tulip/de4x5.c')
-rw-r--r-- | drivers/net/tulip/de4x5.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/net/tulip/de4x5.c b/drivers/net/tulip/de4x5.c index d818456f4713..9522baf8d997 100644 --- a/drivers/net/tulip/de4x5.c +++ b/drivers/net/tulip/de4x5.c | |||
@@ -1337,7 +1337,7 @@ de4x5_open(struct net_device *dev) | |||
1337 | } | 1337 | } |
1338 | 1338 | ||
1339 | lp->interrupt = UNMASK_INTERRUPTS; | 1339 | lp->interrupt = UNMASK_INTERRUPTS; |
1340 | dev->trans_start = jiffies; | 1340 | dev->trans_start = jiffies; /* prevent tx timeout */ |
1341 | 1341 | ||
1342 | START_DE4X5; | 1342 | START_DE4X5; |
1343 | 1343 | ||
@@ -1507,7 +1507,6 @@ de4x5_queue_pkt(struct sk_buff *skb, struct net_device *dev) | |||
1507 | outl(POLL_DEMAND, DE4X5_TPD);/* Start the TX */ | 1507 | outl(POLL_DEMAND, DE4X5_TPD);/* Start the TX */ |
1508 | 1508 | ||
1509 | lp->tx_new = (++lp->tx_new) % lp->txRingSize; | 1509 | lp->tx_new = (++lp->tx_new) % lp->txRingSize; |
1510 | dev->trans_start = jiffies; | ||
1511 | 1510 | ||
1512 | if (TX_BUFFS_AVAIL) { | 1511 | if (TX_BUFFS_AVAIL) { |
1513 | netif_start_queue(dev); /* Another pkt may be queued */ | 1512 | netif_start_queue(dev); /* Another pkt may be queued */ |
@@ -1937,7 +1936,7 @@ set_multicast_list(struct net_device *dev) | |||
1937 | 1936 | ||
1938 | lp->tx_new = (++lp->tx_new) % lp->txRingSize; | 1937 | lp->tx_new = (++lp->tx_new) % lp->txRingSize; |
1939 | outl(POLL_DEMAND, DE4X5_TPD); /* Start the TX */ | 1938 | outl(POLL_DEMAND, DE4X5_TPD); /* Start the TX */ |
1940 | dev->trans_start = jiffies; | 1939 | dev->trans_start = jiffies; /* prevent tx timeout */ |
1941 | } | 1940 | } |
1942 | } | 1941 | } |
1943 | } | 1942 | } |