[IPV6]: Fix dead lock.

We need to relesae ifp->lock before we call addrconf_dad_stop(),
which will hold ifp->lock.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by YOSHIFUJI Hideaki and committed by David S. Miller 3dd3bf83 c162eeaa

+4 -4
+4 -4
net/ipv6/addrconf.c
··· 2467 return; 2468 } 2469 2470 - if (idev->if_flags & IF_READY) 2471 addrconf_dad_kick(ifp); 2472 - else { 2473 /* 2474 * If the defice is not ready: 2475 * - keep it tentative if it is a permanent address. ··· 2480 in6_ifa_hold(ifp); 2481 addrconf_dad_stop(ifp); 2482 } 2483 - 2484 - spin_unlock_bh(&ifp->lock); 2485 out: 2486 read_unlock_bh(&idev->lock); 2487 }
··· 2467 return; 2468 } 2469 2470 + if (idev->if_flags & IF_READY) { 2471 addrconf_dad_kick(ifp); 2472 + spin_unlock_bh(&ifp->lock); 2473 + } else { 2474 + spin_unlock_bh(&ifp->lock); 2475 /* 2476 * If the defice is not ready: 2477 * - keep it tentative if it is a permanent address. ··· 2478 in6_ifa_hold(ifp); 2479 addrconf_dad_stop(ifp); 2480 } 2481 out: 2482 read_unlock_bh(&idev->lock); 2483 }