From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.0 required=3.0 tests=DATE_IN_PAST_12_24, DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, UNPARSEABLE_RELAY,USER_AGENT_GIT autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 65091ECE58B for ; Fri, 4 Oct 2019 14:00:09 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 3BFC320700 for ; Fri, 4 Oct 2019 14:00:09 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=oracle.com header.i=@oracle.com header.b="rbs/CGdo" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388935AbfJDOAI (ORCPT ); Fri, 4 Oct 2019 10:00:08 -0400 Received: from userp2130.oracle.com ([156.151.31.86]:37942 "EHLO userp2130.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388197AbfJDOAI (ORCPT ); Fri, 4 Oct 2019 10:00:08 -0400 Received: from pps.filterd (userp2130.oracle.com [127.0.0.1]) by userp2130.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x94Ds1h6024269; Fri, 4 Oct 2019 13:58:08 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id; s=corp-2019-08-05; bh=W0qjKQg1B8u+RNi8nWbMKhDrA5TAne7U2vWQ/Wl2O1U=; b=rbs/CGdoD+Zf9ZZ4jL/5e7B5Frua/hPsRtXH1pf2kv3ySrsOXnZe0wkMuCNBI+3vY/2P +TcQhJaeanKqKsecuA1ZtSjgxeqG2U0iR6Atii9nykd1b2d4ymdKKhz5wUOofkovgIJo fVhxE5mv/cg/1f4CYHHLS6xWJJgnk4u5H80VavIDrGUCP8JOiJ119BHx/8aqzvXFkIOH tiAxTJN4rTn0863rasD+zPaqcJSsMHuRJVCodtfP6V9y3VWeo7+iJpvGqZ7zgVL9+KJZ Dn6tEDUaWpRKHT/gQNrPy2bq60LwBIVEfwMYCHJpGQSUjZ8UL5lLj/P4Me6q+6W02dkQ CQ== Received: from userp3030.oracle.com (userp3030.oracle.com [156.151.31.80]) by userp2130.oracle.com with ESMTP id 2v9xxvbq8k-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 04 Oct 2019 13:58:08 +0000 Received: from pps.filterd (userp3030.oracle.com [127.0.0.1]) by userp3030.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x94DrNJv009193; Fri, 4 Oct 2019 13:58:08 GMT Received: from aserv0121.oracle.com (aserv0121.oracle.com [141.146.126.235]) by userp3030.oracle.com with ESMTP id 2vdn19tpwd-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 04 Oct 2019 13:58:06 +0000 Received: from abhmp0011.oracle.com (abhmp0011.oracle.com [141.146.116.17]) by aserv0121.oracle.com (8.14.4/8.13.8) with ESMTP id x94Dvubq011560; Fri, 4 Oct 2019 13:57:59 GMT Received: from z2.cn.oracle.com (/10.182.71.205) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Fri, 04 Oct 2019 06:57:55 -0700 From: Zhenzhong Duan To: linux-kernel@vger.kernel.org Cc: vkuznets@redhat.com, linux-hyperv@vger.kernel.org, kvm@vger.kernel.org, kys@microsoft.com, haiyangz@microsoft.com, sthemmin@microsoft.com, sashal@kernel.org, tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, pbonzini@redhat.com, rkrcmar@redhat.com, sean.j.christopherson@intel.com, wanpengli@tencent.com, jmattson@google.com, joro@8bytes.org, boris.ostrovsky@oracle.com, jgross@suse.com, sstabellini@kernel.org, peterz@infradead.org, Zhenzhong Duan Subject: [PATCH v4 0/4] Add a unified parameter "nopvspin" Date: Thu, 3 Oct 2019 22:02:11 +0800 Message-Id: <1570111335-12731-1-git-send-email-zhenzhong.duan@oracle.com> X-Mailer: git-send-email 1.8.3.1 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9399 signatures=668684 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=1 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1908290000 definitions=main-1910040130 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9399 signatures=668684 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=1 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1908290000 definitions=main-1910040130 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org There are cases folks want to disable spinlock optimization for debug/test purpose. Xen and hyperv already have parameters "xen_nopvspin" and "hv_nopvspin" to support that, but kvm doesn't. The first patch adds that feature to KVM guest with "nopvspin". For compatibility reason original parameters "xen_nopvspin" and "hv_nopvspin" are retained and marked obsolete. v4: PATCH1: use variable name nopvspin instead of pvspin and defined it as __initdata, changed print message, updated patch description [Sean Christopherson] PATCH2: remove Suggested-by, use "kvm-guest:" prefix [Sean Christopherson] PATCH3: make variable nopvsin and xen_pvspin coexist remove Reviewed-by due to code change [Sean Christopherson] PATCH4: make variable nopvsin and hv_pvspin coexist [Sean Christopherson] v3: PATCH2: Fix indentation v2: PATCH1: pick the print code change into separate PATCH2, updated patch description [Vitaly Kuznetsov] PATCH2: new patch with print code change [Vitaly Kuznetsov] PATCH3: add Reviewed-by [Juergen Gross] Zhenzhong Duan (4): x86/kvm: Add "nopvspin" parameter to disable PV spinlocks x86/kvm: Change print code to use pr_*() format xen: Mark "xen_nopvspin" parameter obsolete x86/hyperv: Mark "hv_nopvspin" parameter obsolete Documentation/admin-guide/kernel-parameters.txt | 14 ++++++- arch/x86/hyperv/hv_spinlock.c | 4 ++ arch/x86/include/asm/qspinlock.h | 1 + arch/x86/kernel/kvm.c | 51 +++++++++++++++---------- arch/x86/xen/spinlock.c | 3 ++ kernel/locking/qspinlock.c | 7 ++++ 6 files changed, 57 insertions(+), 23 deletions(-) -- 1.8.3.1