* + mm-damon-paddr-add-kunit-tests-for-addr_unit-conversion-fix.patch added to mm-unstable branch
@ 2026-11-18 2:32 Andrew Morton
0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2026-11-18 2:32 UTC (permalink / raw)
To: mm-commits, sj, rdunlap, ndesaulniers, nathan, morbo, lkp, lienze,
justinstitt, david, jm5905938, akpm
The patch titled
Subject: mm/damon/paddr: avoid truncation warning in high-address KUnit test
has been added to the -mm mm-unstable branch. Its filename is
mm-damon-paddr-add-kunit-tests-for-addr_unit-conversion-fix.patch
This patch will shortly appear at
https://git.kernel.org/pub/scm/linux/kernel/git/akpm/25-new.git/tree/patches/mm-damon-paddr-add-kunit-tests-for-addr_unit-conversion-fix.patch
This patch will later appear in the mm-unstable branch at
git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
Before you just go and hit "reply", please:
a) Consider who else should be cc'ed
b) Prefer to cc a suitable mailing list as well
c) Ideally: find the original patch on the mailing list and do a
reply-to-all to that, adding suitable additional cc's
*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***
The -mm tree is included into linux-next via various
branches at git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
and is updated there most days
------------------------------------------------------
From: Aveline Noir <jm5905938@gmail.com>
Subject: mm/damon/paddr: avoid truncation warning in high-address KUnit test
Date: Wed, 18 Nov 2026 04:04:33 +1100
When phys_addr_t is 32-bit, Sparse warns about truncating the u64 address
passed to damon_pa_core_addr() in damon_test_pa_addr_over_4g(). The
runtime kunit_skip() does not prevent Sparse from checking that
conversion.
Compile the high-address assertions only with CONFIG_PHYS_ADDR_T_64BIT,
and keep the test skipped otherwise.
Link: https://lore.kernel.org/20261118-fix-damon-paddr-sparse-20261118-v1-1-3a0e943406d5@gmail.com
Fixes: 7a983cc1b573 ("mm/damon/paddr: add KUnit tests for addr_unit conversion")
Signed-off-by: Aveline Noir <jm5905938@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/20261117170155.fEdeuuhm-lkp@intel.com/
Cc: SJ Park <sj@kernel.org>
Cc: David Hildenbrand <david@kernel.org>
Cc: Justin Stitt <justinstitt@google.com>
Cc: Bill Wendling <morbo@google.com>
Cc: Nathan Chancellor <nathan@kernel.org>
Cc: Nick Desaulniers <ndesaulniers@google.com>
Cc: Enze Li <lienze@kylinos.cn>
Cc: Randy Dunlap <rdunlap@infradead.org>
mm/damon/tests/paddr-kunit.h | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
--- a/mm/damon/tests/paddr-kunit.h~mm-damon-paddr-add-kunit-tests-for-addr_unit-conversion-fix
+++ a/mm/damon/tests/paddr-kunit.h
@@ -26,15 +26,16 @@ static void damon_test_pa_core_addr(stru
static void damon_test_pa_addr_over_4g(struct kunit *test)
{
+#ifdef CONFIG_PHYS_ADDR_T_64BIT
unsigned long addr = 0xffffffffUL;
unsigned long addr_unit = 0x1000;
u64 pa = 0xffffffff000ULL;
- if (!IS_ENABLED(CONFIG_PHYS_ADDR_T_64BIT))
- kunit_skip(test, "phys_addr_t is 32-bit");
-
KUNIT_EXPECT_EQ(test, damon_pa_phys_addr(addr, addr_unit), pa);
KUNIT_EXPECT_EQ(test, damon_pa_core_addr(pa, addr_unit), addr);
+#else
+ kunit_skip(test, "phys_addr_t is 32-bit");
+#endif
}
static struct kunit_case damon_paddr_test_cases[] = {
_
Patches currently in -mm which might be from jm5905938@gmail.com are
mm-damon-ops-common-align-mmu-notifier-range-when-clearing-pmd-young-bit.patch
mm-damon-stat-avoid-32-bit-overflow-in-idle-percentiles.patch
mm-damon-pvaddr-skip-folios-already-on-the-migration-target-node.patch
docs-admin-guide-mm-damon-start-fix-grammar.patch
docs-admin-guide-mm-damon-stat-fix-pronoun-agreement.patch
docs-admin-guide-mm-damon-usage-fix-grammar.patch
docs-admin-guide-mm-damon-lru_sort-fix-remaining-grammar.patch
docs-mm-damon-design-fix-grammar-and-typos.patch
docs-mm-damon-api-fix-verb-form.patch
docs-mm-damon-maintainer-profile-fix-subject-verb-agreement.patch
docs-mm-damon-monitoring_intervals_tuning_example-fix-grammar-and-typos.patch
mm-damon-paddr-add-kunit-tests-for-addr_unit-conversion.patch
mm-damon-paddr-add-kunit-tests-for-addr_unit-conversion-fix.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-11-18 2:32 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-18 2:32 + mm-damon-paddr-add-kunit-tests-for-addr_unit-conversion-fix.patch added to mm-unstable branch Andrew Morton
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.