• E
    net: add a core netdev->rx_dropped counter · caf586e5
    Eric Dumazet 提交于
    In various situations, a device provides a packet to our stack and we
    drop it before it enters protocol stack :
    - softnet backlog full (accounted in /proc/net/softnet_stat)
    - bad vlan tag (not accounted)
    - unknown/unregistered protocol (not accounted)
    
    We can handle a per-device counter of such dropped frames at core level,
    and automatically adds it to the device provided stats (rx_dropped), so
    that standard tools can be used (ifconfig, ip link, cat /proc/net/dev)
    
    This is a generalization of commit 8990f468 (net: rx_dropped
    accounting), thus reverting it.
    Signed-off-by: NEric Dumazet <eric.dumazet@gmail.com>
    Signed-off-by: NDavid S. Miller <davem@davemloft.net>
    caf586e5
ip_gre.c 42.4 KB