summaryrefslogtreecommitdiff
path: root/net/batman-adv/soft-interface.c
diff options
context:
space:
mode:
authorSven Eckelmann <sven@narfation.org>2011-05-03 11:51:38 +0200
committerSven Eckelmann <sven@narfation.org>2011-05-08 16:10:41 +0200
commitc3caf5196c47a5d1c325308d8eb7f6b020ba12df (patch)
tree6c94a6272919cb238dea5e0d4a3c06f27e7bb3f3 /net/batman-adv/soft-interface.c
parent61906ae86d8989e5bd3bc1f51b2fb8d32ffde2c5 (diff)
downloadlwn-c3caf5196c47a5d1c325308d8eb7f6b020ba12df.tar.gz
lwn-c3caf5196c47a5d1c325308d8eb7f6b020ba12df.zip
batman-adv: Remove unnecessary hardif_list_lock
hardif_list_lock is unneccessary because we already ensure that no multiple admin operations can take place through rtnl_lock. hardif_list_lock only adds additional overhead and complexity. Critical functions now check whether they are called with rtnl_lock using ASSERT_RTNL. It indirectly fixes the problem that orig_hash_del_if() expects that only one interface is deleted from hardif_list at a time, but hardif_remove_interfaces() removes all at once and then calls orig_hash_del_if(). Reported-by: Linus Lüssing <linus.luessing@web.de> Signed-off-by: Sven Eckelmann <sven@narfation.org>
Diffstat (limited to 'net/batman-adv/soft-interface.c')
-rw-r--r--net/batman-adv/soft-interface.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/batman-adv/soft-interface.c b/net/batman-adv/soft-interface.c
index 8cb13a03b0e1..9301e21052e7 100644
--- a/net/batman-adv/soft-interface.c
+++ b/net/batman-adv/soft-interface.c
@@ -819,7 +819,7 @@ struct net_device *softif_create(char *name)
goto out;
}
- ret = register_netdev(soft_iface);
+ ret = register_netdevice(soft_iface);
if (ret < 0) {
pr_err("Unable to register the batman interface '%s': %i\n",
name, ret);