[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20260115144604.822702-2-kas@kernel.org>
Date: Thu, 15 Jan 2026 14:45:47 +0000
From: Kiryl Shutsemau <kas@...nel.org>
To: Andrew Morton <akpm@...ux-foundation.org>,
Muchun Song <muchun.song@...ux.dev>,
David Hildenbrand <david@...nel.org>,
Matthew Wilcox <willy@...radead.org>,
Usama Arif <usamaarif642@...il.com>,
Frank van der Linden <fvdl@...gle.com>
Cc: Oscar Salvador <osalvador@...e.de>,
Mike Rapoport <rppt@...nel.org>,
Vlastimil Babka <vbabka@...e.cz>,
Lorenzo Stoakes <lorenzo.stoakes@...cle.com>,
Zi Yan <ziy@...dia.com>,
Baoquan He <bhe@...hat.com>,
Michal Hocko <mhocko@...e.com>,
Johannes Weiner <hannes@...xchg.org>,
Jonathan Corbet <corbet@....net>,
kernel-team@...a.com,
linux-mm@...ck.org,
linux-kernel@...r.kernel.org,
linux-doc@...r.kernel.org,
Kiryl Shutsemau <kas@...nel.org>,
x86@...nel.org
Subject: [PATCHv3 01/15] x86/vdso32: Prepare for <linux/pgtable.h> inclusion
The 32-bit vDSO for 64-bit kernels is built by faking a 32-bit environment
through various #undefs and #defines in fake_32bit_build.h.
Upcoming change will include <linux/pgtable.h> in <linux/mmzone.h>.
Without preparation, it breaks build of 32-bit vDSO because of exposure
to more 64-bit things.
CONFIG_PHYS_ADDR_T_64BIT triggers "Missing MAX_POSSIBLE_PHYSMEM_BITS
definition" error in <linux/pgtable.h>.
And CONFIG_X86_INTEL_MEMORY_PROTECTION_KEYS leads to "shift count >=
width of type" errors in pte_flags_pkey().
Undefine CONFIG_PHYS_ADDR_T_64BIT and CONFIG_X86_INTEL_MEMORY_PROTECTION_KEYS
in fake_32bit_build.h to fix the problem.
Signed-off-by: Kiryl Shutsemau <kas@...nel.org>
Cc: x86@...nel.org
---
arch/x86/entry/vdso/vdso32/fake_32bit_build.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/arch/x86/entry/vdso/vdso32/fake_32bit_build.h b/arch/x86/entry/vdso/vdso32/fake_32bit_build.h
index db1b15f686e3..900cdcde1029 100644
--- a/arch/x86/entry/vdso/vdso32/fake_32bit_build.h
+++ b/arch/x86/entry/vdso/vdso32/fake_32bit_build.h
@@ -13,6 +13,8 @@
#undef CONFIG_SPARSEMEM_VMEMMAP
#undef CONFIG_NR_CPUS
#undef CONFIG_PARAVIRT_XXL
+#undef CONFIG_PHYS_ADDR_T_64BIT
+#undef CONFIG_X86_INTEL_MEMORY_PROTECTION_KEYS
#define CONFIG_X86_32 1
#define CONFIG_PGTABLE_LEVELS 2
--
2.51.2
Powered by blists - more mailing lists