diff options
Diffstat (limited to 'include/asm-powerpc/pgtable-64k.h')
-rw-r--r-- | include/asm-powerpc/pgtable-64k.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/include/asm-powerpc/pgtable-64k.h b/include/asm-powerpc/pgtable-64k.h index 31cbd3d7fce8..bd54b772fbc6 100644 --- a/include/asm-powerpc/pgtable-64k.h +++ b/include/asm-powerpc/pgtable-64k.h | |||
@@ -9,9 +9,11 @@ | |||
9 | #define PUD_INDEX_SIZE 0 | 9 | #define PUD_INDEX_SIZE 0 |
10 | #define PGD_INDEX_SIZE 4 | 10 | #define PGD_INDEX_SIZE 4 |
11 | 11 | ||
12 | #ifndef __ASSEMBLY__ | ||
12 | #define PTE_TABLE_SIZE (sizeof(real_pte_t) << PTE_INDEX_SIZE) | 13 | #define PTE_TABLE_SIZE (sizeof(real_pte_t) << PTE_INDEX_SIZE) |
13 | #define PMD_TABLE_SIZE (sizeof(pmd_t) << PMD_INDEX_SIZE) | 14 | #define PMD_TABLE_SIZE (sizeof(pmd_t) << PMD_INDEX_SIZE) |
14 | #define PGD_TABLE_SIZE (sizeof(pgd_t) << PGD_INDEX_SIZE) | 15 | #define PGD_TABLE_SIZE (sizeof(pgd_t) << PGD_INDEX_SIZE) |
16 | #endif /* __ASSEMBLY__ */ | ||
15 | 17 | ||
16 | #define PTRS_PER_PTE (1 << PTE_INDEX_SIZE) | 18 | #define PTRS_PER_PTE (1 << PTE_INDEX_SIZE) |
17 | #define PTRS_PER_PMD (1 << PMD_INDEX_SIZE) | 19 | #define PTRS_PER_PMD (1 << PMD_INDEX_SIZE) |
@@ -49,12 +51,10 @@ | |||
49 | 51 | ||
50 | /* Shift to put page number into pte. | 52 | /* Shift to put page number into pte. |
51 | * | 53 | * |
52 | * That gives us a max RPN of 32 bits, which means a max of 48 bits | 54 | * That gives us a max RPN of 34 bits, which means a max of 50 bits |
53 | * of addressable physical space. | 55 | * of addressable physical space, or 46 bits for the special 4k PFNs. |
54 | * We could get 3 more bits here by setting PTE_RPN_SHIFT to 29 but | ||
55 | * 32 makes PTEs more readable for debugging for now :) | ||
56 | */ | 56 | */ |
57 | #define PTE_RPN_SHIFT (32) | 57 | #define PTE_RPN_SHIFT (30) |
58 | #define PTE_RPN_MAX (1UL << (64 - PTE_RPN_SHIFT)) | 58 | #define PTE_RPN_MAX (1UL << (64 - PTE_RPN_SHIFT)) |
59 | #define PTE_RPN_MASK (~((1UL<<PTE_RPN_SHIFT)-1)) | 59 | #define PTE_RPN_MASK (~((1UL<<PTE_RPN_SHIFT)-1)) |
60 | 60 | ||