hc
2023-12-11 6778948f9de86c3cfaf36725a7c87dcff9ba247f
kernel/arch/um/include/asm/pgtable-3level.h
....@@ -1,13 +1,12 @@
1
+/* SPDX-License-Identifier: GPL-2.0 */
12 /*
23 * Copyright 2003 PathScale Inc
34 * Derived from include/asm-i386/pgtable.h
4
- * Licensed under the GPL
55 */
66
77 #ifndef __UM_PGTABLE_3LEVEL_H
88 #define __UM_PGTABLE_3LEVEL_H
99
10
-#define __ARCH_USE_5LEVEL_HACK
1110 #include <asm-generic/pgtable-nopud.h>
1211
1312 /* PGDIR_SHIFT determines what a third-level page table entry can map */
....@@ -79,9 +78,6 @@
7978 #define set_pmd(pmdptr, pmdval) (*(pmdptr) = (pmdval))
8079 #endif
8180
82
-struct mm_struct;
83
-extern pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long address);
84
-
8581 static inline void pud_clear (pud_t *pud)
8682 {
8783 set_pud(pud, __pud(_PAGE_NEWPAGE));
....@@ -89,10 +85,6 @@
8985
9086 #define pud_page(pud) phys_to_page(pud_val(pud) & PAGE_MASK)
9187 #define pud_page_vaddr(pud) ((unsigned long) __va(pud_val(pud) & PAGE_MASK))
92
-
93
-/* Find an entry in the second-level page table.. */
94
-#define pmd_offset(pud, address) ((pmd_t *) pud_page_vaddr(*(pud)) + \
95
- pmd_index(address))
9688
9789 static inline unsigned long pte_pfn(pte_t pte)
9890 {