views:

40

answers:

1

I know that the qemu-kvm does the device emulation stuff in KVM. Is the qemu-kvm being executed in the userspace of the host? So when a kick function is encountered, it exits the VM through a hypercall into the hypervisor, then the hypervisor hand over to qemu-kvm in host userspace. Next after doing the needed things, the qemu-kvm transits to the hypervisor and then the hypervisor back to the VM. So it means there are two system calls one from VM-->Hypervisor and qemu-kvm-->Hypervisor? Are these the steps that take place or i am wrong? If there is any documentation about these kind of stuff, please give me the link. Thank you very much...

Thanks, Bala

A: 

Is the qemu-kvm being executed in the userspace of the host? yes, this is a performance bottleneck too and there are ways around it being developed. Look at PCI SR-IOV NIC for network and NPIV for fibrechannel. They both are special hardware designed to subdivided I/O controllers so that KVM/qemu can attach the VM to a private channel on the controller.

So it means there are two system calls one from VM-->Hypervisor and qemu-kvm-->Hypervisor? I don't know for certain but I think there are device interrupts crossing user-kernel space boundaries not systems calls.

Perhaps this document will help you a bit:

http://www.linux-kvm.org/wiki/images/4/42/Kvm-device-assignment.pdf

Ken Stailey