Received: by 2002:a19:f614:0:0:0:0:0 with SMTP id x20csp54584lfe; Fri, 15 Apr 2022 19:10:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzHdd1r9Vfv5g2O8DB8QqTTzjpfATE/DV4ICaJ9ymnmJ0J6iIffaLMdrCEVtDpejGomDEif X-Received: by 2002:a17:902:8b8a:b0:158:983d:2689 with SMTP id ay10-20020a1709028b8a00b00158983d2689mr1697007plb.173.1650075048392; Fri, 15 Apr 2022 19:10:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650075048; cv=none; d=google.com; s=arc-20160816; b=QpgCWTlp/Y6m/AvKS0ZnCdwD12QJrA3rAdWvuTQBhpgZt9P/TsdxVbor4N5tIQVzMm gcY2TEg5Z9EDq+XuzEngk8dwVfpV6+Rt714vQWUf3HyAGzhPKKNH+gnKDRcg9gfFFgpw m5ICNLepWafA0lvp0SaHX51JyDXOEmoKJH3yXiWTvVaCZmyzHZyFfOJ/MTTll6YwnUe3 VnZ/6MV3Q5OlK/4ivRoDwr+9Fnh1WCwySwsLzc4NnHAjgUMoyBS96BQgAjF1ndwtsYel LbinRNJ+tnS3Vs9Y6Xw+vrTpS0wwUqCaBfEOqiLEL76pMeXoU/fkuukoiY1uFqxUwjj4 HqsA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:from:cc:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject :dkim-signature; bh=fGuiIocTsGNeGfljFQBqIaq8z11faA06QmkOS1ZNMsM=; b=FyMEWlwkKz/1ArhCQe4ATWLwiMsZfci8hh/isiMoweNfGxxNrcbNu5pUes+oavhUda KEgyt7Z9v1ytp/gtIYKmA+Fzz77qHa/fp5ifIFr3uwPmGZVpJ0trMzBZJLP57cg8wjNd ej2FzTjNu3Xjk86ATlFGfHaYDpgLPfW1b7o+gPo2GmjOajcNjpoabSps4lHundQ83/Ya qQ8GCQMlsHWS36z0Xp5N/T6AyN2O7hElIyJ1YWVtTUgEh7owPQUPLGhu2iGeOOYhdV4R Qs2u83ABUeGhrU8olLGMJ/tvBhRVRaL10L7AFtZNO+CoGzF1ih3MzlrZx16tznbZc+wS GfRQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@rivosinc-com.20210112.gappssmtp.com header.s=20210112 header.b=R6qB8EHj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id bq13-20020a056a000e0d00b004fa3a8dffd1si2897628pfb.136.2022.04.15.19.10.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Apr 2022 19:10:48 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@rivosinc-com.20210112.gappssmtp.com header.s=20210112 header.b=R6qB8EHj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id A115EF70C9; Fri, 15 Apr 2022 18:28:03 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1344585AbiDNWIH (ORCPT + 99 others); Thu, 14 Apr 2022 18:08:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55952 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S245265AbiDNWHq (ORCPT ); Thu, 14 Apr 2022 18:07:46 -0400 Received: from mail-pl1-x62f.google.com (mail-pl1-x62f.google.com [IPv6:2607:f8b0:4864:20::62f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E8245ADD5E for ; Thu, 14 Apr 2022 15:05:19 -0700 (PDT) Received: by mail-pl1-x62f.google.com with SMTP id d15so5795397pll.10 for ; Thu, 14 Apr 2022 15:05:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20210112.gappssmtp.com; s=20210112; h=subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding:cc:from:to; bh=fGuiIocTsGNeGfljFQBqIaq8z11faA06QmkOS1ZNMsM=; b=R6qB8EHjaJgSIdCtMKhdYuPkgsZWKZJvItsuxrvYJe66b0kWr5qEcaypbW8fVsbM0X FhUqRtspmHufGwN2FALekT8CyXJm5S7kjyMcktlGU1XrpzbtotUCXZuO87tkl8dzpRsU rD7GHFid/eI0LZmwYI/csFXmn3CvJN7DaDKvJaMLpPJ/3/P4dIfleHYvn2zvLdnkO4tP 7bShSmxTBQk2haxc2USQ9dtIjlVAIPg3bDRc+xVXDklpfpHWqfjPqU6sgkCSldEnbFhC TWJSMeobIJFf8xFLlsze9XxDtvdwjGCazEbqvvXoqURGpeC9W8m/Vt3E4JkUOM5Z3ckq eeBQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:cc:from:to; bh=fGuiIocTsGNeGfljFQBqIaq8z11faA06QmkOS1ZNMsM=; b=pdnlRWH1a04rcWAv9Lx+D2IZcQ6XkLaERU5KtCbVnBdiGo58ZvuEIP1yMDEGZ/0VIF zqduCv002V4vYdGYl/saHQS9P+7ZI1OzNImWrtjzlaY+pXDrwhWW3RJ05A8bytlwI+GF 4Bx/aEUVE8T5KggxsXbkHUjCBIdc5RncvyAg5Haovk6tcwfQETyohlYz543DNpwq1ic5 mFvsOhnJej8A3x4BBNXseoQKo7KPBC8XNi7/gLXcN8CF1qpyy2hc6/kQby0hp08oyPaB ki1yJvoOef470/205hyrC3GQYplr+Fu5Ng/mBXTT3D6fLSQ83zMEXj/VFD5JcQXe1gLB fIKw== X-Gm-Message-State: AOAM530lW8dsEFZpGruy/VdnQUEjUOM0aOM4H7sbqSEk7ZPQm1yUaVkt yEkUsvgqpBYvnNdduclnCxuz7A== X-Received: by 2002:a17:90a:4294:b0:1cd:5524:cd6a with SMTP id p20-20020a17090a429400b001cd5524cd6amr716857pjg.212.1649973919487; Thu, 14 Apr 2022 15:05:19 -0700 (PDT) Received: from localhost ([12.3.194.138]) by smtp.gmail.com with ESMTPSA id d5-20020a056a0024c500b004fae56b2921sm805319pfv.167.2022.04.14.15.05.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 14 Apr 2022 15:05:19 -0700 (PDT) Subject: [PATCH v3 4/7] openrisc: Move to ticket-spinlock Date: Thu, 14 Apr 2022 15:02:11 -0700 Message-Id: <20220414220214.24556-5-palmer@rivosinc.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220414220214.24556-1-palmer@rivosinc.com> References: <20220414220214.24556-1-palmer@rivosinc.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Cc: peterz@infradead.org, mingo@redhat.com, Will Deacon , longman@redhat.com, boqun.feng@gmail.com, jonas@southpole.se, stefan.kristiansson@saunalahti.fi, Paul Walmsley , Palmer Dabbelt , aou@eecs.berkeley.edu, Arnd Bergmann , macro@orcam.me.uk, Greg KH , sudipm.mukherjee@gmail.com, wangkefeng.wang@huawei.com, jszhang@kernel.org, linux-csky@vger.kernel.org, linux-kernel@vger.kernel.org, openrisc@lists.librecores.org, linux-riscv@lists.infradead.org, linux-arch@vger.kernel.org, Palmer Dabbelt From: Palmer Dabbelt To: Arnd Bergmann , heiko@sntech.de, guoren@kernel.org, shorne@gmail.com X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RDNS_NONE, SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Peter Zijlstra We have no indications that openrisc meets the qspinlock requirements, so move to ticket-spinlock as that is more likey to be correct. Signed-off-by: Peter Zijlstra (Intel) Signed-off-by: Palmer Dabbelt --- arch/openrisc/Kconfig | 1 - arch/openrisc/include/asm/Kbuild | 5 ++-- arch/openrisc/include/asm/spinlock.h | 27 ---------------------- arch/openrisc/include/asm/spinlock_types.h | 7 ------ 4 files changed, 2 insertions(+), 38 deletions(-) delete mode 100644 arch/openrisc/include/asm/spinlock.h delete mode 100644 arch/openrisc/include/asm/spinlock_types.h diff --git a/arch/openrisc/Kconfig b/arch/openrisc/Kconfig index 0d68adf6e02b..99f0e4a4cbbd 100644 --- a/arch/openrisc/Kconfig +++ b/arch/openrisc/Kconfig @@ -30,7 +30,6 @@ config OPENRISC select HAVE_DEBUG_STACKOVERFLOW select OR1K_PIC select CPU_NO_EFFICIENT_FFS if !OPENRISC_HAVE_INST_FF1 - select ARCH_USE_QUEUED_SPINLOCKS select ARCH_USE_QUEUED_RWLOCKS select OMPIC if SMP select ARCH_WANT_FRAME_POINTERS diff --git a/arch/openrisc/include/asm/Kbuild b/arch/openrisc/include/asm/Kbuild index ca5987e11053..3386b9c1c073 100644 --- a/arch/openrisc/include/asm/Kbuild +++ b/arch/openrisc/include/asm/Kbuild @@ -1,9 +1,8 @@ # SPDX-License-Identifier: GPL-2.0 generic-y += extable.h generic-y += kvm_para.h -generic-y += mcs_spinlock.h -generic-y += qspinlock_types.h -generic-y += qspinlock.h +generic-y += spinlock_types.h +generic-y += spinlock.h generic-y += qrwlock_types.h generic-y += qrwlock.h generic-y += user.h diff --git a/arch/openrisc/include/asm/spinlock.h b/arch/openrisc/include/asm/spinlock.h deleted file mode 100644 index 264944a71535..000000000000 --- a/arch/openrisc/include/asm/spinlock.h +++ /dev/null @@ -1,27 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0-or-later */ -/* - * OpenRISC Linux - * - * Linux architectural port borrowing liberally from similar works of - * others. All original copyrights apply as per the original source - * declaration. - * - * OpenRISC implementation: - * Copyright (C) 2003 Matjaz Breskvar - * Copyright (C) 2010-2011 Jonas Bonn - * et al. - */ - -#ifndef __ASM_OPENRISC_SPINLOCK_H -#define __ASM_OPENRISC_SPINLOCK_H - -#include - -#include - -#define arch_spin_relax(lock) cpu_relax() -#define arch_read_relax(lock) cpu_relax() -#define arch_write_relax(lock) cpu_relax() - - -#endif diff --git a/arch/openrisc/include/asm/spinlock_types.h b/arch/openrisc/include/asm/spinlock_types.h deleted file mode 100644 index 7c6fb1208c88..000000000000 --- a/arch/openrisc/include/asm/spinlock_types.h +++ /dev/null @@ -1,7 +0,0 @@ -#ifndef _ASM_OPENRISC_SPINLOCK_TYPES_H -#define _ASM_OPENRISC_SPINLOCK_TYPES_H - -#include -#include - -#endif /* _ASM_OPENRISC_SPINLOCK_TYPES_H */ -- 2.34.1