UPSTREAM: mm/damon/vaddr: call damon_update_region_access_rate() always
When getting mm_struct of the monitoring target process fails, there wil be no need to increase the access rate counter (nr_accesses) of the regions for the process. Hence, damon_va_check_accesses() skips calling damon_update_region_access_rate() in the case. This breaks the assumption that damon_update_region_access_rate() is called for every region, for every sampling interval. Call the function for every region even in the case. This might increase the overhead in some cases, but such case would not be frequent, so no significant impact is really expected. Link: https://lkml.kernel.org/r/20230915025251.72816-3-sj@kernel.org Signed-off-by:SeongJae Park <sj@kernel.org> Cc: Brendan Higgins <brendanhiggins@google.com> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> (cherry picked from commit 22a77880) Bug:407463672 Change-Id: I52f9ea383852ef99b6a5b94637c6681ff42a7585 Signed-off-by:
daiyang5 <daiyang5@xiaomi.com>
Loading
Please sign in to comment