aboutsummaryrefslogtreecommitdiff
path: root/net/8021q
diff options
context:
space:
mode:
authorGravatar David S. Miller <davem@davemloft.net> 2017-10-05 17:57:03 -0700
committerGravatar David S. Miller <davem@davemloft.net> 2017-10-05 18:19:22 -0700
commit53954cf8c5d205624167a2bfd117cc0c1a5f3c6d (patch)
treea287f0c80eb616758bb5212523c8fb3d8fc350a4 /net/8021q
parentMerge branch 'bpftool' (diff)
parentMerge tag 'pm-4.14-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafa... (diff)
downloadlinux-53954cf8c5d205624167a2bfd117cc0c1a5f3c6d.tar.gz
linux-53954cf8c5d205624167a2bfd117cc0c1a5f3c6d.tar.bz2
linux-53954cf8c5d205624167a2bfd117cc0c1a5f3c6d.zip
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Just simple overlapping changes. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/8021q')
-rw-r--r--net/8021q/vlan_core.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/net/8021q/vlan_core.c b/net/8021q/vlan_core.c
index e2ed69850489..0bc31de9071a 100644
--- a/net/8021q/vlan_core.c
+++ b/net/8021q/vlan_core.c
@@ -21,6 +21,12 @@ bool vlan_do_receive(struct sk_buff **skbp)
if (unlikely(!skb))
return false;
+ if (unlikely(!(vlan_dev->flags & IFF_UP))) {
+ kfree_skb(skb);
+ *skbp = NULL;
+ return false;
+ }
+
skb->dev = vlan_dev;
if (unlikely(skb->pkt_type == PACKET_OTHERHOST)) {
/* Our lower layer thinks this is not local, let's make sure.