From mboxrd@z Thu Jan 1 00:00:00 1970 From: Cornelia Huck Subject: Re: [PATCH v2] KVM: introduce kvm_arch_vcpu_async_ioctl Date: Wed, 13 Dec 2017 10:41:39 +0100 Message-ID: <20171213104139.65396b1c.cohuck@redhat.com> References: <1513157757-1917-1-git-send-email-pbonzini@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: linux-kernel@vger.kernel.org, kvm@vger.kernel.org, christoffer.dall@linaro.org, James Hogan , Paul Mackerras , Christian Borntraeger To: Paolo Bonzini Return-path: In-Reply-To: <1513157757-1917-1-git-send-email-pbonzini@redhat.com> Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org On Wed, 13 Dec 2017 10:35:57 +0100 Paolo Bonzini wrote: > After the vcpu_load/vcpu_put pushdown, the handling of asynchronous VCPU > ioctl is already much clearer in that it is obvious that they bypass > vcpu_load and vcpu_put. > > However, it is still not perfect in that the different state of the VCPU > mutex is still hidden in the caller. Separate those ioctls into a new > function kvm_arch_vcpu_async_ioctl that returns -ENOIOCTLCMD for more > "traditional" synchronous ioctls. > > Cc: James Hogan > Cc: Paul Mackerras > Cc: Christian Borntraeger > Reviewed-by: Christoffer Dall > Reviewed-by: Cornelia Huck > Suggested-by: Cornelia Huck > Signed-off-by: Paolo Bonzini > --- > arch/mips/kvm/Kconfig | 1 + > arch/mips/kvm/mips.c | 15 ++++++++++++--- > arch/powerpc/kvm/Kconfig | 1 + > arch/powerpc/kvm/powerpc.c | 14 +++++++++++--- > arch/s390/kvm/Kconfig | 1 + > arch/s390/kvm/kvm-s390.c | 16 ++++++++++++---- > include/linux/kvm_host.h | 11 +++++++++++ > virt/kvm/kvm_main.c | 12 +++++------- > 8 files changed, 54 insertions(+), 17 deletions(-) Using HAVE_KVM_VCPU_ASYNC_IOCTL looks good to me.