Re: [PATCH] mm/migrate: rename PAGE_ migration flags to FOLIO_MF_

From: Matthew Wilcox

Date: Mon Mar 23 2026 - 12:25:26 EST


On Mon, Mar 23, 2026 at 02:19:37PM +0000, Shivank Garg wrote:
> +++ b/mm/migrate.c
> @@ -1135,26 +1135,26 @@ static int move_to_new_folio(struct folio *dst, struct folio *src,
> * This is safe because nobody is using it except us.
> */
> enum {
> - PAGE_WAS_MAPPED = BIT(0),
> - PAGE_WAS_MLOCKED = BIT(1),
> - PAGE_OLD_STATES = PAGE_WAS_MAPPED | PAGE_WAS_MLOCKED,
> + FOLIO_MF_WAS_MAPPED = BIT(0),
> + FOLIO_MF_WAS_MLOCKED = BIT(1),
> + FOLIO_MF_OLD_STATES = FOLIO_MF_WAS_MAPPED | FOLIO_MF_WAS_MLOCKED,

what does 'MF' stand for? i mean, presumably not the pop culture
meaning of MF ...

> locked = true;
> if (folio_test_mlocked(src))
> - old_page_state |= PAGE_WAS_MLOCKED;
> + old_folio_state |= FOLIO_MF_WAS_MLOCKED;

I mean, this doesn't make sense any more. PAGE_WAS_MLOCKED is a
sentence that means something. FOLIO_MF_WAS_MLOCKED doesn't ... unless
you imagine Samuel L Jackson saying it ...