CVE-2026-80592: samples/damon/mtier: fail early if address range parameters are invalid
In the Linux kernel, the following vulnerability has been resolved:
samples/damon/mtier: fail early if address range parameters are invalid
The comment on top of struct damonregion clearly says that
For any use case, @ar should be non-zero positive size.
which is now verified in damonverifynewregion() if the kernel is built with DAMONDEBUGSANITY.
The WARNONCE() can be triggered if the mtier sample module is enabled before node{0,1}{start,end}addr have been properly initialized, which is obviously not good.
------------[ cut here ]------------ start 0 >= end 0 WARNING: mm/damon/core.c:217 at damonnewregion+0xf4/0x118, CPU#59: bash/341468 Call trace: damonnewregion+0xf4/0x118 (P) damonsetregions+0xfc/0x3c0 damonsamplemtierbuildctx+0xe8/0x3a8 damonsamplemtierstart+0x1c/0x90 damonsamplemtierenablestore+0x98/0xb0 paramattrstore+0xb4/0x128 moduleattrstore+0x2c/0x50 sysfskfwrite+0x58/0x90 kernfsfopwriteiter+0x16c/0x238 vfswrite+0x2c0/0x370 ksyswrite+0x74/0x118 arm64syswrite+0x24/0x38 invokesyscall+0xa8/0x118 el0svccommon.constprop.0+0x48/0xf0 doel0svc+0x24/0x38 el0svc+0x54/0x370 el0t64synchandler+0xa0/0xe8 el0t64sync+0x1ac/0x1b0 ---[ end trace 0000000000000000 ]---
Note that the same issue can happen if detectnodeaddresses is true, and node 0 or 1 is memoryless. Fix it together by checking the validity of parameters right before damonnewregion() and fail early if they're invalid.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Configuration
Build the Linux kernel with DAMON_DEBUG_SANITY so damon_verify_new_region() verifies address range parameters before damon_new_region() proceeds.
Linux kernel DAMON (samples/damon/mtier) DAMON_DEBUG_SANITY = enabled - Configuration
In samples/damon/mtier, fail early in damon_sample_mtier_build_ctx / mtier start path if address range parameters are invalid (e.g., start 0 >= end 0) so damon_new_region() is not called with uninitialized node{0,1}_{start,end}_addr.
Linux kernel DAMON (samples/damon/mtier) address range parameters validation = enabled