From patchwork Tue Apr 16 18:43:58 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Atish Kumar Patra X-Patchwork-Id: 13632507 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 20BBDC04FF6 for ; Tue, 16 Apr 2024 19:46:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=pcWzbko5etKI/gj6JSy/DihJjl91r5gUiHLnbmnLo1E=; b=sFM/9vspbrp8PN HSFPICtpe4j8yC8kJ6xinw6rlQMHEWv5RB0yV4ImFDp4QWDmWQRUEFPNsXKaqFvHfUMWknmNv5c2g D4EhfccQGnB7k7CvHXoDTV7WsFazeMtKegIw9ar5bJUDO7/WYkY3yu+4eGiI8vqFYQ6ftn0E63Mes DwObz7fWAqvdkVpFm0DO5i1Zt4/17BH4U1OySTUB1d2+J1nr10OOVtoaPLZ0b/losRxn8oMYK1byC /iyDCZzaaClfxgCasUD9d7vXtAFsb6HIT/lviQTql1ACobnYGqhxfHiigTsR/aKmR/tYWcOMwFxsM qmU7H1g7c1BGdWPIT+Dg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rwoke-0000000Daeg-15Jo; Tue, 16 Apr 2024 19:45:56 +0000 Received: from mail-pf1-x42f.google.com ([2607:f8b0:4864:20::42f]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rwnnP-0000000DMBn-3cxP for linux-riscv@lists.infradead.org; Tue, 16 Apr 2024 18:44:49 +0000 Received: by mail-pf1-x42f.google.com with SMTP id d2e1a72fcca58-6ed2170d89fso32288b3a.1 for ; Tue, 16 Apr 2024 11:44:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20230601.gappssmtp.com; s=20230601; t=1713293083; x=1713897883; darn=lists.infradead.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=T1oS0ksNazYXtVOBgFTjTYlhVVLdg1h0owq7BrHVbdc=; b=C8kDdGE05ZqTaZGqoNdw7k9065ai7DSfMuLwVqQkdJq8I0Am0yY6PJYYBj8RcoBTR7 o/sQEKXn9NB6BYaZxwxXzAqUOeWxKVGwgsitlYvtxXICiv2umnIEpgZTQS96j+v3j6Q7 PuqI3qoZp5/i4T8ReI4wTmOoV/igww943KBNH8OsUb3f9Kax14N+tidvOz87Q0UyEB11 Sv4uCIN9cLeHwHjai2RRjd8rN8IE0i18cgs7agQkKUwJhTxWAkNDy/qjNgNSCQZw8ZhF 5Zxh0723eLxihNZoNtPG27q0+T0vQp0UBH7hGK+KHgm/QjaDfXT9gEn6Ml70yvXSssfZ XCeA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1713293083; x=1713897883; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=T1oS0ksNazYXtVOBgFTjTYlhVVLdg1h0owq7BrHVbdc=; b=hZ2IkUYYe2AfTZwcjMX8ZftwDguM7vTInaqsTG2q+wjWiWK3F7l6t1S02/NMhYxiS6 f941U2nk9Jid0NPvQcA32pzxsnCBu+1MXmQWzeOMdoGBrm6+JsOenkzYhlwmcyMC/aR3 5mOKko7gxgWwiKf5wZ2MPdfqIX11JErSaQbfLvEIwHZ2VsQTduQg+hZga5bhvQuy2LaX ifJoNJUyYz7PvrAWQBK+Xr0AxCi8bXSB9xDlGeOj7AnXdqQ0abKH4v9jHZSBTzhs4G+W x+UhVCRfC42KGncUd649eIInb6X7njimaC6DYXZ1chy/TTJFRqrcI5gttCqJjvciBakl wfiw== X-Forwarded-Encrypted: i=1; AJvYcCXKuEouWlR4XE3201KC4x8pQ79AbuAeyJLgyA+JnS1sGqvin6eKhR4PQbnBhP9GZIELFsZiVcM/pADjWLjuUg93arAhU6aJm/ORdgR1yHD2 X-Gm-Message-State: AOJu0YxJ1T9Q2zfGuigs5X0Mvem0f9ZD4AGoIbgUgIrYTH5xdii21qUQ ZF2DQ8L5Zs4z5ySgEOQ/VmfnXWsgqkx8q2BQSHncN88f2x+vQ9uDyC94lvqta4o= X-Google-Smtp-Source: AGHT+IFCEO++RSNi2s4BPgY/cFtIWMTnHZE2PMfQmZHO7SJaFE1gAV8eT+53+kwpYpGgaU41aAh/DA== X-Received: by 2002:a17:90a:7c06:b0:2a2:7494:15df with SMTP id v6-20020a17090a7c0600b002a2749415dfmr4080891pjf.9.1713293082701; Tue, 16 Apr 2024 11:44:42 -0700 (PDT) Received: from atishp.ba.rivosinc.com ([64.71.180.162]) by smtp.gmail.com with ESMTPSA id o19-20020a17090aac1300b002a269828bb8sm8883645pjq.40.2024.04.16.11.44.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 16 Apr 2024 11:44:42 -0700 (PDT) From: Atish Patra To: linux-kernel@vger.kernel.org Cc: Atish Patra , =?utf-8?b?Q2zDqW1lbnQgTMOpZ2Vy?= , Conor Dooley , Anup Patel , Andrew Jones , Ajay Kaher , Albert Ou , Alexandre Ghiti , Juergen Gross , kvm-riscv@lists.infradead.org, kvm@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-riscv@lists.infradead.org, Mark Rutland , Palmer Dabbelt , Paolo Bonzini , Paul Walmsley , Shuah Khan , virtualization@lists.linux.dev, Will Deacon , x86@kernel.org Subject: [PATCH v7 01/24] RISC-V: Fix the typo in Scountovf CSR name Date: Tue, 16 Apr 2024 11:43:58 -0700 Message-Id: <20240416184421.3693802-2-atishp@rivosinc.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240416184421.3693802-1-atishp@rivosinc.com> References: <20240416184421.3693802-1-atishp@rivosinc.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240416_114444_201368_F7C86727 X-CRM114-Status: GOOD ( 10.98 ) X-BeenThere: linux-riscv@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-riscv" Errors-To: linux-riscv-bounces+linux-riscv=archiver.kernel.org@lists.infradead.org The counter overflow CSR name is "scountovf" not "sscountovf". Fix the csr name. Fixes: 4905ec2fb7e6 ("RISC-V: Add sscofpmf extension support") Reviewed-by: Clément Léger Reviewed-by: Conor Dooley Reviewed-by: Anup Patel Reviewed-by: Andrew Jones Signed-off-by: Atish Patra --- arch/riscv/include/asm/csr.h | 2 +- drivers/perf/riscv_pmu_sbi.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/riscv/include/asm/csr.h b/arch/riscv/include/asm/csr.h index 2468c55933cd..9d1b07932794 100644 --- a/arch/riscv/include/asm/csr.h +++ b/arch/riscv/include/asm/csr.h @@ -281,7 +281,7 @@ #define CSR_HPMCOUNTER30H 0xc9e #define CSR_HPMCOUNTER31H 0xc9f -#define CSR_SSCOUNTOVF 0xda0 +#define CSR_SCOUNTOVF 0xda0 #define CSR_SSTATUS 0x100 #define CSR_SIE 0x104 diff --git a/drivers/perf/riscv_pmu_sbi.c b/drivers/perf/riscv_pmu_sbi.c index 8cbe6e5f9c39..3e44d2fb8bf8 100644 --- a/drivers/perf/riscv_pmu_sbi.c +++ b/drivers/perf/riscv_pmu_sbi.c @@ -27,7 +27,7 @@ #define ALT_SBI_PMU_OVERFLOW(__ovl) \ asm volatile(ALTERNATIVE_2( \ - "csrr %0, " __stringify(CSR_SSCOUNTOVF), \ + "csrr %0, " __stringify(CSR_SCOUNTOVF), \ "csrr %0, " __stringify(THEAD_C9XX_CSR_SCOUNTEROF), \ THEAD_VENDOR_ID, ERRATA_THEAD_PMU, \ CONFIG_ERRATA_THEAD_PMU, \