PERFORCE change 167395 for review
Marko Zec
zec at FreeBSD.org
Sun Aug 16 09:24:23 UTC 2009
http://perforce.freebsd.org/chv.cgi?CH=167395
Change 167395 by zec at zec_tpx32 on 2009/08/16 09:24:12
Further simplify the ipdivert V_ patch - there's no real
need to iterate over all vnets in div_zone_change() when
maxsockets get increased. Given that maxsockets is a
global variable, it cannot be changed by any of the non-default
vnets anyhow, so div_zone_change() will be always called
from the context of vnet0. Given that maxsockets cannot
shrink but only grow, and that ipdivert will have only a
single or exceptionally a few socket consumers anyhow, there's
no need to increase UMA zone limits in non-default vnets.
Affected files ...
.. //depot/projects/vimage-commit2/src/sys/netinet/ip_divert.c#41 edit
Differences ...
==== //depot/projects/vimage-commit2/src/sys/netinet/ip_divert.c#41 (text+ko) ====
@@ -133,15 +133,8 @@
static void
div_zone_change(void *tag)
{
- VNET_ITERATOR_DECL(vnet_iter);
- VNET_LIST_RLOCK_NOSLEEP();
- VNET_FOREACH(vnet_iter) {
- CURVNET_SET(vnet_iter);
- uma_zone_set_max(V_divcbinfo.ipi_zone, maxsockets);
- CURVNET_RESTORE();
- }
- VNET_LIST_RUNLOCK_NOSLEEP();
+ uma_zone_set_max(V_divcbinfo.ipi_zone, maxsockets);
}
static int
More information about the p4-projects
mailing list