/arch/powerpc/include/asm/ |
H A D | pgalloc-32.h | 9 extern void __bad_pte(pmd_t *pmd); 15 * We don't have any real pmd's, and this code never triggers because 21 /* #define pgd_populate(mm, pmd, pte) BUG() */ 24 #define pmd_populate_kernel(mm, pmd, pte) \ 25 (pmd_val(*(pmd)) = __pa(pte) | _PMD_PRESENT) 26 #define pmd_populate(mm, pmd, pte) \ 27 (pmd_val(*(pmd)) = (page_to_pfn(pte) << PAGE_SHIFT) | _PMD_PRESENT) 28 #define pmd_pgtable(pmd) pmd_page(pmd) 30 #define pmd_populate_kernel(mm, pmd, pt [all...] |
H A D | pgalloc-64.h | 65 static inline void pud_populate(struct mm_struct *mm, pud_t *pud, pmd_t *pmd) argument 67 pud_set(pud, (unsigned long)pmd); 70 #define pmd_populate(mm, pmd, pte_page) \ 71 pmd_populate_kernel(mm, pmd, page_address(pte_page)) 72 #define pmd_populate_kernel(mm, pmd, pte) pmd_set(pmd, (unsigned long)(pte)) 73 #define pmd_pgtable(pmd) pmd_page(pmd) 78 #define pud_populate(mm, pud, pmd) pud_set(pud, (unsigned long)pmd) 80 pmd_populate_kernel(struct mm_struct *mm, pmd_t *pmd, pte_t *pte) argument 98 pmd_free(struct mm_struct *mm, pmd_t *pmd) argument 100 kmem_cache_free(PGT_CACHE(PMD_INDEX_SIZE), pmd); local [all...] |
/arch/parisc/include/asm/ |
H A D | pgalloc.h | 15 * allocate the first pmd adjacent to the pgd. This means that we can 16 * subtract a constant offset to get to it. The pmd and pgd sizes are 17 * arranged so that a single pmd covers 4GB (giving a full 64-bit 31 /* Populate first pmd with allocated memory. We mark it 33 * pmd entry may not be cleared. */ 38 /* The first pmd entry also is marked with _PAGE_GATEWAY as 39 * a signal that this pmd may not be freed */ 56 /* Three Level Page Table Support for pmd's */ 58 static inline void pgd_populate(struct mm_struct *mm, pgd_t *pgd, pmd_t *pmd) argument 61 (__u32)(__pa((unsigned long)pmd) >> PxD_VALUE_SHIF 66 pmd_t *pmd = (pmd_t *)__get_free_pages(GFP_KERNEL|__GFP_REPEAT, local 73 pmd_free(struct mm_struct *mm, pmd_t *pmd) argument 100 pmd_populate_kernel(struct mm_struct *mm, pmd_t *pmd, pte_t *pte) argument [all...] |
/arch/alpha/include/asm/ |
H A D | pgalloc.h | 14 pmd_populate(struct mm_struct *mm, pmd_t *pmd, pgtable_t pte) argument 16 pmd_set(pmd, (pte_t *)(page_to_pa(pte) + PAGE_OFFSET)); 18 #define pmd_pgtable(pmd) pmd_page(pmd) 21 pmd_populate_kernel(struct mm_struct *mm, pmd_t *pmd, pte_t *pte) argument 23 pmd_set(pmd, pte); 27 pgd_populate(struct mm_struct *mm, pgd_t *pgd, pmd_t *pmd) argument 29 pgd_set(pgd, pmd); 48 pmd_free(struct mm_struct *mm, pmd_t *pmd) argument 50 free_page((unsigned long)pmd); [all...] |
H A D | tlb.h | 13 #define __pmd_free_tlb(tlb, pmd, address) pmd_free((tlb)->mm, pmd)
|
/arch/mn10300/include/asm/ |
H A D | pgalloc.h | 22 #define pmd_populate_kernel(mm, pmd, pte) \ 23 set_pmd(pmd, __pmd(__pa(pte) | _PAGE_TABLE)) 26 void pmd_populate(struct mm_struct *mm, pmd_t *pmd, struct page *pte) argument 28 set_pmd(pmd, __pmd((page_to_pfn(pte) << PAGE_SHIFT) | _PAGE_TABLE)); 30 #define pmd_pgtable(pmd) pmd_page(pmd)
|
/arch/mips/include/asm/ |
H A D | pgalloc.h | 16 static inline void pmd_populate_kernel(struct mm_struct *mm, pmd_t *pmd, argument 19 set_pmd(pmd, __pmd((unsigned long)pte)); 22 static inline void pmd_populate(struct mm_struct *mm, pmd_t *pmd, argument 25 set_pmd(pmd, __pmd((unsigned long)page_address(pte))); 27 #define pmd_pgtable(pmd) pmd_page(pmd) 30 * Initialize a new pmd table with invalid pointers. 36 static inline void pud_populate(struct mm_struct *mm, pud_t *pud, pmd_t *pmd) argument 38 set_pud(pud, __pud((unsigned long)pmd)); 43 * Initialize a new pgd / pmd tabl 111 pmd_t *pmd; local 119 pmd_free(struct mm_struct *mm, pmd_t *pmd) argument [all...] |
/arch/sh/include/asm/ |
H A D | pgalloc.h | 13 extern void pud_populate(struct mm_struct *mm, pud_t *pudp, pmd_t *pmd); 15 extern void pmd_free(struct mm_struct *mm, pmd_t *pmd); 18 static inline void pmd_populate_kernel(struct mm_struct *mm, pmd_t *pmd, argument 21 set_pmd(pmd, __pmd((unsigned long)pte)); 24 static inline void pmd_populate(struct mm_struct *mm, pmd_t *pmd, argument 27 set_pmd(pmd, __pmd((unsigned long)page_address(pte))); 29 #define pmd_pgtable(pmd) pmd_page(pmd)
|
/arch/um/include/asm/ |
H A D | pgalloc.h | 13 #define pmd_populate_kernel(mm, pmd, pte) \ 14 set_pmd(pmd, __pmd(_PAGE_TABLE + (unsigned long) __pa(pte))) 16 #define pmd_populate(mm, pmd, pte) \ 17 set_pmd(pmd, __pmd(_PAGE_TABLE + \ 20 #define pmd_pgtable(pmd) pmd_page(pmd) 50 static inline void pmd_free(struct mm_struct *mm, pmd_t *pmd) argument 52 free_page((unsigned long)pmd);
|
/arch/sh/mm/ |
H A D | hugetlbpage.c | 29 pmd_t *pmd; local 36 pmd = pmd_alloc(mm, pud, addr); 37 if (pmd) 38 pte = pte_alloc_map(mm, NULL, pmd, addr); 49 pmd_t *pmd; local 56 pmd = pmd_offset(pud, addr); 57 if (pmd) 58 pte = pte_offset_map(pmd, addr); 76 int pmd_huge(pmd_t pmd) argument 87 pmd_t *pmd, in 86 follow_huge_pmd(struct mm_struct *mm, unsigned long address, pmd_t *pmd, int write) argument [all...] |
/arch/unicore32/kernel/ |
H A D | hibernate.c | 50 static pte_t *resume_one_page_table_init(pmd_t *pmd) argument 52 if (pmd_none(*pmd)) { 57 set_pmd(pmd, __pmd(__pa(page_table) | _PAGE_KERNEL_TABLE)); 59 BUG_ON(page_table != pte_offset_kernel(pmd, 0)); 64 return pte_offset_kernel(pmd, 0); 76 pmd_t *pmd; local 85 pmd = resume_one_md_table_init(pgd); 86 if (!pmd) 92 for (pmd_idx = 0; pmd_idx < PTRS_PER_PMD; pmd++, pmd_idx++) { 101 pte = resume_one_page_table_init(pmd); [all...] |
/arch/arm/mm/ |
H A D | idmap.c | 16 pmd_t *pmd; local 20 pmd = pmd_alloc_one(&init_mm, addr); 21 if (!pmd) { 22 pr_warning("Failed to allocate identity pmd.\n"); 25 pud_populate(&init_mm, pud, pmd); 26 pmd += pmd_index(addr); 28 pmd = pmd_offset(pud, addr); 32 *pmd = __pmd((addr & PMD_MASK) | prot); 33 flush_pmd_entry(pmd); 34 } while (pmd 40 pmd_t *pmd = pmd_offset(pud, addr); local [all...] |
/arch/m32r/include/asm/ |
H A D | pgalloc.h | 8 #define pmd_populate_kernel(mm, pmd, pte) \ 9 set_pmd(pmd, __pmd(_PAGE_TABLE + __pa(pte))) 11 static __inline__ void pmd_populate(struct mm_struct *mm, pmd_t *pmd, argument 14 set_pmd(pmd, __pmd(_PAGE_TABLE + page_to_phys(pte))); 16 #define pmd_pgtable(pmd) pmd_page(pmd) 64 * allocating and freeing a pmd is trivial: the 1-entry pmd is 72 #define pgd_populate(mm, pmd, pte) BUG()
|
/arch/m68k/include/asm/ |
H A D | mcf_pgalloc.h | 36 #define pmd_populate(mm, pmd, page) (pmd_val(*pmd) = \ 39 #define pmd_populate_kernel(mm, pmd, pte) (pmd_val(*pmd) = (unsigned long)(pte)) 41 #define pmd_pgtable(pmd) pmd_page(pmd) 49 #define __pmd_free_tlb(tlb, pmd, address) do { } while (0) 78 * In our implementation, each pgd entry contains 1 pmd that is never allocated 81 #define pmd_free(mm, pmd) BUG() 100 #define pgd_populate(mm, pmd, pt [all...] |
H A D | motorola_pgalloc.h | 70 static inline int pmd_free(struct mm_struct *mm, pmd_t *pmd) argument 72 return free_pointer_table(pmd); 75 static inline int __pmd_free_tlb(struct mmu_gather *tlb, pmd_t *pmd, argument 78 return free_pointer_table(pmd); 93 static inline void pmd_populate_kernel(struct mm_struct *mm, pmd_t *pmd, pte_t *pte) argument 95 pmd_set(pmd, pte); 98 static inline void pmd_populate(struct mm_struct *mm, pmd_t *pmd, pgtable_t page) argument 100 pmd_set(pmd, page_address(page)); 102 #define pmd_pgtable(pmd) pmd_page(pmd) 104 pgd_populate(struct mm_struct *mm, pgd_t *pgd, pmd_t *pmd) argument [all...] |
H A D | sun3_pgalloc.h | 67 static inline void pmd_populate_kernel(struct mm_struct *mm, pmd_t *pmd, pte_t *pte) argument 69 pmd_val(*pmd) = __pa((unsigned long)pte); 72 static inline void pmd_populate(struct mm_struct *mm, pmd_t *pmd, pgtable_t page) argument 74 pmd_val(*pmd) = __pa((unsigned long)page_address(page)); 76 #define pmd_pgtable(pmd) pmd_page(pmd) 79 * allocating and freeing a pmd is trivial: the 1-entry pmd is 100 #define pgd_populate(mm, pmd, pte) BUG()
|
/arch/unicore32/mm/ |
H A D | pgd.c | 80 pmd_t *pmd; local 87 pmd = pmd_off(pgd, 0); 88 if (pmd_none(*pmd)) 90 if (pmd_bad(*pmd)) { 91 pmd_ERROR(*pmd); 92 pmd_clear(pmd); 96 pte = pmd_pgtable(*pmd); 97 pmd_clear(pmd); 99 pmd_free(mm, pmd);
|
/arch/tile/include/asm/ |
H A D | pgalloc.h | 41 static inline void set_pmd(pmd_t *pmdp, pmd_t pmd) argument 44 set_pte(pmdp, pmd); 46 set_pte(&pmdp->pud.pgd, pmd.pud.pgd); 51 pmd_t *pmd, pte_t *ptep) 53 set_pmd(pmd, ptfn_pmd(__pa(ptep) >> HV_LOG2_PAGE_TABLE_ALIGN, 57 static inline void pmd_populate(struct mm_struct *mm, pmd_t *pmd, argument 60 set_pmd(pmd, ptfn_pmd(HV_PFN_TO_PTFN(page_to_pfn(page)), 74 #define pmd_pgtable(pmd) pmd_page(pmd) 101 void shatter_pmd(pmd_t *pmd); 50 pmd_populate_kernel(struct mm_struct *mm, pmd_t *pmd, pte_t *ptep) argument [all...] |
/arch/frv/include/asm/ |
H A D | pgalloc.h | 23 #define pmd_populate_kernel(mm, pmd, pte) __set_pmd(pmd, __pa(pte) | _PAGE_TABLE) 28 #define pmd_pgtable(pmd) pmd_page(pmd) 59 * allocating and freeing a pmd is trivial: the 1-entry pmd is
|
/arch/x86/include/asm/ |
H A D | pgalloc.h | 63 pmd_t *pmd, pte_t *pte) 66 set_pmd(pmd, __pmd(__pa(pte) | _PAGE_TABLE)); 69 static inline void pmd_populate(struct mm_struct *mm, pmd_t *pmd, argument 75 set_pmd(pmd, __pmd(((pteval_t)pfn << PAGE_SHIFT) | _PAGE_TABLE)); 78 #define pmd_pgtable(pmd) pmd_page(pmd) 86 static inline void pmd_free(struct mm_struct *mm, pmd_t *pmd) argument 88 BUG_ON((unsigned long)pmd & (PAGE_SIZE-1)); 89 free_page((unsigned long)pmd); 92 extern void ___pmd_free_tlb(struct mmu_gather *tlb, pmd_t *pmd); 62 pmd_populate_kernel(struct mm_struct *mm, pmd_t *pmd, pte_t *pte) argument 94 __pmd_free_tlb(struct mmu_gather *tlb, pmd_t *pmd, unsigned long address) argument 103 pud_populate(struct mm_struct *mm, pud_t *pud, pmd_t *pmd) argument [all...] |
/arch/x86/power/ |
H A D | hibernate_32.c | 61 static pte_t *resume_one_page_table_init(pmd_t *pmd) argument 63 if (pmd_none(*pmd)) { 68 set_pmd(pmd, __pmd(__pa(page_table) | _PAGE_TABLE)); 70 BUG_ON(page_table != pte_offset_kernel(pmd, 0)); 75 return pte_offset_kernel(pmd, 0); 87 pmd_t *pmd; local 96 pmd = resume_one_md_table_init(pgd); 97 if (!pmd) 103 for (pmd_idx = 0; pmd_idx < PTRS_PER_PMD; pmd++, pmd_idx++) { 112 set_pmd(pmd, pfn_pm [all...] |
/arch/cris/include/asm/ |
H A D | pgalloc.h | 7 #define pmd_populate_kernel(mm, pmd, pte) pmd_set(pmd, pte) 8 #define pmd_populate(mm, pmd, pte) pmd_set(pmd, page_address(pte)) 9 #define pmd_pgtable(pmd) pmd_page(pmd)
|
/arch/openrisc/include/asm/ |
H A D | pgalloc.h | 30 #define pmd_populate_kernel(mm, pmd, pte) \ 31 set_pmd(pmd, __pmd(_KERNPG_TABLE + __pa(pte))) 33 static inline void pmd_populate(struct mm_struct *mm, pmd_t *pmd, argument 36 set_pmd(pmd, __pmd(_KERNPG_TABLE + 98 #define pmd_pgtable(pmd) pmd_page(pmd)
|
/arch/unicore32/include/asm/ |
H A D | tlbflush.h | 135 static inline void flush_pmd_entry(pmd_t *pmd) argument 146 : : "r" (pmd) : "r1", "r2"); 150 : : "r" (pmd) : "cc"); 154 static inline void clean_pmd_entry(pmd_t *pmd) argument 159 : : "r" (__pa(pmd) & ~(L1_CACHE_BYTES - 1)) : "cc"); 163 : : "r" (pmd) : "cc");
|
/arch/mips/mm/ |
H A D | hugetlbpage.c | 44 pmd_t *pmd = NULL; local 50 pmd = pmd_offset(pud, addr); 52 return (pte_t *) pmd; 78 int pmd_huge(pmd_t pmd) argument 80 return (pmd_val(pmd) & _PAGE_HUGE) != 0; 90 pmd_t *pmd, int write) 94 page = pte_page(*(pte_t *)pmd); 89 follow_huge_pmd(struct mm_struct *mm, unsigned long address, pmd_t *pmd, int write) argument
|