Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751962AbdHHHea (ORCPT ); Tue, 8 Aug 2017 03:34:30 -0400 Received: from mx1.redhat.com ([209.132.183.28]:52646 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750776AbdHHHe3 (ORCPT ); Tue, 8 Aug 2017 03:34:29 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com ACB5C1E2F2 Authentication-Results: ext-mx06.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx06.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=pbonzini@redhat.com Subject: Re: [PATCH v2 1/4] KVM: add spinlock optimization framework To: "Longpeng(Mike)" , 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, david@redhat.com References: <1502165135-4784-1-git-send-email-longpeng2@huawei.com> <1502165135-4784-2-git-send-email-longpeng2@huawei.com> From: Paolo Bonzini Message-ID: Date: Tue, 8 Aug 2017 09:34:14 +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-2-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.30]); Tue, 08 Aug 2017 07:34:28 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 557 Lines: 19 On 08/08/2017 06:05, Longpeng(Mike) wrote: > return 1; > diff --git a/arch/s390/kvm/diag.c b/arch/s390/kvm/diag.c > index ce865bd..4ea8c38 100644 > --- a/arch/s390/kvm/diag.c > +++ b/arch/s390/kvm/diag.c > @@ -150,7 +150,7 @@ static int __diag_time_slice_end(struct kvm_vcpu *vcpu) > { > VCPU_EVENT(vcpu, 5, "%s", "diag time slice end"); > vcpu->stat.diagnose_44++; > - kvm_vcpu_on_spin(vcpu); > + kvm_vcpu_on_spin(vcpu, kvm_arch_vcpu_in_kernel(vcpu)); > return 0; > } > IIUC, diag is a privileged instruction so this an also be "true". Paolo