Skip to content

Commit 4b8e032

Browse files
author
Ingo Molnar
committed
x86/mm: Remove the unused mk_kernel_pgd() #define
AFAICS the last uses of directly 'making' kernel PGDs was removed 7 years ago: 8b78c21: ("x86, 64bit, mm: hibernate use generic mapping_init") Where the explicit PGD walking loop was replaced with kernel_ident_mapping_init() calls. This was then (unnecessarily) carried over through the 5-level paging conversion. Also clean up the 'level' comments a bit, to convey the original, meanwhile somewhat bit-rotten notion, that these are empty comment blocks with no methods to handle any of the levels except the PTE level. Signed-off-by: Ingo Molnar <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent 161449b commit 4b8e032

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

arch/x86/include/asm/pgtable_64.h

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -175,16 +175,13 @@ extern void sync_global_pgds(unsigned long start, unsigned long end);
175175
* and a page entry and page directory to the page they refer to.
176176
*/
177177

178-
/*
179-
* Level 4 access.
180-
*/
181-
#define mk_kernel_pgd(address) __pgd((address) | _KERNPG_TABLE)
178+
/* PGD - Level 4 access */
182179

183-
/* PUD - Level3 access */
180+
/* PUD - Level 3 access */
184181

185-
/* PMD - Level 2 access */
182+
/* PMD - Level 2 access */
186183

187-
/* PTE - Level 1 access. */
184+
/* PTE - Level 1 access */
188185

189186
/*
190187
* Encode and de-code a swap entry

0 commit comments

Comments
 (0)