Home
last modified time | relevance | path

Searched refs:rmap (Results 1 – 13 of 13) sorted by relevance

/arch/powerpc/kvm/
Dbook3s_hv_rm_mmu.c82 unsigned long *rmap, long pte_index, int realmode) in kvmppc_add_revmap_chain() argument
87 if (*rmap & KVMPPC_RMAP_PRESENT) { in kvmppc_add_revmap_chain()
88 i = *rmap & KVMPPC_RMAP_INDEX; in kvmppc_add_revmap_chain()
101 *rmap = (*rmap & ~KVMPPC_RMAP_INDEX) | in kvmppc_add_revmap_chain()
104 unlock_rmap(rmap); in kvmppc_add_revmap_chain()
143 unsigned long *rmap; in revmap_for_hpte() local
155 rmap = real_vmalloc_addr(&memslot->arch.rmap[gfn - memslot->base_gfn]); in revmap_for_hpte()
156 return rmap; in revmap_for_hpte()
166 unsigned long *rmap; in remove_revmap_chain() local
173 rmap = revmap_for_hpte(kvm, hpte_v, ptel, &memslot, &gfn); in remove_revmap_chain()
[all …]
Dbook3s_64_vio_hv.c92 *prmap = &memslot->arch.rmap[gfn - memslot->base_gfn]; in kvmppc_rm_tce_to_ua()
495 unsigned long *rmap = NULL; in kvmppc_rm_h_put_tce_indirect() local
546 if (kvmppc_rm_tce_to_ua(vcpu->kvm, tce_list, &ua, &rmap)) in kvmppc_rm_h_put_tce_indirect()
549 rmap = (void *) vmalloc_to_phys(rmap); in kvmppc_rm_h_put_tce_indirect()
550 if (WARN_ON_ONCE_RM(!rmap)) in kvmppc_rm_h_put_tce_indirect()
561 lock_rmap(rmap); in kvmppc_rm_h_put_tce_indirect()
601 if (rmap) in kvmppc_rm_h_put_tce_indirect()
602 unlock_rmap(rmap); in kvmppc_rm_h_put_tce_indirect()
Dbook3s_hv_nested.c785 u64 rmap, new_rmap = (*n_rmap)->rmap; in kvmhv_insert_nest_rmap() local
795 for_each_nest_rmap_safe(cursor, entry, &rmap) { in kvmhv_insert_nest_rmap()
796 if (kvmhv_n_rmap_is_equal(rmap, new_rmap)) in kvmhv_insert_nest_rmap()
801 rmap = *rmapp; in kvmhv_insert_nest_rmap()
802 if (rmap & RMAP_NESTED_IS_SINGLE_ENTRY) /* Not previously a list */ in kvmhv_insert_nest_rmap()
805 if (rmap & RMAP_NESTED_IS_SINGLE_ENTRY) /* Not previously a list */ in kvmhv_insert_nest_rmap()
806 (*n_rmap)->list.next = (struct llist_node *) rmap; in kvmhv_insert_nest_rmap()
851 unsigned long rmap, mask; in kvmhv_update_nest_rmap_rc_list() local
859 for_each_nest_rmap_safe(cursor, entry, &rmap) in kvmhv_update_nest_rmap_rc_list()
860 kvmhv_update_nest_rmap_rc(kvm, rmap, clr, set, hpa, mask); in kvmhv_update_nest_rmap_rc_list()
[all …]
Dbook3s_64_mmu_hv.c502 unsigned long *rmap; in kvmppc_book3s_hv_page_fault() local
687 rmap = &memslot->arch.rmap[gfn_base - memslot->base_gfn]; in kvmppc_book3s_hv_page_fault()
688 lock_rmap(rmap); in kvmppc_book3s_hv_page_fault()
693 unlock_rmap(rmap); in kvmppc_book3s_hv_page_fault()
698 rcbits = *rmap >> KVMPPC_RMAP_RC_SHIFT; in kvmppc_book3s_hv_page_fault()
703 unlock_rmap(rmap); in kvmppc_book3s_hv_page_fault()
709 kvmppc_add_revmap_chain(kvm, rev, rmap, index, 0); in kvmppc_book3s_hv_page_fault()
759 memset(memslot->arch.rmap, 0, in kvmppc_rmap_reset()
760 memslot->npages * sizeof(*memslot->arch.rmap)); in kvmppc_rmap_reset()
861 rmapp = &memslot->arch.rmap[gfn - memslot->base_gfn]; in kvm_unmap_rmapp()
[all …]
Dbook3s_64_mmu_radix.c1011 rmapp = &memslot->arch.rmap[gfn - memslot->base_gfn]; in kvm_age_radix()
1056 rmapp = &memslot->arch.rmap[gfn - memslot->base_gfn]; in kvm_radix_test_clear_dirty()
Dbook3s_hv.c4487 if (!dont || free->arch.rmap != dont->arch.rmap) { in kvmppc_core_free_memslot_hv()
4488 vfree(free->arch.rmap); in kvmppc_core_free_memslot_hv()
4489 free->arch.rmap = NULL; in kvmppc_core_free_memslot_hv()
4496 slot->arch.rmap = vzalloc(array_size(npages, sizeof(*slot->arch.rmap))); in kvmppc_core_create_memslot_hv()
4497 if (!slot->arch.rmap) in kvmppc_core_create_memslot_hv()
/arch/powerpc/include/asm/
Dkvm_book3s_64.h64 u64 rmap; member
104 ((u64) (node)) : ((pos)->rmap))) && \
473 static inline void lock_rmap(unsigned long *rmap) in lock_rmap() argument
476 while (test_bit(KVMPPC_RMAP_LOCK_BIT, rmap)) in lock_rmap()
478 } while (test_and_set_bit_lock(KVMPPC_RMAP_LOCK_BIT, rmap)); in lock_rmap()
481 static inline void unlock_rmap(unsigned long *rmap) in unlock_rmap() argument
483 __clear_bit_unlock(KVMPPC_RMAP_LOCK_BIT, rmap); in unlock_rmap()
Dkvm_book3s.h241 unsigned long *rmap, long pte_index, int realmode);
Dkvm_host.h262 unsigned long *rmap; member
/arch/s390/mm/
Dgmap.c152 struct gmap_rmap *rmap, *rnext, *head; in gmap_rmap_radix_tree_free() local
171 gmap_for_each_rmap_safe(rmap, rnext, head) in gmap_rmap_radix_tree_free()
172 kfree(rmap); in gmap_rmap_radix_tree_free()
1179 struct gmap_rmap *rmap) in gmap_insert_rmap() argument
1186 rmap->next = radix_tree_deref_slot_protected(slot, in gmap_insert_rmap()
1188 radix_tree_replace_slot(&sg->host_to_rmap, slot, rmap); in gmap_insert_rmap()
1190 rmap->next = NULL; in gmap_insert_rmap()
1192 rmap); in gmap_insert_rmap()
1210 struct gmap_rmap *rmap; in gmap_protect_rmap() local
1222 rmap = kzalloc(sizeof(*rmap), GFP_KERNEL); in gmap_protect_rmap()
[all …]
/arch/x86/kvm/
Dmmu.c1486 return &slot->arch.rmap[level - PT_PAGE_TABLE_LEVEL][idx]; in __gfn_to_rmap()
1943 struct kvm_rmap_head *rmap; member
1955 iterator->rmap = __gfn_to_rmap(iterator->gfn, level, iterator->slot); in rmap_walk_init_level()
1976 return !!iterator->rmap; in slot_rmap_walk_okay()
1981 if (++iterator->rmap <= iterator->end_rmap) { in slot_rmap_walk_next()
1987 iterator->rmap = NULL; in slot_rmap_walk_next()
2040 ret |= handler(kvm, iterator.rmap, memslot, in kvm_handle_hva_range()
5691 if (iterator.rmap) in slot_handle_level_range()
5692 flush |= fn(kvm, iterator.rmap); in slot_handle_level_range()
Dx86.c9805 if (!dont || free->arch.rmap[i] != dont->arch.rmap[i]) { in kvm_arch_free_memslot()
9806 kvfree(free->arch.rmap[i]); in kvm_arch_free_memslot()
9807 free->arch.rmap[i] = NULL; in kvm_arch_free_memslot()
9843 slot->arch.rmap[i] = in kvm_arch_create_memslot()
9844 kvcalloc(lpages, sizeof(*slot->arch.rmap[i]), in kvm_arch_create_memslot()
9846 if (!slot->arch.rmap[i]) in kvm_arch_create_memslot()
9883 kvfree(slot->arch.rmap[i]); in kvm_arch_create_memslot()
9884 slot->arch.rmap[i] = NULL; in kvm_arch_create_memslot()
/arch/x86/include/asm/
Dkvm_host.h795 struct kvm_rmap_head *rmap[KVM_NR_PAGE_SIZES]; member