summaryrefslogtreecommitdiffstats
path: root/sys/net/if_llatbl.c
diff options
context:
space:
mode:
authorbz <bz@FreeBSD.org>2010-10-16 18:42:09 +0000
committerbz <bz@FreeBSD.org>2010-10-16 18:42:09 +0000
commite7e5079137c3881bd359a41ee2809794189db487 (patch)
tree76eff86417a70191a47a410eb3ecd852b49db437 /sys/net/if_llatbl.c
parentf49f5e7badc63571d152296b1b1faf66cb998567 (diff)
downloadFreeBSD-src-e7e5079137c3881bd359a41ee2809794189db487.zip
FreeBSD-src-e7e5079137c3881bd359a41ee2809794189db487.tar.gz
lltable_drain() has never been used so far, thus #if 0 it for now.
While touching it add the missing locking to the now disabled code for the time when we'll resurrect it. MFC after: 3 days
Diffstat (limited to 'sys/net/if_llatbl.c')
-rw-r--r--sys/net/if_llatbl.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/net/if_llatbl.c b/sys/net/if_llatbl.c
index d516dbc..a0fb071 100644
--- a/sys/net/if_llatbl.c
+++ b/sys/net/if_llatbl.c
@@ -183,6 +183,7 @@ lltable_free(struct lltable *llt)
free(llt, M_LLTABLE);
}
+#if 0
void
lltable_drain(int af)
{
@@ -197,15 +198,18 @@ lltable_drain(int af)
for (i=0; i < LLTBL_HASHTBL_SIZE; i++) {
LIST_FOREACH(lle, &llt->lle_head[i], lle_next) {
+ LLE_WLOCK(lle);
if (lle->la_hold) {
m_freem(lle->la_hold);
lle->la_hold = NULL;
}
+ LLE_WUNLOCK(lle);
}
}
}
LLTABLE_RUNLOCK();
}
+#endif
void
lltable_prefix_free(int af, struct sockaddr *prefix, struct sockaddr *mask)
OpenPOWER on IntegriCloud