diff options
author | Jiri Pirko <jpirko@redhat.com> | 2010-02-07 23:30:35 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-02-12 14:38:58 -0500 |
commit | 4cd24eaf0c6ee7f0242e34ee77ec899f255e66b5 (patch) | |
tree | 99f57f6374a58022e1e5ed1cbc12699288c7eae1 /drivers/net/enic | |
parent | 8e5574211d96c0552f84c757718475fdb4021be7 (diff) |
net: use netdev_mc_count and netdev_mc_empty when appropriate
This patch replaces dev->mc_count in all drivers (hopefully I didn't miss
anything). Used spatch and did small tweaks and conding style changes when
it was suitable.
Jirka
Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/enic')
-rw-r--r-- | drivers/net/enic/enic_main.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/enic/enic_main.c b/drivers/net/enic/enic_main.c index c81bc4b1816f..94749ebaaea8 100644 --- a/drivers/net/enic/enic_main.c +++ b/drivers/net/enic/enic_main.c | |||
@@ -827,11 +827,11 @@ static void enic_set_multicast_list(struct net_device *netdev) | |||
827 | int multicast = (netdev->flags & IFF_MULTICAST) ? 1 : 0; | 827 | int multicast = (netdev->flags & IFF_MULTICAST) ? 1 : 0; |
828 | int broadcast = (netdev->flags & IFF_BROADCAST) ? 1 : 0; | 828 | int broadcast = (netdev->flags & IFF_BROADCAST) ? 1 : 0; |
829 | int promisc = (netdev->flags & IFF_PROMISC) ? 1 : 0; | 829 | int promisc = (netdev->flags & IFF_PROMISC) ? 1 : 0; |
830 | unsigned int mc_count = netdev_mc_count(netdev); | ||
830 | int allmulti = (netdev->flags & IFF_ALLMULTI) || | 831 | int allmulti = (netdev->flags & IFF_ALLMULTI) || |
831 | (netdev->mc_count > ENIC_MULTICAST_PERFECT_FILTERS); | 832 | mc_count > ENIC_MULTICAST_PERFECT_FILTERS; |
832 | unsigned int flags = netdev->flags | (allmulti ? IFF_ALLMULTI : 0); | 833 | unsigned int flags = netdev->flags | (allmulti ? IFF_ALLMULTI : 0); |
833 | u8 mc_addr[ENIC_MULTICAST_PERFECT_FILTERS][ETH_ALEN]; | 834 | u8 mc_addr[ENIC_MULTICAST_PERFECT_FILTERS][ETH_ALEN]; |
834 | unsigned int mc_count = netdev->mc_count; | ||
835 | unsigned int i, j; | 835 | unsigned int i, j; |
836 | 836 | ||
837 | if (mc_count > ENIC_MULTICAST_PERFECT_FILTERS) | 837 | if (mc_count > ENIC_MULTICAST_PERFECT_FILTERS) |