* [merged mm-stable] mm-page_alloc-remove-unnecessary-parameter-batch-of-nr_pcp_free.patch removed from -mm tree
@ 2023-08-21 20:40 Andrew Morton
0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2023-08-21 20:40 UTC (permalink / raw)
To: mm-commits, willy, mgorman, david, baolin.wang, shikemeng, akpm
The quilt patch titled
Subject: mm/page_alloc: remove unnecessary parameter batch of nr_pcp_free
has been removed from the -mm tree. Its filename was
mm-page_alloc-remove-unnecessary-parameter-batch-of-nr_pcp_free.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: Kemeng Shi <shikemeng@huaweicloud.com>
Subject: mm/page_alloc: remove unnecessary parameter batch of nr_pcp_free
Date: Wed, 9 Aug 2023 18:07:54 +0800
We get batch from pcp and just pass it to nr_pcp_free immediately. Get
batch from pcp inside nr_pcp_free to remove unnecessary parameter batch.
Link: https://lkml.kernel.org/r/20230809100754.3094517-3-shikemeng@huaweicloud.com
Signed-off-by: Kemeng Shi <shikemeng@huaweicloud.com>
Cc: Baolin Wang <baolin.wang@linux.alibaba.com>
Cc: David Hildenbrand <david@redhat.com>
Cc: Matthew Wilcox <willy@infradead.org>
Cc: Mel Gorman <mgorman@techsingularity.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
mm/page_alloc.c | 8 +++-----
1 file changed, 3 insertions(+), 5 deletions(-)
--- a/mm/page_alloc.c~mm-page_alloc-remove-unnecessary-parameter-batch-of-nr_pcp_free
+++ a/mm/page_alloc.c
@@ -2340,10 +2340,10 @@ static bool free_unref_page_prepare(stru
return true;
}
-static int nr_pcp_free(struct per_cpu_pages *pcp, int high, int batch,
- bool free_high)
+static int nr_pcp_free(struct per_cpu_pages *pcp, int high, bool free_high)
{
int min_nr_free, max_nr_free;
+ int batch = READ_ONCE(pcp->batch);
/* Free everything if batch freeing high-order pages. */
if (unlikely(free_high))
@@ -2410,9 +2410,7 @@ static void free_unref_page_commit(struc
high = nr_pcp_high(pcp, zone, free_high);
if (pcp->count >= high) {
- int batch = READ_ONCE(pcp->batch);
-
- free_pcppages_bulk(zone, nr_pcp_free(pcp, high, batch, free_high), pcp, pindex);
+ free_pcppages_bulk(zone, nr_pcp_free(pcp, high, free_high), pcp, pindex);
}
}
_
Patches currently in -mm which might be from shikemeng@huaweicloud.com are
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2023-08-21 20:42 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-21 20:40 [merged mm-stable] mm-page_alloc-remove-unnecessary-parameter-batch-of-nr_pcp_free.patch removed from -mm tree Andrew Morton
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.