Re: [PATCH] mm: add more readable thp_vma_allowable_order_foo()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





On 2024/4/24 22:58, David Hildenbrand wrote:
On 24.04.24 16:05, Ryan Roberts wrote:
On 24/04/2024 15:07, Kefeng Wang wrote:
There are too many bool arguments in thp_vma_allowable_orders(), adding
some more readable thp_vma_allowable_order_foo(),

   thp_vma_allowable_orders_insmaps() is used in samps
   thp_vma_allowable_order[s]_inpf()  is used in page fault
   thp_vma_allowable_pmd_order_inhuge is used in khugepaged scan and madvise

Signed-off-by: Kefeng Wang <wangkefeng.wang@xxxxxxxxxx>

Just one nit below. With that addressed:

Reviewed-by: Ryan Roberts <ryan.roberts@xxxxxxx>


...

nit: Personally I'd leave the order as an argument rather than encoding it in
the name. It's likely that khugepaged will grow support for non-PMD-size

Agreed.

collapse in future. The first part of the name "thp_vma_allowable_order" is then consistent and easy to search for all variants. And perhaps "inkhuge" is more
precise?

"_khugepaged" or something else that people can actually parse and understand.


Try this before, _inkhugepaged is a bit long, so choose inkhuge, but I can't find a better name, as you and Ryan suggested,

thp_vma_allowable_orders_smaps()
thp_vma_allowable_order[s]_pf()
thp_vma_allowable_order_khugepaged()

Thanks.




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux