mm-page_alloc-remove-ifdefs-from-pindex-helpers.patch removed from -mm tree
The quilt patch titled
Subject: mm/page_alloc: remove ifdefs from pindex helpers
has been removed from the -mm tree. Its filename was
mm-page_alloc-remove-ifdefs-from-pindex-helpers.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: Brendan Jackman <[email protected]>
Subject: mm/page_alloc: remove ifdefs from pindex helpers
Date: Wed, 13 May 2026 12:35:16 +0000
The ifdefs are not technically needed here, everything used here is always defined.
Switching to IS_ENABLED() makes the code a bit less tiresome to read.
---
mm/page_alloc.c | 30 ++++++++++++++---------------- 1 file changed, 14 insertions(+), 16 deletions(-)
mm/page_alloc.c renamed from mm/page_alloc.c~mm-page_alloc-remove-ifdefs-from-pindex-helpers +14 -16
@@ -650,19 +650,17 @@ out:static inline unsigned int order_to_pindex (int migratetype,int order) { +if (IS_ENABLED (CONFIG_TRANSPARENT_HUGEPAGE )) { +bool movable = migratetype ==MIGRATE_MOVABLE ; -#ifdef CONFIG_TRANSPARENT_HUGEPAGE -bool movable; -if (order >PAGE_ALLOC_COSTLY_ORDER ) { -VM_BUG_ON (!is_pmd_order (order)); +if (order >PAGE_ALLOC_COSTLY_ORDER ) { +VM_BUG_ON (!is_pmd_order (order)); - movable = migratetype ==MIGRATE_MOVABLE ; - -return NR_LOWORDER_PCP_LISTS + movable; +return NR_LOWORDER_PCP_LISTS + movable; + } + }else { +VM_BUG_ON (order >PAGE_ALLOC_COSTLY_ORDER ); } -#else -VM_BUG_ON (order >PAGE_ALLOC_COSTLY_ORDER ); -#endif return (MIGRATE_PCPTYPES * order) + migratetype; }
@@ -671,12 +669,12 @@ static inline int pindex_to_order(unsign {int order = pindex /MIGRATE_PCPTYPES ; -#ifdef CONFIG_TRANSPARENT_HUGEPAGE -if (pindex >=NR_LOWORDER_PCP_LISTS ) - order =HPAGE_PMD_ORDER ; -#else -VM_BUG_ON (order >PAGE_ALLOC_COSTLY_ORDER ); -#endif +if (IS_ENABLED (CONFIG_TRANSPARENT_HUGEPAGE )) { +if (pindex >=NR_LOWORDER_PCP_LISTS ) + order =HPAGE_PMD_ORDER ; + }else { +VM_BUG_ON (order >PAGE_ALLOC_COSTLY_ORDER ); + }return order; }
_
Patches currently in -mm which might be from [email protected] are
mm-delete-stale-comment-about-cachelines.patch