Lines Matching refs:vaddr
121 static void __init __sme_early_map_unmap_mem(void *vaddr, unsigned long size, in __sme_early_map_unmap_mem() argument
124 unsigned long paddr = (unsigned long)vaddr - __PAGE_OFFSET; in __sme_early_map_unmap_mem()
132 __early_make_pgtable((unsigned long)vaddr, pmd); in __sme_early_map_unmap_mem()
134 vaddr += PMD_SIZE; in __sme_early_map_unmap_mem()
261 void notify_range_enc_status_changed(unsigned long vaddr, int npages, bool enc) in notify_range_enc_status_changed() argument
265 unsigned long vaddr_end = vaddr + sz; in notify_range_enc_status_changed()
267 while (vaddr < vaddr_end) { in notify_range_enc_status_changed()
272 kpte = lookup_address(vaddr, &level); in notify_range_enc_status_changed()
287 vaddr = (vaddr & pmask) + psize; in notify_range_enc_status_changed()
333 static int __init early_set_memory_enc_dec(unsigned long vaddr, in early_set_memory_enc_dec() argument
342 start = vaddr; in early_set_memory_enc_dec()
343 vaddr_next = vaddr; in early_set_memory_enc_dec()
344 vaddr_end = vaddr + size; in early_set_memory_enc_dec()
346 for (; vaddr < vaddr_end; vaddr = vaddr_next) { in early_set_memory_enc_dec()
347 kpte = lookup_address(vaddr, &level); in early_set_memory_enc_dec()
355 vaddr_next = (vaddr & PAGE_MASK) + PAGE_SIZE; in early_set_memory_enc_dec()
368 if (vaddr == (vaddr & pmask) && in early_set_memory_enc_dec()
369 ((vaddr_end - vaddr) >= psize)) { in early_set_memory_enc_dec()
371 vaddr_next = (vaddr & pmask) + psize; in early_set_memory_enc_dec()
390 kernel_physical_mapping_change(__pa(vaddr & pmask), in early_set_memory_enc_dec()
403 int __init early_set_memory_decrypted(unsigned long vaddr, unsigned long size) in early_set_memory_decrypted() argument
405 return early_set_memory_enc_dec(vaddr, size, false); in early_set_memory_decrypted()
408 int __init early_set_memory_encrypted(unsigned long vaddr, unsigned long size) in early_set_memory_encrypted() argument
410 return early_set_memory_enc_dec(vaddr, size, true); in early_set_memory_encrypted()
413 void __init early_set_mem_enc_dec_hypercall(unsigned long vaddr, int npages, bool enc) in early_set_mem_enc_dec_hypercall() argument
415 notify_range_enc_status_changed(vaddr, npages, enc); in early_set_mem_enc_dec_hypercall()
446 unsigned long vaddr, vaddr_end, npages; in mem_encrypt_free_decrypted_mem() local
449 vaddr = (unsigned long)__start_bss_decrypted_unused; in mem_encrypt_free_decrypted_mem()
451 npages = (vaddr_end - vaddr) >> PAGE_SHIFT; in mem_encrypt_free_decrypted_mem()
458 r = set_memory_encrypted(vaddr, npages); in mem_encrypt_free_decrypted_mem()
465 free_init_pages("unused decrypted", vaddr, vaddr_end); in mem_encrypt_free_decrypted_mem()