* [to-be-updated] xen-grant-table-stop-setting-pg_private-on-pages-for-grant-mapping.patch removed from -mm tree
@ 2026-09-21 3:31 Andrew Morton
0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2026-09-21 3:31 UTC (permalink / raw)
To: mm-commits, ziy, akpm
The quilt patch titled
Subject: xen/grant-table: stop setting PG_private on pages for grant mapping
has been removed from the -mm tree. Its filename was
xen-grant-table-stop-setting-pg_private-on-pages-for-grant-mapping.patch
This patch was dropped because an updated version will be issued
------------------------------------------------------
From: Zi Yan <ziy@nvidia.com>
Subject: xen/grant-table: stop setting PG_private on pages for grant mapping
Date: Sun, 13 Sep 2026 22:24:01 -0400
gnttab_alloc_pages() stores xen_page_foreign in page->private. On 32-bit,
a pointer to an allocated xen_page_foreign is stored; on 64-bit,
xen_page_foreign is stored inline. Checking page->private != NULL is
enough to tell whether a xen_page_foreign needs to be freed on 32-bit and
page->private is zeroed unconditionally on 64-bit.
It prepares for a future commit that remove PG_private.
No functional change intended.
Assisted-by: LLM
Link: https://lore.kernel.org/20260913-remove-pg_private-v4-3-848550f7574e@nvidia.com
Signed-off-by: Zi Yan <ziy@nvidia.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Reviewed-by: David Hildenbrand (Arm) <david@kernel.org>
Cc: Juergen Gross <jgross@suse.com>
Cc: Stefano Stabellini <sstabellini@kernel.org>
Cc: Oleksandr Tyshchenko <oleksandr_tyshchenko@epam.com>
---
drivers/xen/grant-table.c | 11 +++++------
1 file changed, 5 insertions(+), 6 deletions(-)
--- a/drivers/xen/grant-table.c~xen-grant-table-stop-setting-pg_private-on-pages-for-grant-mapping
+++ a/drivers/xen/grant-table.c
@@ -863,10 +863,10 @@ EXPORT_SYMBOL_GPL(gnttab_free_auto_xlat_
int gnttab_pages_set_private(int nr_pages, struct page **pages)
{
+#if BITS_PER_LONG < 64
int i;
for (i = 0; i < nr_pages; i++) {
-#if BITS_PER_LONG < 64
struct xen_page_foreign *foreign;
foreign = kzalloc_obj(*foreign);
@@ -874,9 +874,9 @@ int gnttab_pages_set_private(int nr_page
return -ENOMEM;
set_page_private(pages[i], (unsigned long)foreign);
-#endif
- SetPagePrivate(pages[i]);
}
+#endif
+ /* Data is stored in page->private on 64-bit */
return 0;
}
@@ -1031,12 +1031,11 @@ void gnttab_pages_clear_private(int nr_p
int i;
for (i = 0; i < nr_pages; i++) {
- if (PagePrivate(pages[i])) {
#if BITS_PER_LONG < 64
+ if (page_private(pages[i]))
kfree((void *)page_private(pages[i]));
#endif
- ClearPagePrivate(pages[i]);
- }
+ set_page_private(pages[i], 0);
}
}
EXPORT_SYMBOL_GPL(gnttab_pages_clear_private);
_
Patches currently in -mm which might be from ziy@nvidia.com are
fscrypt-stop-setting-pg_private-on-bounce-page.patch
mm-hugetlb-use-direct-assignment-instead-of-folio_change_private.patch
f2fs-stop-using-pg_private.patch
f2fs-convert-the-private-flag-helpers-to-folio-only.patch
erofs-mm-pagemap-add-readahead_folio_last-to-avoid-folio-private.patch
erofs-use-folio_attach-detach_private-instead-of-direct-assignment.patch
mm-page-flags-check-page-folio-private-instead-of-pg_private.patch
treewide-remove-folio_set-clear_private-usage.patch
ceph-replace-pageprivate-with-page_private.patch
md-md-bitmap-replace-pageprivate-with-page_private.patch
buffer-replace-page_buffer-with-page_private-and-delete-it.patch
treewide-remove-pageprivate-and-pg_private-from-comments-and-docs.patch
mm-page-flags-remove-pg_private.patch
usb-gadgetfs-do-not-warn-about-excessively-large-memory-allocations.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-09-21 3:31 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-21 3:31 [to-be-updated] xen-grant-table-stop-setting-pg_private-on-pages-for-grant-mapping.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.