commit 95d67494dc4090820af22b88fae8ff6322712d86 Author: Ryota Ozaki Date: Fri Sep 4 11:11:24 2015 +0900 softnet_lock lltable_free diff --git a/sys/net/if_llatbl.c b/sys/net/if_llatbl.c index 1c3e1e8..7726713 100644 --- a/sys/net/if_llatbl.c +++ b/sys/net/if_llatbl.c @@ -42,6 +42,7 @@ #include #include #include +#include #include #include #include @@ -370,8 +371,9 @@ lltable_free(struct lltable *llt) llentries_unlink(llt, &dchain); IF_AFDATA_WUNLOCK(llt->llt_ifp); + mutex_enter(softnet_lock); LIST_FOREACH_SAFE(lle, &dchain, lle_chain, next) { - if (callout_stop(&lle->la_timer)) + if (callout_halt(&lle->la_timer, softnet_lock)) LLE_REMREF(lle); #if defined(__NetBSD__) /* XXX should have callback? */ @@ -380,6 +382,7 @@ lltable_free(struct lltable *llt) #endif llentry_free(lle); } + mutex_exit(softnet_lock); llt->llt_free_tbl(llt); }