Skip to contentSkip to conversation

docs-mm-damon-design-document-the-power-of-two-limitation-for-addr_unit.patch removed from -mm tree

merged mm-stable Andrew Morton 1 participant 1 message Mar 29

lore
Share & tools
lore

Andrew Morton

author tree notice Applied
#0 lore raw

The quilt patch titled
Subject: Docs/mm/damon/design: document the power-of-two limitation for addr_unit
has been removed from the -mm tree. Its filename was
docs-mm-damon-design-document-the-power-of-two-limitation-for-addr_unit.patch

This patch was dropped because it was merged into the mm-stable branch of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

------------------------------------------------------
From: SeongJae Park <[email protected]>
Subject: Docs/mm/damon/design: document the power-of-two limitation for addr_unit
Date: Sat, 7 Mar 2026 11:42:21 -0800

The min_region_sz is set as max(DAMON_MIN_REGION_SZ / addr_unit, 1). DAMON_MIN_REGION_SZ is the same to PAGE_SIZE, and addr_unit is what the user can arbitrarily set. Commit c80f46ac228b ("mm/damon/core: disallow non-power of two min_region_sz") made min_region_sz to always be a power of two. Hence, addr_unit should be a power of two when it is smaller than PAGE_SIZE. While 'addr_unit' is a user-exposed parameter, the rule is not documented. This can confuse users. Specifically, if the user sets addr_unit as a value that is smaller than PAGE_SIZE and not a power of two, the setup will explicitly fail.

Document the rule on the design document. Usage documents reference the design document for detail, so updating only the design document should suffice.

Cc Brendan Higgins <[email protected]>
Cc David Gow <[email protected]>
Cc David Hildenbrand <[email protected]>
Cc Jonathan Corbet <[email protected]>
Cc Liam Howlett <[email protected]>
Cc Lorenzo Stoakes (Oracle) <[email protected]>
Cc Michal Hocko <[email protected]>
Cc Mike Rapoport <[email protected]>
Cc Suren Baghdasaryan <[email protected]>

---

 Documentation/mm/damon/design.rst |    2 ++
 1 file changed, 2 insertions(+)
Documentation/mm/damon/design.rst renamed from Documentation/mm/damon/design.rst~docs-mm-damon-design-document-the-power-of-two-limitation-for-addr_unit +2 -0
@@ -150,6 +150,8 @@ address on the given address space.  Sup
 up to each operations set implementation.  ``paddr`` is the only operations set
 implementation that supports the parameter.
 
+If the value is smaller than ``PAGE_SIZE``, only a power of two should be used.
+
 .. _damon_core_logic:
 
 Core Logics

_

Patches currently in -mm which might be from [email protected] are

mm-damon-sysfs-dealloc-repeat_call_control-if-damon_call-fails.patch