]>
Commit | Line | Data |
---|---|---|
1965aae3 PA |
1 | #ifndef _ASM_X86_PGTABLE_3LEVEL_DEFS_H |
2 | #define _ASM_X86_PGTABLE_3LEVEL_DEFS_H | |
1da177e4 | 3 | |
54321d94 JF |
4 | #ifndef __ASSEMBLY__ |
5 | #include <linux/types.h> | |
6 | ||
7 | typedef u64 pteval_t; | |
8 | typedef u64 pmdval_t; | |
9 | typedef u64 pudval_t; | |
fe1e8c3e | 10 | typedef u64 p4dval_t; |
54321d94 JF |
11 | typedef u64 pgdval_t; |
12 | typedef u64 pgprotval_t; | |
13 | ||
14 | typedef union { | |
15 | struct { | |
16 | unsigned long pte_low, pte_high; | |
17 | }; | |
18 | pteval_t pte; | |
19 | } pte_t; | |
20 | #endif /* !__ASSEMBLY__ */ | |
21 | ||
5311ab62 | 22 | #ifdef CONFIG_PARAVIRT |
93b1eab3 | 23 | #define SHARED_KERNEL_PMD (pv_info.shared_kernel_pmd) |
5311ab62 JF |
24 | #else |
25 | #define SHARED_KERNEL_PMD 1 | |
26 | #endif | |
27 | ||
1da177e4 LT |
28 | /* |
29 | * PGDIR_SHIFT determines what a top-level page table entry can map | |
30 | */ | |
31 | #define PGDIR_SHIFT 30 | |
32 | #define PTRS_PER_PGD 4 | |
33 | ||
34 | /* | |
35 | * PMD_SHIFT determines the size of the area a middle-level | |
36 | * page table can map | |
37 | */ | |
38 | #define PMD_SHIFT 21 | |
39 | #define PTRS_PER_PMD 512 | |
40 | ||
41 | /* | |
42 | * entries per page directory level | |
43 | */ | |
44 | #define PTRS_PER_PTE 512 | |
45 | ||
54321d94 | 46 | |
1965aae3 | 47 | #endif /* _ASM_X86_PGTABLE_3LEVEL_DEFS_H */ |