From: Yajun Deng <yajun.deng@linux.dev>
To: akpm@linux-foundation.org, hannes@cmpxchg.org, vbabka@suse.cz
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
Yajun Deng <yajun.deng@linux.dev>
Subject: [PATCH] mm: page_alloc: fix the incorrect parameter
Date: Tue, 14 May 2024 14:59:33 +0800 [thread overview]
Message-ID: <20240514065933.1523170-1-yajun.deng@linux.dev> (raw)
The first parameter passed to set_pageblock_migratetype should be the
buddy, not the page. Let's change it back correctly.
Fixes: fd919a85cd55 ("mm: page_isolation: prepare for hygienic freelists")
Signed-off-by: Yajun Deng <yajun.deng@linux.dev>
---
mm/page_alloc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/mm/page_alloc.c b/mm/page_alloc.c
index cd584aace6bf..5422f6f8975d 100644
--- a/mm/page_alloc.c
+++ b/mm/page_alloc.c
@@ -1728,7 +1728,7 @@ bool move_freepages_block_isolate(struct zone *zone, struct page *page,
del_page_from_free_list(buddy, zone, order,
get_pfnblock_migratetype(buddy, pfn));
- set_pageblock_migratetype(page, migratetype);
+ set_pageblock_migratetype(buddy, migratetype);
split_large_buddy(zone, buddy, pfn, order);
return true;
}
--
2.25.1
next reply other threads:[~2024-05-14 7:00 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-14 6:59 Yajun Deng [this message]
2024-05-14 12:40 ` [PATCH] mm: page_alloc: fix the incorrect parameter Johannes Weiner
2024-05-15 1:50 ` Yajun Deng
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240514065933.1523170-1-yajun.deng@linux.dev \
--to=yajun.deng@linux.dev \
--cc=akpm@linux-foundation.org \
--cc=hannes@cmpxchg.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=vbabka@suse.cz \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).