mirror of
https://github.com/torvalds/linux.git
synced 2026-09-22 04:34:03 +02:00
mm/damon/reclaim: remove duplicated min_region_sz power of 2 check
DAMON_RECLAIM validates the user input for min_region_sz. The same validation is done inside damon_start() and damon_commit_ctx(). Remove the duplicate. Link: https://lore.kernel.org/20260705155600.96555-5-sj@kernel.org Signed-off-by: SJ Park <sj@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
This commit is contained in:
parent
fa93d15562
commit
529ba07482
|
|
@ -208,11 +208,6 @@ static int damon_reclaim_apply_parameters(void)
|
|||
param_ctx->addr_unit = addr_unit;
|
||||
param_ctx->min_region_sz = max(DAMON_MIN_REGION_SZ / addr_unit, 1);
|
||||
|
||||
if (!is_power_of_2(param_ctx->min_region_sz)) {
|
||||
err = -EINVAL;
|
||||
goto out;
|
||||
}
|
||||
|
||||
if (!damon_reclaim_mon_attrs.aggr_interval) {
|
||||
err = -EINVAL;
|
||||
goto out;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user