Lines Matching refs:pmd
97 static pte_t * __init one_page_table_init(pmd_t *pmd) in one_page_table_init() argument
99 if (!(pmd_val(*pmd) & _PAGE_PRESENT)) { in one_page_table_init()
103 set_pmd(pmd, __pmd(__pa(page_table) | _PAGE_TABLE)); in one_page_table_init()
104 BUG_ON(page_table != pte_offset_kernel(pmd, 0)); in one_page_table_init()
107 return pte_offset_kernel(pmd, 0); in one_page_table_init()
121 pmd_t *pmd; in populate_extra_pte() local
123 pmd = populate_extra_pmd(vaddr); in populate_extra_pte()
124 return one_page_table_init(pmd) + pte_idx; in populate_extra_pte()
158 static pte_t *__init page_table_kmap_check(pte_t *pte, pmd_t *pmd, in page_table_kmap_check() argument
185 set_pmd(pmd, __pmd(__pa(newpte)|_PAGE_TABLE)); in page_table_kmap_check()
186 BUG_ON(newpte != pte_offset_kernel(pmd, 0)); in page_table_kmap_check()
214 pmd_t *pmd; in page_table_range_init() local
228 pmd = one_md_table_init(pgd); in page_table_range_init()
229 pmd = pmd + pmd_index(vaddr); in page_table_range_init()
231 pmd++, pmd_idx++) { in page_table_range_init()
232 pte = page_table_kmap_check(one_page_table_init(pmd), in page_table_range_init()
233 pmd, vaddr, pte, &adr); in page_table_range_init()
266 pmd_t *pmd; in kernel_physical_mapping_init() local
299 pmd = one_md_table_init(pgd); in kernel_physical_mapping_init()
305 pmd += pmd_idx; in kernel_physical_mapping_init()
310 pmd++, pmd_idx++) { in kernel_physical_mapping_init()
338 set_pmd(pmd, pfn_pmd(pfn, init_prot)); in kernel_physical_mapping_init()
340 set_pmd(pmd, pfn_pmd(pfn, prot)); in kernel_physical_mapping_init()
345 pte = one_page_table_init(pmd); in kernel_physical_mapping_init()
446 pmd_t *pmd; in native_pagetable_init() local
466 pmd = pmd_offset(pud, va); in native_pagetable_init()
467 if (!pmd_present(*pmd)) in native_pagetable_init()
471 if (pmd_large(*pmd)) { in native_pagetable_init()
473 pfn, pmd, __pa(pmd)); in native_pagetable_init()
477 pte = pte_offset_kernel(pmd, va); in native_pagetable_init()
482 pfn, pmd, __pa(pmd), pte, __pa(pte)); in native_pagetable_init()