summaryrefslogtreecommitdiffstats
path: root/sys/netinet/tcp_reass.c
diff options
context:
space:
mode:
authorandre <andre@FreeBSD.org>2013-02-01 14:21:09 +0000
committerandre <andre@FreeBSD.org>2013-02-01 14:21:09 +0000
commit922fff49539a81d39e42239d997cd370ba961492 (patch)
treeae225463a6972092a2088d5552230c4ed62ef3b9 /sys/netinet/tcp_reass.c
parent6af4b61a849d3c566a7b0cf3bea904cb54cd5dd9 (diff)
downloadFreeBSD-src-922fff49539a81d39e42239d997cd370ba961492.zip
FreeBSD-src-922fff49539a81d39e42239d997cd370ba961492.tar.gz
uma_zone_set_max() directly returns the rounded effective zone
limit. Use the return value directly instead of doing a second uma_zone_set_max() step. MFC after: 1 week
Diffstat (limited to 'sys/netinet/tcp_reass.c')
-rw-r--r--sys/netinet/tcp_reass.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/netinet/tcp_reass.c b/sys/netinet/tcp_reass.c
index 289b58a..5fd29b8 100644
--- a/sys/netinet/tcp_reass.c
+++ b/sys/netinet/tcp_reass.c
@@ -106,8 +106,8 @@ tcp_reass_zone_change(void *tag)
/* Set the zone limit and read back the effective value. */
V_tcp_reass_maxseg = nmbclusters / 16;
- uma_zone_set_max(V_tcp_reass_zone, V_tcp_reass_maxseg);
- V_tcp_reass_maxseg = uma_zone_get_max(V_tcp_reass_zone);
+ V_tcp_reass_maxseg = uma_zone_set_max(V_tcp_reass_zone,
+ V_tcp_reass_maxseg);
}
void
@@ -120,8 +120,8 @@ tcp_reass_init(void)
V_tcp_reass_zone = uma_zcreate("tcpreass", sizeof (struct tseg_qent),
NULL, NULL, NULL, NULL, UMA_ALIGN_PTR, UMA_ZONE_NOFREE);
/* Set the zone limit and read back the effective value. */
- uma_zone_set_max(V_tcp_reass_zone, V_tcp_reass_maxseg);
- V_tcp_reass_maxseg = uma_zone_get_max(V_tcp_reass_zone);
+ V_tcp_reass_maxseg = uma_zone_set_max(V_tcp_reass_zone,
+ V_tcp_reass_maxseg);
EVENTHANDLER_REGISTER(nmbclusters_change,
tcp_reass_zone_change, NULL, EVENTHANDLER_PRI_ANY);
}
OpenPOWER on IntegriCloud