ppp: release rtnl mutex when interface creation fails
authorGuillaume Nault <g.nault@alphalink.fr>
Mon, 7 Mar 2016 18:36:44 +0000 (19:36 +0100)
committerDavid S. Miller <davem@davemloft.net>
Mon, 7 Mar 2016 21:11:31 +0000 (16:11 -0500)
Add missing rtnl_unlock() in the error path of ppp_create_interface().

Fixes: 58a89ecaca53 ("ppp: fix lockdep splat in ppp_dev_uninit()")
Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ppp/ppp_generic.c

index e8a5936..d61da9e 100644 (file)
@@ -2816,6 +2816,7 @@ static struct ppp *ppp_create_interface(struct net *net, int unit,
 
 out2:
        mutex_unlock(&pn->all_ppp_mutex);
+       rtnl_unlock();
        free_netdev(dev);
 out1:
        *retp = ret;