• Andrey Smetanin's avatar
    kvm/x86: Hyper-V SynIC message slot pending clearing at SINT ack · 765eaa0f
    Andrey Smetanin authored
    The SynIC message protocol mandates that the message slot is claimed
    by atomically setting message type to something other than HVMSG_NONE.
    If another message is to be delivered while the slot is still busy,
    message pending flag is asserted to indicate to the guest that the
    hypervisor wants to be notified when the slot is released.
    
    To make sure the protocol works regardless of where the message
    sources are (kernel or userspace), clear the pending flag on SINT ACK
    notification, and let the message sources compete for the slot again.
    Signed-off-by: default avatarAndrey Smetanin <asmetanin@virtuozzo.com>
    Reviewed-by: default avatarRoman Kagan <rkagan@virtuozzo.com>
    CC: Gleb Natapov <gleb@kernel.org>
    CC: Paolo Bonzini <pbonzini@redhat.com>
    CC: "K. Y. Srinivasan" <kys@microsoft.com>
    CC: Haiyang Zhang <haiyangz@microsoft.com>
    CC: Vitaly Kuznetsov <vkuznets@redhat.com>
    CC: Roman Kagan <rkagan@virtuozzo.com>
    CC: Denis V. Lunev <den@openvz.org>
    CC: qemu-devel@nongnu.org
    Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
    765eaa0f
hyperv.c 18.3 KB