linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: "Vishal Moola (Oracle)" <vishal.moola@gmail.com>
To: akpm@linux-foundation.org
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
	"Vishal Moola (Oracle)" <vishal.moola@gmail.com>,
	Matthew Wilcox <willy@infradead.org>
Subject: [PATCH v2 1/5] mmzone: Introduce folio_is_zone_movable()
Date: Tue, 13 Jun 2023 19:13:08 -0700	[thread overview]
Message-ID: <20230614021312.34085-2-vishal.moola@gmail.com> (raw)
In-Reply-To: <20230614021312.34085-1-vishal.moola@gmail.com>

Introduce folio_is_zone_movable() to act as a folio equivalent for
is_zone_movable_page(). This is to assist in later folio conversions.

Signed-off-by: Vishal Moola (Oracle) <vishal.moola@gmail.com>
Reviewed-by: Matthew Wilcox (Oracle) <willy@infradead.org>
---
 include/linux/mmzone.h | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h
index a4889c9d4055..744bf32e48a8 100644
--- a/include/linux/mmzone.h
+++ b/include/linux/mmzone.h
@@ -1116,6 +1116,11 @@ static inline bool is_zone_movable_page(const struct page *page)
 {
 	return page_zonenum(page) == ZONE_MOVABLE;
 }
+
+static inline bool folio_is_zone_movable(const struct folio *folio)
+{
+	return folio_zonenum(folio) == ZONE_MOVABLE;
+}
 #endif
 
 /*
-- 
2.40.1



  reply	other threads:[~2023-06-14  2:14 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-14  2:13 [PATCH v2 0/5] Replace is_longterm_pinnable_page() Vishal Moola (Oracle)
2023-06-14  2:13 ` Vishal Moola (Oracle) [this message]
2023-06-14  2:13 ` [PATCH v2 2/5] mmzone: Introduce folio_migratetype() Vishal Moola (Oracle)
2023-06-14 20:13   ` Andrew Morton
2023-06-14 20:17     ` Matthew Wilcox
2023-06-14 20:33       ` Andrew Morton
2023-06-14  2:13 ` [PATCH v2 3/5] mm/gup_test.c: Convert verify_dma_pinned() to us folios Vishal Moola (Oracle)
2023-06-14  2:13 ` [PATCH v2 4/5] mm/gup.c: Reorganize try_get_folio() Vishal Moola (Oracle)
2023-06-14  2:13 ` [PATCH v2 5/5] mm: Remove is_longterm_pinnable_page() and Reimplement folio_is_longterm_pinnable() Vishal Moola (Oracle)
2023-06-17 20:50   ` Lorenzo Stoakes

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=20230614021312.34085-2-vishal.moola@gmail.com \
    --to=vishal.moola@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=willy@infradead.org \
    /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