On Tue, 7 Aug 2012 12:57:13 +0200
Alexander Graf <[email protected]> wrote:
> +struct kvm_memory_slot *hva_to_memslot(struct kvm *kvm, hva_t hva)
> +{
> + struct kvm_memslots *slots = kvm_memslots(kvm);
> + struct kvm_memory_slot *memslot;
> +
> + kvm_for_each_memslot(memslot, slots)
> + if (hva >= memslot->userspace_addr &&
> + hva < memslot->userspace_addr + memslot->npages)
> + return memslot;
> +
> + return NULL;
> +}
Can't we have two memory slots which contain that hva?
I thought that's why hva handler had to check all slots.
Thanks,
Takuya
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html