diff options
author | Nicolas Dichtel <nicolas.dichtel@6wind.com> | 2015-02-05 12:21:30 -0500 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2015-02-13 23:19:58 -0500 |
commit | f9d1ce8f81eb046626cfa1bb0f419f8dca04bcae (patch) | |
tree | 80ebdf697f1b07b301dd0887d697dd2dad8b7356 /net/ieee802154/core.c | |
parent | a715d11e453c37822eca675a4445c1ce4ea7297e (diff) |
ieee802154: fix netns settings
6LoWPAN currently doesn't supports x-netns and works only in init_net.
With this patch, we ensure that:
- the wpan interface cannot be moved to another netns;
- the 6lowpan interface cannot be moved to another netns;
- the wpan interface is in the same netns than the 6lowpan interface;
- the 6lowpan interface is in init_net.
Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Acked-by: Alexander Aring <alex.aring@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'net/ieee802154/core.c')
-rw-r--r-- | net/ieee802154/core.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/net/ieee802154/core.c b/net/ieee802154/core.c index 18bc7e738507..888d0991c761 100644 --- a/net/ieee802154/core.c +++ b/net/ieee802154/core.c | |||
@@ -225,6 +225,7 @@ static int cfg802154_netdev_notifier_call(struct notifier_block *nb, | |||
225 | switch (state) { | 225 | switch (state) { |
226 | /* TODO NETDEV_DEVTYPE */ | 226 | /* TODO NETDEV_DEVTYPE */ |
227 | case NETDEV_REGISTER: | 227 | case NETDEV_REGISTER: |
228 | dev->features |= NETIF_F_NETNS_LOCAL; | ||
228 | wpan_dev->identifier = ++rdev->wpan_dev_id; | 229 | wpan_dev->identifier = ++rdev->wpan_dev_id; |
229 | list_add_rcu(&wpan_dev->list, &rdev->wpan_dev_list); | 230 | list_add_rcu(&wpan_dev->list, &rdev->wpan_dev_list); |
230 | rdev->devlist_generation++; | 231 | rdev->devlist_generation++; |