macvlan: lockless tx path
authorEric Dumazet <eric.dumazet@gmail.com>
Wed, 10 Nov 2010 21:14:04 +0000 (21:14 +0000)
committerDavid S. Miller <davem@davemloft.net>
Tue, 16 Nov 2010 18:58:30 +0000 (10:58 -0800)
commit8ffab51b3dfc54876f145f15b351c41f3f703195
tree0455321fbdb953e77fecff62345f8414553bc394
parent0e3125c755445664f00ad036e4fc2cd32fd52877
macvlan: lockless tx path

macvlan is a stacked device, like tunnels. We should use the lockless
mechanism we are using in tunnels and loopback.

This patch completely removes locking in TX path.

tx stat counters are added into existing percpu stat structure, renamed
from rx_stats to pcpu_stats.

Note : this reverts commit 2c11455321f37 (macvlan: add multiqueue
capability)

Note : rx_errors converted to a 32bit counter, like tx_dropped, since
they dont need 64bit range.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Cc: Patrick McHardy <kaber@trash.net>
Cc: Ben Greear <greearb@candelatech.com>
Cc: Ben Hutchings <bhutchings@solarflare.com>
Acked-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/macvlan.c
include/linux/if_macvlan.h