• Joao Martins's avatar
    KVM: x86/xen: Fix coexistence of Xen and Hyper-V hypercalls · 79033beb
    Joao Martins authored
    Disambiguate Xen vs. Hyper-V calls by adding 'orl $0x80000000, %eax'
    at the start of the Hyper-V hypercall page when Xen hypercalls are
    also enabled.
    
    That bit is reserved in the Hyper-V ABI, and those hypercall numbers
    will never be used by Xen (because it does precisely the same trick).
    
    Switch to using kvm_vcpu_write_guest() while we're at it, instead of
    open-coding it.
    Signed-off-by: default avatarDavid Woodhouse <dwmw@amazon.co.uk>
    79033beb
hyperv.c 55.2 KB