summaryrefslogtreecommitdiffstats
path: root/net/8021q/vlan.c
diff options
context:
space:
mode:
authorSean Paul <seanpaul@chromium.org>2017-06-27 17:36:28 +0200
committerSean Paul <seanpaul@chromium.org>2017-06-27 17:36:28 +0200
commitc048c984de38d906bb0df56ec2ae90eafc123d0a (patch)
tree4e670e712aeedcaf2e2193b64f9120e03320e01c /net/8021q/vlan.c
parentDRM: Fix an incorrectly formatted table (diff)
parentBackmerge tag 'v4.12-rc7' into drm-next (diff)
downloadlinux-c048c984de38d906bb0df56ec2ae90eafc123d0a.tar.xz
linux-c048c984de38d906bb0df56ec2ae90eafc123d0a.zip
Merge remote-tracking branch 'airlied/drm-next' into drm-misc-next-fixes
Backmerge drm-next with rc7
Diffstat (limited to 'net/8021q/vlan.c')
-rw-r--r--net/8021q/vlan.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/8021q/vlan.c b/net/8021q/vlan.c
index 467069b73ce1..9649579b5b9f 100644
--- a/net/8021q/vlan.c
+++ b/net/8021q/vlan.c
@@ -277,7 +277,8 @@ static int register_vlan_device(struct net_device *real_dev, u16 vlan_id)
return 0;
out_free_newdev:
- free_netdev(new_dev);
+ if (new_dev->reg_state == NETREG_UNINITIALIZED)
+ free_netdev(new_dev);
return err;
}