qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Pavel Fedin <p.fedin@samsung.com>,
	'Andrey Smetanin' <asmetanin@virtuozzo.com>,
	kvm@vger.kernel.org
Cc: 'Gleb Natapov' <gleb@kernel.org>,
	'Joerg Roedel' <joro@8bytes.org>,
	qemu-devel@nongnu.org, 'Roman Kagan' <rkagan@virtuozzo.com>,
	"'Denis V. Lunev'" <den@openvz.org>,
	"'K. Y. Srinivasan'" <kys@microsoft.com>,
	'Haiyang Zhang' <haiyangz@microsoft.com>
Subject: Re: [Qemu-devel] [PATCH v1 4/5] kvm/x86: Hyper-V VMBus hypercall userspace exit
Date: Wed, 20 Jan 2016 14:59:08 +0100	[thread overview]
Message-ID: <569F92AC.4030506@redhat.com> (raw)
In-Reply-To: <009401d14ea5$dc8cf250$95a6d6f0$@samsung.com>



On 14/01/2016 09:30, Pavel Fedin wrote:
>  Hello!
> 
>> --- a/Documentation/virtual/kvm/api.txt
>> +++ b/Documentation/virtual/kvm/api.txt
>> @@ -3359,6 +3359,14 @@ Hyper-V SynIC state change. Notification is used to remap SynIC
>>  event/message pages and to enable/disable SynIC messages/events processing
>>  in userspace.
>>
>> +		/* KVM_EXIT_HYPERV_HCALL */
>> +		struct {
>> +			__u64 input;
>> +			__u64 params[2];
>> +			__u64 result;
>> +		} hv_hcall;
>> +Indicates that the VCPU exits into userspace to process some guest
>> +Hyper-V hypercalls.
> 
> Why introducing this? We already have KVM_EXIT_HYPERCALL, which is
> exactly the same. AFAIK it's not used at the moment.
> Additionally, in theory we could have hypercalls handled in
> userspace for something else except HyperV. And not only for x86.

Because, as the docs say, we don't want to do that.  We want to use
KVM_EXIT_IO or KVM_EXIT_MMIO, with two exceptions: s390 and wherever we
can't do that for compatibility purposes.  This is the latter.  So we
should not add a new exit (I suggested elsewhere the existing hyper-v
exit) but we shouldn't use KVM_EXIT_HYPERCALL either.

There is a precedent in fact of using "something else than
KVM_EXIT_HYPERCALL" for interoperability/compatibility hypercalls,
namely KVM_EXIT_PAPR_HCALL.

Paolo

  parent reply	other threads:[~2016-01-20 13:59 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-12 10:50 [Qemu-devel] [PATCH v1 0/5] KVM: Hyper-V VMBus hypercalls Andrey Smetanin
2016-01-12 10:50 ` [Qemu-devel] [PATCH v1 1/5] kvm/x86: Rename Hyper-V long spin wait hypercall Andrey Smetanin
2016-01-12 10:50 ` [Qemu-devel] [PATCH v1 2/5] drivers/hv: Move VMBus hypercall codes into Hyper-V UAPI header Andrey Smetanin
2016-01-20 15:04   ` KY Srinivasan
2016-01-12 10:50 ` [Qemu-devel] [PATCH v1 3/5] kvm/x86: Pass return code of kvm_emulate_hypercall Andrey Smetanin
2016-01-12 10:50 ` [Qemu-devel] [PATCH v1 4/5] kvm/x86: Hyper-V VMBus hypercall userspace exit Andrey Smetanin
2016-01-14  8:30   ` Pavel Fedin
2016-01-14 10:20     ` 'Roman Kagan'
2016-01-14 10:50       ` Pavel Fedin
2016-01-14 11:52         ` 'Roman Kagan'
2016-01-20 13:59     ` Paolo Bonzini [this message]
2016-01-20 14:41       ` Pavel Fedin
2016-01-20 15:20       ` 'Roman Kagan'
2016-01-20 17:02         ` Paolo Bonzini
2016-01-20 17:31           ` 'Roman Kagan'
2016-01-20 21:05             ` Paolo Bonzini
2016-01-20 13:43   ` Paolo Bonzini
2016-01-20 16:51     ` Roman Kagan
2016-01-12 10:50 ` [Qemu-devel] [PATCH v1 5/5] kvm/x86: Reject Hyper-V hypercall continuation Andrey Smetanin
2016-01-12 11:19 ` [Qemu-devel] [PATCH v1 0/5] KVM: Hyper-V VMBus hypercalls Andrey Smetanin
2016-01-19  7:49 ` Denis V. Lunev
2016-01-19 16:47   ` Paolo Bonzini
2016-01-20 14:08     ` Paolo Bonzini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=569F92AC.4030506@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=asmetanin@virtuozzo.com \
    --cc=den@openvz.org \
    --cc=gleb@kernel.org \
    --cc=haiyangz@microsoft.com \
    --cc=joro@8bytes.org \
    --cc=kvm@vger.kernel.org \
    --cc=kys@microsoft.com \
    --cc=p.fedin@samsung.com \
    --cc=qemu-devel@nongnu.org \
    --cc=rkagan@virtuozzo.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).