Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752113AbdHHIfr (ORCPT ); Tue, 8 Aug 2017 04:35:47 -0400 Received: from mx1.redhat.com ([209.132.183.28]:60770 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752069AbdHHIfp (ORCPT ); Tue, 8 Aug 2017 04:35:45 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 2A1F5822 Authentication-Results: ext-mx05.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx05.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=david@redhat.com Subject: Re: [PATCH v2 3/4] KVM: s390: implements the kvm_arch_vcpu_in_kernel() To: "Longpeng(Mike)" , pbonzini@redhat.com, rkrcmar@redhat.com Cc: agraf@suse.com, borntraeger@de.ibm.com, cohuck@redhat.com, christoffer.dall@linaro.org, marc.zyngier@arm.com, james.hogan@imgtec.com, kvm@vger.kernel.org, linux-kernel@vger.kernel.org, weidong.huang@huawei.com, arei.gonglei@huawei.com, wangxinxin.wang@huawei.com, longpeng.mike@gmail.com References: <1502165135-4784-1-git-send-email-longpeng2@huawei.com> <1502165135-4784-4-git-send-email-longpeng2@huawei.com> From: David Hildenbrand Organization: Red Hat GmbH Message-ID: Date: Tue, 8 Aug 2017 10:35:40 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <1502165135-4784-4-git-send-email-longpeng2@huawei.com> 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.29]); Tue, 08 Aug 2017 08:35:45 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 768 Lines: 29 On 08.08.2017 06:05, Longpeng(Mike) wrote: > This implements the kvm_arch_vcpu_in_kernel() for s390. > > Signed-off-by: Longpeng(Mike) > --- > arch/s390/kvm/kvm-s390.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c > index 0b0c689..e46177b 100644 > --- a/arch/s390/kvm/kvm-s390.c > +++ b/arch/s390/kvm/kvm-s390.c > @@ -2449,7 +2449,7 @@ int kvm_arch_vcpu_runnable(struct kvm_vcpu *vcpu) > > bool kvm_arch_vcpu_in_kernel(struct kvm_vcpu *vcpu) > { > - return false; > + return !(vcpu->arch.sie_block->gpsw.mask & PSW_MASK_PSTATE); > } > EXPORT_SYMBOL_GPL(kvm_arch_vcpu_in_kernel); > > Reviewed-by: David Hildenbrand -- Thanks, David