]> git.karo-electronics.de Git - linux-beck.git/commit
net: addr_list: add exclusive dev_uc_add and dev_mc_add
authorJohn Fastabend <john.r.fastabend@intel.com>
Sun, 15 Apr 2012 06:44:02 +0000 (06:44 +0000)
committerDavid S. Miller <davem@davemloft.net>
Sun, 15 Apr 2012 17:06:04 +0000 (13:06 -0400)
commit12a94634453c61fd9a11c4702002e3db6d4feb70
tree1131fded53fdab8b912cd14d8240def52166d2f2
parent77162022ab26a1f99d3af30c03760a76f86e193d
net: addr_list: add exclusive dev_uc_add and dev_mc_add

This adds a dev_uc_add_excl() and dev_mc_add_excl() calls
similar to the original dev_{uc|mc}_add() except it sets
the global bit and returns -EEXIST for duplicat entires.

This is useful for drivers that support SR-IOV, macvlan
devices and any other devices that need to manage the
unicast and multicast lists.

v2: fix typo UNICAST should be MULTICAST in dev_mc_add_excl()

CC: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: John Fastabend <john.r.fastabend@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/netdevice.h
net/core/dev_addr_lists.c