Pass RTF_RNH_LOCKED to rtalloc1 sunce the node head is locked, this avoids a

recursive lock panic on inet6 detach.

Reviewed by:	kmacy
This commit is contained in:
Andrew Thompson 2008-12-12 01:46:59 +00:00
parent db10c0837d
commit 84b5117529
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=185964

View File

@ -834,7 +834,7 @@ in6_ifdetach(struct ifnet *ifp)
/* XXX grab lock first to avoid LOR */
if (V_rt_tables[0][AF_INET6] != NULL) {
RADIX_NODE_HEAD_LOCK(V_rt_tables[0][AF_INET6]);
rt = rtalloc1((struct sockaddr *)&sin6, 0, 0UL);
rt = rtalloc1((struct sockaddr *)&sin6, RTF_RNH_LOCKED, 0UL);
if (rt) {
if (rt->rt_ifp == ifp)
rtexpunge(rt);