mirror of
https://github.com/opnsense/src.git
synced 2026-06-17 20:49:40 -04:00
uma: Don't allow a limit to be set in a warm zone
The limit accounting in UMA does not tolerate this. MFC after: 2 weeks Sponsored by: The FreeBSD Foundation
This commit is contained in:
parent
54361f9020
commit
d53927b0ba
1 changed files with 2 additions and 0 deletions
|
|
@ -4880,6 +4880,8 @@ uma_zone_set_max(uma_zone_t zone, int nitems)
|
|||
* way to clear a limit.
|
||||
*/
|
||||
ZONE_LOCK(zone);
|
||||
if (zone->uz_max_items == 0)
|
||||
ZONE_ASSERT_COLD(zone);
|
||||
zone->uz_max_items = nitems;
|
||||
zone->uz_flags |= UMA_ZFLAG_LIMIT;
|
||||
zone_update_caches(zone);
|
||||
|
|
|
|||
Loading…
Reference in a new issue