qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Pavel Fedin <p.fedin@samsung.com>
To: 'Roman Kagan' <rkagan@virtuozzo.com>
Cc: kvm@vger.kernel.org, 'Gleb Natapov' <gleb@kernel.org>,
	'Joerg Roedel' <joro@8bytes.org>,
	qemu-devel@nongnu.org, "'Denis V. Lunev'" <den@openvz.org>,
	'Andrey Smetanin' <asmetanin@virtuozzo.com>,
	'Paolo Bonzini' <pbonzini@redhat.com>,
	"'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: Thu, 14 Jan 2016 13:50:20 +0300	[thread overview]
Message-ID: <00b201d14eb9$5d8ddeb0$18a99c10$@samsung.com> (raw)
In-Reply-To: <20160114102040.GA10363@rkaganb.sw.ru>

 Hello!

> We thought reusing KVM_EXIT_HYPERCALL was a bad idea exactly because of
> that.  Hypercalls are not universal, the calling and return conventions
> are hypervisor-specific.

 Treatment of them is hypervisor-specific, but from CPUs point of view they are the same. You load something into registers, and
execute hypercall instruction. So, you just need to pass registers in your structure. Or, you could even use generic register access
APIs.

>  KVM already has to make the decision that the
> particular vmexit is a HyperV hypercall; it appears unnatural to then
> pass the data on to userspace in a generic structure and have them make
> that decision again.

 Is it so difficult to make such a decision? The userland already knows what we are emulating.
 I'm afraid that in future we can end up in having 10 versions of KVM_EXIT_xxx_HYPERCALL with very small difference between them.
Will it be good?

Kind regards,
Pavel Fedin
Senior Engineer
Samsung Electronics Research center Russia

  reply	other threads:[~2016-01-14 10:50 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 [this message]
2016-01-14 11:52         ` 'Roman Kagan'
2016-01-20 13:59     ` Paolo Bonzini
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='00b201d14eb9$5d8ddeb0$18a99c10$@samsung.com' \
    --to=p.fedin@samsung.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=pbonzini@redhat.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).