summaryrefslogtreecommitdiffstats
path: root/sys/netinet6/nd6_rtr.c
diff options
context:
space:
mode:
authorbz <bz@FreeBSD.org>2009-02-04 10:35:27 +0000
committerbz <bz@FreeBSD.org>2009-02-04 10:35:27 +0000
commit5af7ae8eacea1f123d5f1dfce499fa0a528f2815 (patch)
tree33afa0b9c2c375f4cb14c335514a9d43e0c00478 /sys/netinet6/nd6_rtr.c
parentb979733e865fa3b6687b599751d90a7f2b508a77 (diff)
downloadFreeBSD-src-5af7ae8eacea1f123d5f1dfce499fa0a528f2815.zip
FreeBSD-src-5af7ae8eacea1f123d5f1dfce499fa0a528f2815.tar.gz
When iterating through the list trying to find a router in
defrouter_select(), NULL the cached llentry after unlocking as we are no longer interested in it and with the second iteration would try to unlock it again resulting in panic: Lock (rw) lle not locked @ ... Reported by: Mark Atkinson <m.atkinson@f5.com> Tested by: Mark Atkinson <m.atkinson@f5.com> PR: kern/128247 (in follow-up, unrelated to original report)
Diffstat (limited to 'sys/netinet6/nd6_rtr.c')
-rw-r--r--sys/netinet6/nd6_rtr.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/netinet6/nd6_rtr.c b/sys/netinet6/nd6_rtr.c
index 2f2d2ff..2bf47d2 100644
--- a/sys/netinet6/nd6_rtr.c
+++ b/sys/netinet6/nd6_rtr.c
@@ -651,8 +651,10 @@ defrouter_select(void)
selected_dr = dr;
}
IF_AFDATA_UNLOCK(dr->ifp);
- if (ln != NULL)
+ if (ln != NULL) {
LLE_RUNLOCK(ln);
+ ln = NULL;
+ }
if (dr->installed && installed_dr == NULL)
installed_dr = dr;
OpenPOWER on IntegriCloud