[Devel] [PATCH RHEL7 COMMIT] ms/drivers/hv: Move VMBus hypercall codes into Hyper-V UAPI header

Konstantin Khorenko khorenko at virtuozzo.com
Sat Feb 20 08:11:47 PST 2016


The commit is pushed to "branch-rh7-3.10.0-327.4.5.vz7.11.x-ovz" and will appear at https://src.openvz.org/scm/ovz/vzkernel.git
after rh7-3.10.0-327.4.5.vz7.11.5
------>
commit 2e2751bd829e8130b2bd089b6f38a66e320bded4
Author: Andrey Smetanin <asmetanin at virtuozzo.com>
Date:   Sat Feb 20 20:11:47 2016 +0400

    ms/drivers/hv: Move VMBus hypercall codes into Hyper-V UAPI header
    
    Series description:
    
    KVM: Hyper-V VMBus hypercalls
    
    The patch implements userspace exit 'KVM_EXIT_HYPERV'
    for Hyper-V VMBus hypercalls(postmsg, signalevent)
    to handle these hypercalls by QEMU.
    
    Changes v3:
    * use vcpu->arch.complete_userspace_io to setup hypercall
    result
    * rebase for 'next-20160211'
    
    Changes v2:
    * use KVM_EXIT_HYPERV for hypercalls
    
    https://jira.sw.ru/browse/PSBM-44419
    
    Andrey Smetanin (5):
    ms/kvm/x86: Rename Hyper-V long spin wait hypercall
    ms/drivers/hv: Move VMBus hypercall codes into Hyper-V UAPI header
    ms/kvm/x86: Pass return code of kvm_emulate_hypercall
    ms/kvm/x86: Reject Hyper-V hypercall continuation
    ms/kvm/x86: Hyper-V VMBus hypercall userspace exit
    
    Reviewed-by: Roman Kagan <rkagan at virtuozzo.com>
    ===============================================
    This patch description:
    
    VMBus hypercall codes inside Hyper-V UAPI header will
    be used by QEMU to implement VMBus host devices support.
    
    Signed-off-by: Andrey Smetanin <asmetanin at virtuozzo.com>
    
    Acked-by: K. Y. Srinivasan <kys at microsoft.com>
    Reviewed-by: Roman Kagan <rkagan at virtuozzo.com>
    CC: Gleb Natapov <gleb at kernel.org>
    CC: Paolo Bonzini <pbonzini at redhat.com>
    CC: Joerg Roedel <joro at 8bytes.org>
    CC: "K. Y. Srinivasan" <kys at microsoft.com>
    CC: Haiyang Zhang <haiyangz at microsoft.com>
    CC: Roman Kagan <rkagan at virtuozzo.com>
    CC: Denis V. Lunev <den at openvz.org>
    CC: qemu-devel at nongnu.org
    [Do not rename the constant at the same time as moving it, as that
     would cause semantic conflicts with the Hyper-V tree. - Paolo]
    Signed-off-by: Paolo Bonzini <pbonzini at redhat.com>
    
    (cherry picked from commit 18f098618aa031f4c8a907c550fcd6785280c977)
---
 arch/x86/include/uapi/asm/hyperv.h | 2 ++
 drivers/hv/hyperv_vmbus.h          | 6 ------
 2 files changed, 2 insertions(+), 6 deletions(-)

diff --git a/arch/x86/include/uapi/asm/hyperv.h b/arch/x86/include/uapi/asm/hyperv.h
index 5c068c2..b7f45ea 100644
--- a/arch/x86/include/uapi/asm/hyperv.h
+++ b/arch/x86/include/uapi/asm/hyperv.h
@@ -223,6 +223,8 @@
 
 /* Declare the various hypercall operations. */
 #define HVCALL_NOTIFY_LONG_SPIN_WAIT		0x0008
+#define HVCALL_POST_MESSAGE			0x005c
+#define HVCALL_SIGNAL_EVENT			0x005d
 
 #define HV_X64_MSR_APIC_ASSIST_PAGE_ENABLE		0x00000001
 #define HV_X64_MSR_APIC_ASSIST_PAGE_ADDRESS_SHIFT	12
diff --git a/drivers/hv/hyperv_vmbus.h b/drivers/hv/hyperv_vmbus.h
index 255d852..b07745b 100644
--- a/drivers/hv/hyperv_vmbus.h
+++ b/drivers/hv/hyperv_vmbus.h
@@ -235,12 +235,6 @@ struct hv_monitor_page {
 	u8 rsvdz4[1984];
 };
 
-/* Declare the various hypercall operations. */
-enum hv_call_code {
-	HVCALL_POST_MESSAGE	= 0x005c,
-	HVCALL_SIGNAL_EVENT	= 0x005d,
-};
-
 /* Definition of the hv_post_message hypercall input structure. */
 struct hv_input_post_message {
 	union hv_connection_id connectionid;


More information about the Devel mailing list