Passing UMA_ZONE_NOFREE to uma_zcreate() for swpctrie_zone and swblk_zone is
redundant, because uma_zone_reserve_kva() is performed on both zones and it sets this same flag on the zone. (Moreover, the implementation of the swap pager does not itself require these zones to be UMA_ZONE_NOFREE.) Reviewed by: kib, markj Approved by: re (gjb) MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D17296
This commit is contained in:
parent
3d14a7bb43
commit
f5fbe90de4
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=338912
@ -545,13 +545,11 @@ swap_pager_swap_init(void)
|
||||
if (maxswzone && n > maxswzone / sizeof(struct swblk))
|
||||
n = maxswzone / sizeof(struct swblk);
|
||||
swpctrie_zone = uma_zcreate("swpctrie", pctrie_node_size(), NULL, NULL,
|
||||
pctrie_zone_init, NULL, UMA_ALIGN_PTR,
|
||||
UMA_ZONE_NOFREE | UMA_ZONE_VM);
|
||||
pctrie_zone_init, NULL, UMA_ALIGN_PTR, UMA_ZONE_VM);
|
||||
if (swpctrie_zone == NULL)
|
||||
panic("failed to create swap pctrie zone.");
|
||||
swblk_zone = uma_zcreate("swblk", sizeof(struct swblk), NULL, NULL,
|
||||
NULL, NULL, _Alignof(struct swblk) - 1,
|
||||
UMA_ZONE_NOFREE | UMA_ZONE_VM);
|
||||
NULL, NULL, _Alignof(struct swblk) - 1, UMA_ZONE_VM);
|
||||
if (swblk_zone == NULL)
|
||||
panic("failed to create swap blk zone.");
|
||||
n2 = n;
|
||||
|
Loading…
Reference in New Issue
Block a user