H. Peter Anvin | 1965aae | 2008-10-22 22:26:29 -0700 | [diff] [blame] | 1 | #ifndef _ASM_X86_PGTABLE_3LEVEL_DEFS_H |
| 2 | #define _ASM_X86_PGTABLE_3LEVEL_DEFS_H |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 3 | |
Jeremy Fitzhardinge | 5311ab6 | 2007-05-02 19:27:13 +0200 | [diff] [blame] | 4 | #ifdef CONFIG_PARAVIRT |
Jeremy Fitzhardinge | 93b1eab | 2007-10-16 11:51:29 -0700 | [diff] [blame] | 5 | #define SHARED_KERNEL_PMD (pv_info.shared_kernel_pmd) |
Jeremy Fitzhardinge | 5311ab6 | 2007-05-02 19:27:13 +0200 | [diff] [blame] | 6 | #else |
| 7 | #define SHARED_KERNEL_PMD 1 |
| 8 | #endif |
| 9 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 10 | /* |
| 11 | * PGDIR_SHIFT determines what a top-level page table entry can map |
| 12 | */ |
| 13 | #define PGDIR_SHIFT 30 |
| 14 | #define PTRS_PER_PGD 4 |
| 15 | |
| 16 | /* |
| 17 | * PMD_SHIFT determines the size of the area a middle-level |
| 18 | * page table can map |
| 19 | */ |
| 20 | #define PMD_SHIFT 21 |
| 21 | #define PTRS_PER_PMD 512 |
| 22 | |
| 23 | /* |
| 24 | * entries per page directory level |
| 25 | */ |
| 26 | #define PTRS_PER_PTE 512 |
| 27 | |
H. Peter Anvin | 1965aae | 2008-10-22 22:26:29 -0700 | [diff] [blame] | 28 | #endif /* _ASM_X86_PGTABLE_3LEVEL_DEFS_H */ |