From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S935546AbcI3FEM (ORCPT ); Fri, 30 Sep 2016 01:04:12 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:34484 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932469AbcI3FED (ORCPT ); Fri, 30 Sep 2016 01:04:03 -0400 Subject: Re: [PATCH v3 0/4] implement vcpu preempted check To: Peter Zijlstra , Christian Borntraeger References: <1469101514-49475-1-git-send-email-xinhui.pan@linux.vnet.ibm.com> <20160929101040.GV5016@twins.programming.kicks-ass.net> <166f3bad-f700-4624-6c1c-996f90ad609c@de.ibm.com> <20160929103133.GW5016@twins.programming.kicks-ass.net> Cc: Pan Xinhui , linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, virtualization@lists.linux-foundation.org, linux-s390@vger.kernel.org, xen-devel-request@lists.xenproject.org, kvm@vger.kernel.org, benh@kernel.crashing.org, paulus@samba.org, mpe@ellerman.id.au, mingo@redhat.com, paulmck@linux.vnet.ibm.com, will.deacon@arm.com, kernellwp@gmail.com, jgross@suse.com, pbonzini@redhat.com, bsingharora@gmail.com, Heiko Carstens From: Pan Xinhui Date: Fri, 30 Sep 2016 13:03:34 +0800 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: <20160929103133.GW5016@twins.programming.kicks-ass.net> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-TM-AS-GCONF: 00 X-Content-Scanned: Fidelis XPS MAILER x-cbid: 16093005-0040-0000-0000-000001780D4A X-IBM-SpamModules-Scores: X-IBM-SpamModules-Versions: BY=3.00005828; HX=3.00000240; KW=3.00000007; PH=3.00000004; SC=3.00000186; SDB=6.00762957; UDB=6.00363737; IPR=6.00538079; BA=6.00004771; NDR=6.00000001; ZLA=6.00000005; ZF=6.00000009; ZB=6.00000000; ZP=6.00000000; ZH=6.00000000; ZU=6.00000002; MB=3.00012827; XFM=3.00000011; UTC=2016-09-30 05:03:47 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 16093005-0041-0000-0000-0000056B207B Message-Id: <496ba299-1f1d-e98b-7827-f861eeea5558@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2016-09-30_01:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1609280000 definitions=main-1609300092 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 在 2016/9/29 18:31, Peter Zijlstra 写道: > On Thu, Sep 29, 2016 at 12:23:19PM +0200, Christian Borntraeger wrote: >> On 09/29/2016 12:10 PM, Peter Zijlstra wrote: >>> On Thu, Jul 21, 2016 at 07:45:10AM -0400, Pan Xinhui wrote: >>>> change from v2: >>>> no code change, fix typos, update some comments >>>> >>>> change from v1: >>>> a simplier definition of default vcpu_is_preempted >>>> skip mahcine type check on ppc, and add config. remove dedicated macro. >>>> add one patch to drop overload of rwsem_spin_on_owner and mutex_spin_on_owner. >>>> add more comments >>>> thanks boqun and Peter's suggestion. >>>> >>>> This patch set aims to fix lock holder preemption issues. >>> >>> So I really like the concept, but I would also really like to see >>> support for more hypervisors included before we can move forward with >>> this. >>> >>> Please consider s390 and (x86/arm) KVM. Once we have a few, more can >>> follow later, but I think its important to not only have PPC support for >>> this. >> >> Actually the s390 preemted check via sigp sense running is available for >> all hypervisors (z/VM, LPAR and KVM) which implies everywhere as you can no >> longer buy s390 systems without LPAR. >> >> As Heiko already pointed out we could simply use a small inline function >> that calls cpu_is_preempted from arch/s390/lib/spinlock (or smp_vcpu_scheduled from smp.c) > > Sure, and I had vague memories of Heiko's email. This patch set however > completely fails to do that trivial hooking up. > sorry for that. I will try to work it out on x86. Hi, Will I appreciate that if you or some other arm guys could help on it. :)