People have been abusing the existence of __folio_index. Since that was too subtle for them, use a bigger hammer to make it unusable. That also makes it unusable for the FOLIO_MATCH, TABLE_MATCH and ZPDESC_MATCH macros, but that's OK, since we don't care what fields these fields alias. Signed-off-by: Matthew Wilcox (Oracle) --- include/linux/mm_types.h | 9 +++------ mm/zpdesc.h | 2 -- 2 files changed, 3 insertions(+), 8 deletions(-) diff --git a/include/linux/mm_types.h b/include/linux/mm_types.h index a308e2c23b82..8f8687bb80d9 100644 --- a/include/linux/mm_types.h +++ b/include/linux/mm_types.h @@ -101,10 +101,9 @@ struct page { struct llist_node pcp_llist; }; struct address_space *mapping; - union { - pgoff_t __folio_index; /* Our offset within mapping. */ - unsigned long share; /* share count for fsdax */ - }; +#define DO_NOT_USE(x) x ## __LINE__ + unsigned long DO_NOT_USE(_pad); +#undef DO_NOT_USE /** * @private: Mapping-private opaque data. * Usually used for buffer_heads if PagePrivate. @@ -511,7 +510,6 @@ FOLIO_MATCH(flags, flags); FOLIO_MATCH(lru, lru); FOLIO_MATCH(mapping, mapping); FOLIO_MATCH(compound_info, lru); -FOLIO_MATCH(__folio_index, index); FOLIO_MATCH(private, private); FOLIO_MATCH(_mapcount, _mapcount); FOLIO_MATCH(_refcount, _refcount); @@ -612,7 +610,6 @@ TABLE_MATCH(flags, pt_flags); TABLE_MATCH(compound_info, pt_list); TABLE_MATCH(compound_info, _pt_pad_1); TABLE_MATCH(mapping, __page_mapping); -TABLE_MATCH(__folio_index, pt_index); TABLE_MATCH(rcu_head, pt_rcu_head); TABLE_MATCH(page_type, __page_type); TABLE_MATCH(_refcount, __page_refcount); diff --git a/mm/zpdesc.h b/mm/zpdesc.h index b8258dc78548..194392afd3a7 100644 --- a/mm/zpdesc.h +++ b/mm/zpdesc.h @@ -54,8 +54,6 @@ struct zpdesc { ZPDESC_MATCH(flags, flags); ZPDESC_MATCH(lru, lru); ZPDESC_MATCH(mapping, movable_ops); -ZPDESC_MATCH(__folio_index, next); -ZPDESC_MATCH(__folio_index, handle); ZPDESC_MATCH(private, zspage); ZPDESC_MATCH(page_type, first_obj_offset); ZPDESC_MATCH(_refcount, _refcount); -- 2.47.3