diff options
author | Eric Dumazet <eric.dumazet@gmail.com> | 2010-05-10 16:01:31 +0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-05-10 16:01:31 +0400 |
commit | 1ae5dc342ac78d7a42965fd1f323815f6f5ef2c1 (patch) | |
tree | d1955a7639e99832590df26466a34d5786a880ae /drivers/net/ni52.c | |
parent | 2b0b05ddc04b6d45e71cd36405df512075786f1e (diff) | |
download | linux-1ae5dc342ac78d7a42965fd1f323815f6f5ef2c1.tar.xz |
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/ni52.c')
-rw-r--r-- | drivers/net/ni52.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/net/ni52.c b/drivers/net/ni52.c index b7837ebd9a7d..9bddb5fa7a96 100644 --- a/drivers/net/ni52.c +++ b/drivers/net/ni52.c @@ -1147,7 +1147,7 @@ static void ni52_timeout(struct net_device *dev) writeb(CUC_START, &p->scb->cmd_cuc); ni_attn586(); wait_for_scb_cmd(dev); - dev->trans_start = jiffies; + dev->trans_start = jiffies; /* prevent tx timeout */ return 0; } #endif @@ -1165,7 +1165,7 @@ static void ni52_timeout(struct net_device *dev) ni52_close(dev); ni52_open(dev); } - dev->trans_start = jiffies; + dev->trans_start = jiffies; /* prevent tx timeout */ } /****************************************************** @@ -1218,7 +1218,6 @@ static netdev_tx_t ni52_send_packet(struct sk_buff *skb, writeb(CUC_START, &p->scb->cmd_cuc); } ni_attn586(); - dev->trans_start = jiffies; if (!i) dev_kfree_skb(skb); wait_for_scb_cmd(dev); @@ -1240,7 +1239,6 @@ static netdev_tx_t ni52_send_packet(struct sk_buff *skb, writew(0, &p->nop_cmds[next_nop]->cmd_status); writew(make16(p->xmit_cmds[0]), &p->nop_cmds[p->nop_point]->cmd_link); - dev->trans_start = jiffies; p->nop_point = next_nop; dev_kfree_skb(skb); # endif @@ -1256,7 +1254,6 @@ static netdev_tx_t ni52_send_packet(struct sk_buff *skb, writew(0, &p->nop_cmds[next_nop]->cmd_status); writew(make16(p->xmit_cmds[p->xmit_count]), &p->nop_cmds[p->xmit_count]->cmd_link); - dev->trans_start = jiffies; p->xmit_count = next_nop; { unsigned long flags; |