Lines Matching refs:pgd
123 static void __init kasan_populate_pgd(pgd_t *pgd, unsigned long addr, in kasan_populate_pgd() argument
130 if (pgd_none(*pgd)) { in kasan_populate_pgd()
132 pgd_populate(&init_mm, pgd, p); in kasan_populate_pgd()
135 p4d = p4d_offset(pgd, addr); in kasan_populate_pgd()
145 pgd_t *pgd; in kasan_populate_shadow() local
150 pgd = pgd_offset_k(addr); in kasan_populate_shadow()
153 kasan_populate_pgd(pgd, addr, next, nid); in kasan_populate_shadow()
154 } while (pgd++, addr = next, addr != end); in kasan_populate_shadow()
171 pgd_t *pgd; in clear_pgds() local
176 pgd = pgd_offset_k(start); in clear_pgds()
182 pgd_clear(pgd); in clear_pgds()
184 p4d_clear(p4d_offset(pgd, start)); in clear_pgds()
187 pgd = pgd_offset_k(start); in clear_pgds()
189 p4d_clear(p4d_offset(pgd, start)); in clear_pgds()
192 static inline p4d_t *early_p4d_offset(pgd_t *pgd, unsigned long addr) in early_p4d_offset() argument
197 return (p4d_t *)pgd; in early_p4d_offset()
199 p4d = pgd_val(*pgd) & PTE_PFN_MASK; in early_p4d_offset()
204 static void __init kasan_early_p4d_populate(pgd_t *pgd, in kasan_early_p4d_populate() argument
212 if (pgd_none(*pgd)) { in kasan_early_p4d_populate()
215 set_pgd(pgd, pgd_entry); in kasan_early_p4d_populate()
218 p4d = early_p4d_offset(pgd, addr); in kasan_early_p4d_populate()
231 static void __init kasan_map_early_shadow(pgd_t *pgd) in kasan_map_early_shadow() argument
238 pgd += pgd_index(addr); in kasan_map_early_shadow()
241 kasan_early_p4d_populate(pgd, addr, next); in kasan_map_early_shadow()
242 } while (pgd++, addr = next, addr != end); in kasan_map_early_shadow()
245 static void __init kasan_shallow_populate_p4ds(pgd_t *pgd, in kasan_shallow_populate_p4ds() argument
253 p4d = p4d_offset(pgd, addr); in kasan_shallow_populate_p4ds()
267 pgd_t *pgd; in kasan_shallow_populate_pgds() local
271 pgd = pgd_offset_k(addr); in kasan_shallow_populate_pgds()
275 if (pgd_none(*pgd)) { in kasan_shallow_populate_pgds()
277 pgd_populate(&init_mm, pgd, p); in kasan_shallow_populate_pgds()
284 kasan_shallow_populate_p4ds(pgd, addr, next); in kasan_shallow_populate_pgds()
285 } while (pgd++, addr = next, addr != (unsigned long)end); in kasan_shallow_populate_pgds()