Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752434AbdLLRst (ORCPT ); Tue, 12 Dec 2017 12:48:49 -0500 Received: from mx1.redhat.com ([209.132.183.28]:52734 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750853AbdLLRsr (ORCPT ); Tue, 12 Dec 2017 12:48:47 -0500 Subject: Re: [PATCH] KVM: introduce kvm_arch_vcpu_async_ioctl To: David Hildenbrand , linux-kernel@vger.kernel.org, kvm@vger.kernel.org Cc: kvm-ppc@vger.kernel.org, cohuck@redhat.com, christoffer.dall@linaro.org, James Hogan , Paul Mackerras , Christian Borntraeger References: <1513099915-107126-1-git-send-email-pbonzini@redhat.com> From: Paolo Bonzini Message-ID: Date: Tue, 12 Dec 2017 18:48:40 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.28]); Tue, 12 Dec 2017 17:48:47 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 807 Lines: 24 On 12/12/2017 18:47, David Hildenbrand wrote: >> @@ -2547,13 +2547,13 @@ static long kvm_vcpu_ioctl(struct file *filp, >> #if defined(CONFIG_S390) || defined(CONFIG_PPC) || defined(CONFIG_MIPS) > can we now also get rid of this ugly define? Not yet, I'd have to add the function to x86 and ARM, or a dummy inline. Paolo >> /* >> * Special cases: vcpu ioctls that are asynchronous to vcpu execution, >> - * so vcpu_load() would break it. >> + * so mutex_lock() would break it. >> */ >> - if (ioctl == KVM_S390_INTERRUPT || ioctl == KVM_S390_IRQ || ioctl == KVM_INTERRUPT) >> - return kvm_arch_vcpu_ioctl(filp, ioctl, arg); >> + r = kvm_arch_vcpu_async_ioctl(filp, ioctl, arg); >> + if (r != -ENOIOCTLCMD) >> + return r; >> #endif >> >> - > unrelated change but the right thing to do :) >