Re: [PATCH] mm/huge_memory.c: introduce folio_split_unmapped

From: David Hildenbrand (Red Hat)

Date: Tue Nov 18 2025 - 15:18:31 EST


On 14.11.25 10:10, Balbir Singh wrote:
On 11/14/25 19:36, David Hildenbrand (Red Hat) wrote:
On 14.11.25 02:22, Balbir Singh wrote:
Unmapped was added as a parameter to __folio_split() and related
call sites to support splitting of folios already in the midst
of a migration. This special case arose for device private folio
migration since during migration there could be a disconnect between
source and destination on the folio size.

Didn't I already comment that the subject should start with "mm/huge_memory: introduce ..." ?


Yeah.. the .c in the prefix is not desirable, I missed that in the subject line

Yes I did: https://lore.kernel.org/all/048134fd-6a3d-4a6c-a2eb-9a9911c3b35f@xxxxxxxxxx/

You know, I'm a busy man, can you *please*

* take better care of addressing all previous comments?
* wait more than 12 h after asking a question before you resend?


I think addressed most of it, I missed the subject line, but in general addressed

1. Using folio_split_ as the prefix to split functions, the main function is called folio_split_unmapped and the helper name was suggested by Zi to be __folio_freeze_and_split_unmapped() and it sounded better than what I had __folio_split_unmapped() or even __folio_split_freeze_unmapped()
2. Got rid of _to_order() as the function suffix

Do you have any more outstanding comments that I missed?

I'll take a look at v2 now given that I was distracted for 2 days :(

--
Cheers

David