The quilt patch titled Subject: include/linux/mmzone.h: clean up watermark accessors has been removed from the -mm tree. Its filename was include-linux-mmzoneh-clean-up-watermark-accessors.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: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> Subject: include/linux/mmzone.h: clean up watermark accessors Date: Thu Aug 1 04:50:05 PM PDT 2024 - we have a helper wmark_pages(). Teach min_wmark_pages(), low_wmark_pages(), high_wmark_pages() and promo_wmark_pages() to use it instead of open-coding its implementation. - there's no reason to implement all these things as macros. Redo them in C. Acked-by: Johannes Weiner <hannes@xxxxxxxxxxx> Cc: Kaiyang Zhao <kaiyang2@xxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- include/linux/mmzone.h | 32 ++++++++++++++++++++++++++------ 1 file changed, 26 insertions(+), 6 deletions(-) --- a/include/linux/mmzone.h~include-linux-mmzoneh-clean-up-watermark-accessors +++ a/include/linux/mmzone.h @@ -666,12 +666,6 @@ enum zone_watermarks { #define NR_LOWORDER_PCP_LISTS (MIGRATE_PCPTYPES * (PAGE_ALLOC_COSTLY_ORDER + 1)) #define NR_PCP_LISTS (NR_LOWORDER_PCP_LISTS + NR_PCP_THP) -#define min_wmark_pages(z) (z->_watermark[WMARK_MIN] + z->watermark_boost) -#define low_wmark_pages(z) (z->_watermark[WMARK_LOW] + z->watermark_boost) -#define high_wmark_pages(z) (z->_watermark[WMARK_HIGH] + z->watermark_boost) -#define promo_wmark_pages(z) (z->_watermark[WMARK_PROMO] + z->watermark_boost) -#define wmark_pages(z, i) (z->_watermark[i] + z->watermark_boost) - /* * Flags used in pcp->flags field. * @@ -1017,6 +1011,32 @@ enum zone_flags { ZONE_BELOW_HIGH, /* zone is below high watermark. */ }; +static inline unsigned long wmark_pages(const struct zone *z, + enum zone_watermarks w) +{ + return z->_watermark[w] + z->watermark_boost; +} + +static inline unsigned long min_wmark_pages(const struct zone *z) +{ + return wmark_pages(z, WMARK_MIN); +} + +static inline unsigned long low_wmark_pages(const struct zone *z) +{ + return wmark_pages(z, WMARK_LOW); +} + +static inline unsigned long high_wmark_pages(const struct zone *z) +{ + return wmark_pages(z, WMARK_HIGH); +} + +static inline unsigned long promo_wmark_pages(const struct zone *z) +{ + return wmark_pages(z, WMARK_PROMO); +} + static inline unsigned long zone_managed_pages(struct zone *zone) { return (unsigned long)atomic_long_read(&zone->managed_pages); _ Patches currently in -mm which might be from akpm@xxxxxxxxxxxxxxxxxxxx are mm-contig_alloc-support-__gfp_comp-fix.patch selftests-mm-add-more-mseal-traversal-tests-fix.patch selftests-mm-add-more-mseal-traversal-tests-fix-fix.patch mm-remove-pageactive-fix.patch selftests-test_zswap-add-test-for-hierarchical-zswapwriteback-fix.patch mm-count-the-number-of-anonymous-thps-per-size-fix.patch mm-memory-failure-add-unmap_poisoned_folio-fix.patch mm-shmem-extend-shmem_unused_huge_shrink-to-all-sizes-fix.patch mm-hugetlb-sort-out-global-lock-annotations-fix.patch mm-hugetlb-sort-out-global-lock-annotations-fix-fix.patch lib-maple_treec-remove-unused-functions.patch fault-inject-improve-build-for-config_fault_injection=n-fix.patch fault-inject-improve-build-for-config_fault_injection=n-fix-2.patch fault-inject-improve-build-for-config_fault_injection=n-fix-3.patch