UMA zone limit can be lowered, so remove protection against from
the sysctl_handle_uma_zone_max(). Sponsored by: Nginx, Inc.
This commit is contained in:
parent
c047fd1b99
commit
16be9f54e7
@ -3540,16 +3540,13 @@ int
|
||||
sysctl_handle_uma_zone_max(SYSCTL_HANDLER_ARGS)
|
||||
{
|
||||
uma_zone_t zone = *(uma_zone_t *)arg1;
|
||||
int error, max, old;
|
||||
int error, max;
|
||||
|
||||
old = max = uma_zone_get_max(zone);
|
||||
max = uma_zone_get_max(zone);
|
||||
error = sysctl_handle_int(oidp, &max, 0, req);
|
||||
if (error || !req->newptr)
|
||||
return (error);
|
||||
|
||||
if (max < old)
|
||||
return (EINVAL);
|
||||
|
||||
uma_zone_set_max(zone, max);
|
||||
|
||||
return (0);
|
||||
|
Loading…
Reference in New Issue
Block a user