diff options
author | arr <arr@FreeBSD.org> | 2002-04-25 06:24:40 +0000 |
---|---|---|
committer | arr <arr@FreeBSD.org> | 2002-04-25 06:24:40 +0000 |
commit | 99bf18775ecdf71c0a8a2c322e14cd90ba68bd09 (patch) | |
tree | 69c460a341f2b2b3653de3341b747de1d258d081 | |
parent | 04da61f7a875bdb9921a4311db15271f9ac4cf24 (diff) | |
download | FreeBSD-src-99bf18775ecdf71c0a8a2c322e14cd90ba68bd09.zip FreeBSD-src-99bf18775ecdf71c0a8a2c322e14cd90ba68bd09.tar.gz |
- Fix a round down bogon in uma_zone_set_max().
Submitted by: jeff@
-rw-r--r-- | sys/vm/uma_core.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/vm/uma_core.c b/sys/vm/uma_core.c index bac697a..8418fed 100644 --- a/sys/vm/uma_core.c +++ b/sys/vm/uma_core.c @@ -1801,6 +1801,8 @@ uma_zone_set_max(uma_zone_t zone, int nitems) zone->uz_maxpages = nitems * zone->uz_ppera; else zone->uz_maxpages = nitems / zone->uz_ipers; + if (zone->uz_maxpages * zone->uz_ipers < nitems) + zone->uz_maxpages++; ZONE_UNLOCK(zone); } |