Hello all,
I'm not sure I understood the KVM hypercall mechanism(linux on x86).
I understood that a hypercall is preformed with the instruction:
.byte 0x0f,0x01,0xc1
after putting the hypercall index on a register.
I guess that this instruction would cause a trap to the kernel, but from there on I haven't understood what's going on. How does the OS knows to attach this instruction to the hypervisor(so he could know what was is the hypercall and preform it)?
With "usual" traps (like system calls) a register is being updated so the OS would know what was the request, but it doesn't seem the case here...
If someone could shortly clear this for me, it would be a great help. In addition I would love to know why this specific instruction is being used and not some other trapping instruction.
Thank you and best regards,
Evi
Post new comment