[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZNqHdIi8ySqwoswd@casper.infradead.org>
Date: Mon, 14 Aug 2023 20:58:44 +0100
From: Matthew Wilcox <willy@...radead.org>
To: Peter Xu <peterx@...hat.com>
Cc: linux-mm@...ck.org, linux-kernel@...r.kernel.org,
Mike Kravetz <mike.kravetz@...cle.com>,
David Hildenbrand <david@...hat.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Yu Zhao <yuzhao@...gle.com>,
Ryan Roberts <ryan.roberts@....com>,
Yang Shi <shy828301@...il.com>,
Hugh Dickins <hughd@...gle.com>,
"Kirill A . Shutemov" <kirill@...temov.name>
Subject: Re: [PATCH RFC v2 0/3] mm: Properly document tail pages for a folio
On Mon, Aug 14, 2023 at 02:44:08PM -0400, Peter Xu wrote:
Look, this is all still too complicated. And you're trying to make
something better that I'm trying to make disappear. I'd really rather
you spent your time worrying about making userfaultfd use folios
than faffing with this.
How about this?
diff --git a/include/linux/mm_types.h b/include/linux/mm_types.h
index 5e74ce4a28cd..873285bb5d45 100644
--- a/include/linux/mm_types.h
+++ b/include/linux/mm_types.h
@@ -334,11 +334,14 @@ struct folio {
/* public: */
unsigned char _folio_dtor;
unsigned char _folio_order;
+ /* two bytes available here */
atomic_t _entire_mapcount;
atomic_t _nr_pages_mapped;
atomic_t _pincount;
+ /* no more space on 32-bt */
#ifdef CONFIG_64BIT
unsigned int _folio_nr_pages;
+ /* twelve bytes available on 64-bit */
#endif
/* private: the union with struct page is transitional */
};
@@ -360,6 +363,7 @@ struct folio {
unsigned long _head_2a;
/* public: */
struct list_head _deferred_list;
+ /* three more words available here */
/* private: the union with struct page is transitional */
};
struct page __page_2;
Powered by blists - more mailing lists