diff options
| author | SeongJae Park <sj@kernel.org> | 2026-05-22 18:40:13 +0300 |
|---|---|---|
| committer | Andrew Morton <akpm@linux-foundation.org> | 2026-06-05 00:45:00 +0300 |
| commit | b23dbda659b645482e3234ad10773d991a288e2f (patch) | |
| tree | c8f5bfedbd97d9f0e9a65dd7c95d0460454685f3 /include | |
| parent | ce71e5aa8dc83e703a5301644cef57dfc3caaf44 (diff) | |
| download | linux-b23dbda659b645482e3234ad10773d991a288e2f.tar.xz | |
mm/damon/core: do not use region out of a loop in damon_set_regions()
damon_set_regions() assumes the DAMON region iterator is referencing the
last region after the region iteration loop is completed. The code is
indeed implemented in the way, but that is not a documented safe behavior.
Hence it is unreliable and difficult to read. Cleanup the code to avoid
the case.
No behavioral change is intended.
Link: https://lore.kernel.org/20260522154026.80546-3-sj@kernel.org
Signed-off-by: SeongJae Park <sj@kernel.org>
Cc: Brendan Higgins <brendan.higgins@linux.dev>
Cc: Shuah Khan <shuah@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions
