diff options
author | Linus Torvalds <torvalds@g5.osdl.org> | 2006-03-23 01:20:46 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-03-23 01:20:46 -0500 |
commit | 2e6e33bab6e1996a5dec9108fb467b52b841e7a8 (patch) | |
tree | 6b98b15c2fe7899cdeb2453589cdee00f7853492 /include/asm-powerpc/pgtable.h | |
parent | b7ad6d75028d021362221d9b2db19fcff995c3f8 (diff) | |
parent | b88a0b1d5560cf1959c1565617e460a45c688a08 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc
* git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc: (78 commits)
[PATCH] powerpc: Add FSL SEC node to documentation
[PATCH] macintosh: tidy-up driver_register() return values
[PATCH] powerpc: tidy-up of_register_driver()/driver_register() return values
[PATCH] powerpc: via-pmu warning fix
[PATCH] macintosh: cleanup the use of i2c headers
[PATCH] powerpc: dont allow old RTC to be selected
[PATCH] powerpc: make powerbook_sleep_grackle static
[PATCH] powerpc: Fix warning in add_memory
[PATCH] powerpc: update mailing list addresses
[PATCH] powerpc: Remove calculation of io hole
[PATCH] powerpc: iseries: Add bootargs to /chosen
[PATCH] powerpc: iseries: Add /system-id, /model and /compatible
[PATCH] powerpc: Add strne2a() to convert a string from EBCDIC to ASCII
[PATCH] powerpc: iseries: Make more stuff static in platforms/iseries/mf.c
[PATCH] powerpc: iseries: Remove pointless iSeries_(restart|power_off|halt)
[PATCH] powerpc: iseries: mf related cleanups
[PATCH] powerpc: Replace platform_is_lpar() with a firmware feature
[PATCH] powerpc: trivial: Cleanup whitespace in cputable.h
[PATCH] powerpc: Remove unused iommu_off logic from pSeries_init_early()
[PATCH] powerpc: Unconfuse htab_bolt_mapping() callers
...
Diffstat (limited to 'include/asm-powerpc/pgtable.h')
-rw-r--r-- | include/asm-powerpc/pgtable.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/include/asm-powerpc/pgtable.h b/include/asm-powerpc/pgtable.h index 185ee15963a1..e9f1f4627e6b 100644 --- a/include/asm-powerpc/pgtable.h +++ b/include/asm-powerpc/pgtable.h | |||
@@ -188,9 +188,13 @@ static inline pte_t pfn_pte(unsigned long pfn, pgprot_t pgprot) | |||
188 | #define pte_pfn(x) ((unsigned long)((pte_val(x)>>PTE_RPN_SHIFT))) | 188 | #define pte_pfn(x) ((unsigned long)((pte_val(x)>>PTE_RPN_SHIFT))) |
189 | #define pte_page(x) pfn_to_page(pte_pfn(x)) | 189 | #define pte_page(x) pfn_to_page(pte_pfn(x)) |
190 | 190 | ||
191 | #define PMD_BAD_BITS (PTE_TABLE_SIZE-1) | ||
192 | #define PUD_BAD_BITS (PMD_TABLE_SIZE-1) | ||
193 | |||
191 | #define pmd_set(pmdp, pmdval) (pmd_val(*(pmdp)) = (pmdval)) | 194 | #define pmd_set(pmdp, pmdval) (pmd_val(*(pmdp)) = (pmdval)) |
192 | #define pmd_none(pmd) (!pmd_val(pmd)) | 195 | #define pmd_none(pmd) (!pmd_val(pmd)) |
193 | #define pmd_bad(pmd) (pmd_val(pmd) == 0) | 196 | #define pmd_bad(pmd) (!is_kernel_addr(pmd_val(pmd)) \ |
197 | || (pmd_val(pmd) & PMD_BAD_BITS)) | ||
194 | #define pmd_present(pmd) (pmd_val(pmd) != 0) | 198 | #define pmd_present(pmd) (pmd_val(pmd) != 0) |
195 | #define pmd_clear(pmdp) (pmd_val(*(pmdp)) = 0) | 199 | #define pmd_clear(pmdp) (pmd_val(*(pmdp)) = 0) |
196 | #define pmd_page_kernel(pmd) (pmd_val(pmd) & ~PMD_MASKED_BITS) | 200 | #define pmd_page_kernel(pmd) (pmd_val(pmd) & ~PMD_MASKED_BITS) |
@@ -198,7 +202,8 @@ static inline pte_t pfn_pte(unsigned long pfn, pgprot_t pgprot) | |||
198 | 202 | ||
199 | #define pud_set(pudp, pudval) (pud_val(*(pudp)) = (pudval)) | 203 | #define pud_set(pudp, pudval) (pud_val(*(pudp)) = (pudval)) |
200 | #define pud_none(pud) (!pud_val(pud)) | 204 | #define pud_none(pud) (!pud_val(pud)) |
201 | #define pud_bad(pud) ((pud_val(pud)) == 0) | 205 | #define pud_bad(pud) (!is_kernel_addr(pud_val(pud)) \ |
206 | || (pud_val(pud) & PUD_BAD_BITS)) | ||
202 | #define pud_present(pud) (pud_val(pud) != 0) | 207 | #define pud_present(pud) (pud_val(pud) != 0) |
203 | #define pud_clear(pudp) (pud_val(*(pudp)) = 0) | 208 | #define pud_clear(pudp) (pud_val(*(pudp)) = 0) |
204 | #define pud_page(pud) (pud_val(pud) & ~PUD_MASKED_BITS) | 209 | #define pud_page(pud) (pud_val(pud) & ~PUD_MASKED_BITS) |