Re: [PATCH] mm, thp: display [never] for defrag when THP is set to never

From: David Hildenbrand
Date: Thu Feb 22 2024 - 07:15:15 EST


On 22.02.24 12:53, Yuanhe Shu wrote:
When transparent_hugepage is set to never by cmdline or echo, defrag
still show what it used to be and can be modified which makes user
confusing whether defrag would take effect.

Actually if transparent_hugepage is set to never, defrag will not take
effect. Just Display never and remain unchangeable to for defrag when
transparent_hugepage is set to never.

Suggested-by: Liu Song <liusong@xxxxxxxxxxxxxxxxx>
Signed-off-by: Yuanhe Shu <xiangzao@xxxxxxxxxxxxxxxxx>
---

No, I don't think we want such a dependency between both options.

You might just end up breaking existing scripts (enable defrag before enabling THP) for no good reason.

--
Cheers,

David / dhildenb