Re: [PATCH 4/8] KVM: MMU: hypercall based pte updates and TLB flushes

Marcelo Tosatti
2008-03-03T14:43:35Z

Hi Avi,

Looks nice.

On Sun, Mar 02, 2008 at 06:31:17PM +0200, Avi Kivity wrote:
> +int kvm_pv_mmu_op(struct kvm_vcpu *vcpu, unsigned long bytes,
> + gpa_t addr, unsigned long *ret)
> +{
> + int r;
> + struct kvm_pv_mmu_op_buffer buffer;

Perhaps this structure is a little large to be on stack.

> + down_read(&current->mm->mmap_sem);
> + down_read(&vcpu->kvm->slots_lock);

The order should be slots_locks then mmap_sem. Need some comment in the
code.