Skip to contentSkip to conversation

mm-add-folio_get_nontail_page.patch removed from -mm tree

merged mm-stable Andrew Morton 1 participant 1 message Feb 13, 2023

lore
Share & tools
lore

Andrew Morton

author tree notice Applied
#0 lore raw

The quilt patch titled
Subject: mm: add folio_get_nontail_page()
has been removed from the -mm tree. Its filename was
mm-add-folio_get_nontail_page.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: "Vishal Moola (Oracle)" <[email protected]>
Subject: mm: add folio_get_nontail_page()
Date: Mon, 30 Jan 2023 13:43:49 -0800

Patch series "Convert a couple migrate functions to use folios", v2.

This patchset introduces folio_movable_ops() and converts 3 functions in mm/migrate.c to use folios. It also introduces folio_get_nontail_page() for folio conversions which may want to distinguish between head and tail pages.

This patch (of 4):

folio_get_nontail_page() returns the folio associated with a head page. This is necessary for folio conversions where the behavior of that function differs between head pages and tail pages.

---

include/linux/mm.h renamed from include/linux/mm.h~mm-add-folio_get_nontail_page +7 -0
@@ -892,6 +892,13 @@ static inline bool get_page_unless_zero(
 	return page_ref_add_unless(page, 1, 0);
 }
 
+static inline struct folio *folio_get_nontail_page(struct page *page)
+{
+	if (unlikely(!get_page_unless_zero(page)))
+		return NULL;
+	return (struct folio *)page;
+}
+
 extern int page_is_ram(unsigned long pfn);
 
 enum {

_

Patches currently in -mm which might be from [email protected] are