• Eric Dumazet's avatar
    tunnels: Optimize tx path · 0bfbedb1
    Eric Dumazet authored
    We currently dirty a cache line to update tunnel device stats
    (tx_packets/tx_bytes). We better use the txq->tx_bytes/tx_packets
    counters that already are present in cpu cache, in the cache
    line shared with txq->_xmit_lock
    
    This patch extends IPTUNNEL_XMIT() macro to use txq pointer
    provided by the caller.
    
    Also &tunnel->dev->stats can be replaced by &dev->stats
    Signed-off-by: default avatarEric Dumazet <eric.dumazet@gmail.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    0bfbedb1
ipip.c 20.6 KB