mm/damon/core-test: add a test for damon_set_attrs()
authorSeongJae Park <sj@kernel.org>
Thu, 15 Jun 2023 18:33:22 +0000 (18:33 +0000)
committerAndrew Morton <akpm@linux-foundation.org>
Mon, 19 Jun 2023 23:19:35 +0000 (16:19 -0700)
commitaa13779be6b7d1ce0e6ba96b400b351de6f1a326
tree9ca673e64627e0e24f68c5434d774540688cfda4
parent5d949953f841fd661a2a49df188426d5930ed723
mm/damon/core-test: add a test for damon_set_attrs()

Commit 5ff6e2fff88e ("mm/damon/core: fix divide error in
damon_nr_accesses_to_accesses_bp()") fixed a bug by adding arguments
validation in damon_set_attrs().  Add a unit test for the added validation
to ensure the bug cannot occur again.

Link: https://lkml.kernel.org/r/20230615183323.87561-1-sj@kernel.org
Signed-off-by: SeongJae Park <sj@kernel.org>
Reviewed-by: Kefeng Wang <wangkefeng.wang@huawei.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/damon/core-test.h