summaryrefslogtreecommitdiffstats
path: root/drivers/net/macvlan.c
diff options
context:
space:
mode:
authorGao Feng <gfree.wind@gmail.com>2016-11-21 01:26:38 +0100
committerDavid S. Miller <davem@davemloft.net>2016-11-21 17:58:49 +0100
commitfc51f2b7e5f6cc0bb1958efda18926b0c600e9d9 (patch)
treee223ab19084a0a36e5bd2ab0e99d1840da1e6d57 /drivers/net/macvlan.c
parentmlx4: avoid unnecessary dirtying of critical fields (diff)
downloadlinux-fc51f2b7e5f6cc0bb1958efda18926b0c600e9d9.tar.xz
linux-fc51f2b7e5f6cc0bb1958efda18926b0c600e9d9.zip
driver: macvlan: Remove duplicated IFF_UP condition check in macvlan_forward_source
The function macvlan_forward_source_one has already checked the flag IFF_UP, so needn't check it outside in macvlan_forward_source too. Signed-off-by: Gao Feng <gfree.wind@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/macvlan.c')
-rw-r--r--drivers/net/macvlan.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/macvlan.c b/drivers/net/macvlan.c
index 13b7e0b9bd9b..7ddfd2c917ea 100644
--- a/drivers/net/macvlan.c
+++ b/drivers/net/macvlan.c
@@ -400,8 +400,7 @@ static void macvlan_forward_source(struct sk_buff *skb,
hlist_for_each_entry_rcu(entry, h, hlist) {
if (ether_addr_equal_64bits(entry->addr, addr))
- if (entry->vlan->dev->flags & IFF_UP)
- macvlan_forward_source_one(skb, entry->vlan);
+ macvlan_forward_source_one(skb, entry->vlan);
}
}