Received: by 2002:a05:6a10:eb17:0:0:0:0 with SMTP id hx23csp1732338pxb; Fri, 10 Sep 2021 12:30:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw4nRYMO05sIF6Vvwa14+/WZWIlXpDczsWaWzei07szVsixm2AxWAwzpPQCwZiNnt89znJm X-Received: by 2002:a92:c091:: with SMTP id h17mr7457976ile.286.1631302250914; Fri, 10 Sep 2021 12:30:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631302250; cv=none; d=google.com; s=arc-20160816; b=RF+KG1yzmq0NH0CUdeYT3tRlVM7SFEuePbS12280ssLNRUMtKIuO4IU188fSL9l0MC FxCeVz+X6/8BT8yvxP2UXxEbbib9em4QJce7VyGfITppJo0mqdlXVkSy8k9Hk+FCdWVk T3zMeRXOsfItqt5eNyHncqa9CPKPAlFVtzyJg2ZOtpe0h+DQgow4W9fxbz073fSECooc yayioayJIQ6Z4l+DSUc0VPs+G/Ow4rBy+24e5dMLqDsQ4XBrCtb3nh4GsH45j4qcEXQo Uvkv00hBP94ydYN9UOcIKa4Udb4AF+LWNQJXBoKCP23lQyYdxNSrzWA0DwLyHiJv1hva 42ZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :wdcironportexception:ironport-sdr:ironport-sdr:dkim-signature; bh=eeQatv/AADJbWe/qPPi6wbCb6/MAA/QnJ/0l/fMJ4us=; b=qtuF74axTC2GJJdd36DcZB91SpoCRer/hPEbRtJF6KQ5r51LeBgb/gYObaQpQ5X72/ bnMcW4FWZTTNzWUDvhfQ8vslV9f6fjOEik7br0QVdLBNy9nIYjudogBFQPAr23Rd7GKE zsGVjPJZ9gLcpYoLJM1nyyrBiKF334yQS1DvkBGYoyoJGcaRILEUvyFt4PQQF5gZQHd7 zhPN8tx+D71BoB8jm8siBPFTFgfSWiQLjfEFUKC9RZ3fA0XHZCv+wZBvYQ7o2OHnQFDx TXlsT+V0RxNlZe3iy6Iej62X+qpl+i+ilsTYcqtc5FqjgNk6y9VvtDhdq5H97B+sPMaA 3t5g== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@wdc.com header.s=dkim.wdc.com header.b=qZerMyuc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=wdc.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w13si6346742ilu.26.2021.09.10.12.30.35; Fri, 10 Sep 2021 12:30:50 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@wdc.com header.s=dkim.wdc.com header.b=qZerMyuc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=wdc.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233672AbhIJT3y (ORCPT + 99 others); Fri, 10 Sep 2021 15:29:54 -0400 Received: from esa5.hgst.iphmx.com ([216.71.153.144]:29550 "EHLO esa5.hgst.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232430AbhIJT3d (ORCPT ); Fri, 10 Sep 2021 15:29:33 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1631302101; x=1662838101; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=GO7omq3rVi+V+CzKbzcTcJGYp29gXK/DeiBhKM0seGs=; b=qZerMyucJD+6VT/18+gN/JC9k1+Is55YBg4g0Bb3LQRy+bSrG+ElEmmE 3oqnVkCjrvIYarqQWZ8adnFw0GgN+MDvAiOuz8NZ5zLlLpsrS/vlzTgOZ 2+SgV42np8wjenJefVap4G5eg/eltkDw+0u80wFYaNe0UoO6xRBZsYDPz jqiWLpXbp3xo2V4tC2lZYp/ljAALU0Nl2G1VXmCQYffwIyDxkgW+4InRy 4+fJysfic0VchFTcvz1HVUWWmO/PxgeG2Fc+MPirIraab0Okr4zq80Yf5 PKLRQ23jO2o//MpRpG8QTrcV8PsBIq0UoRC2JbRD7wZA8cyp2RgSpUBVJ g==; X-IronPort-AV: E=Sophos;i="5.85,283,1624291200"; d="scan'208";a="179706171" Received: from h199-255-45-15.hgst.com (HELO uls-op-cesaep02.wdc.com) ([199.255.45.15]) by ob1.hgst.iphmx.com with ESMTP; 11 Sep 2021 03:28:19 +0800 IronPort-SDR: rWkAUIA7EYvSa9t2N7ELO9idCj9yW8V1Xw6mj7c7qC08J1+j3z2I9e4avGhK3uKiQuFMlFacWC h9LIofBNPT6suAdTsqjAZmFhSLszC4rxHCRBB3tGwVuWPQWSa4bKyPXOSAYslCeh8C3PZT3J+y 5kVu/KBp1weRjhkpe1Jtf26BiBEj2f2K2/Z+W6LpRIKHRRTErhcstm1le5O/PdppZHyVL9idmf 6cmYXPM8zZNHalqhMZPekwzVfpXiUTtbb8sg+6Qe/OAX1xP5hIYGb0yBsshil61LyzMnEZHWTt 1WrIDKnMJhNE4Vnhee95A0wF Received: from uls-op-cesaip01.wdc.com ([10.248.3.36]) by uls-op-cesaep02.wdc.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 Sep 2021 12:03:14 -0700 IronPort-SDR: Pi5w3WBSwQLpYocu6+1OCZR4qfNgdu33q8ZyZCDQmT6KaBuyr7NQd/pmCPqgFxHF0ggFXPqWPI 1XWIXvtzgstTo2WYEzTBzJpELtB42UivH9fcusm3D0USH7yscN3XlCc2rnBVqP0FoMGubfyqb7 NJD3uXeaWgrNKAIMsruMovMkq6SlZHHqVlmBm8FnN2REzSbOrdR4j7i1qtboo2oIOhkBazpQvb iL/OeYzGN+A/Lu/u6pzCtgREIkRcMYFlcmUZPeiwXAFwfqlTvJ91wtitQSNerq5/88AZHzSBGe Yqc= WDCIronportException: Internal Received: from unknown (HELO hulk.wdc.com) ([10.225.167.73]) by uls-op-cesaip01.wdc.com with ESMTP; 10 Sep 2021 12:28:20 -0700 From: Atish Patra To: linux-kernel@vger.kernel.org Cc: Atish Patra , Alexander Shishkin , Anup Patel , Ard Biesheuvel , "Darrick J. Wong" , devicetree@vger.kernel.org, Guo Ren , Heinrich Schuchardt , Jiri Olsa , John Garry , Jonathan Corbet , linux-doc@vger.kernel.org, linux-perf-users@vger.kernel.org, linux-riscv@lists.infradead.org, Nick Kossifidis , Palmer Dabbelt , Paul Walmsley , Rob Herring , Vincent Chen Subject: [v3 02/10] RISC-V: Add CSR encodings for all HPMCOUNTERS Date: Fri, 10 Sep 2021 12:27:49 -0700 Message-Id: <20210910192757.2309100-3-atish.patra@wdc.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210910192757.2309100-1-atish.patra@wdc.com> References: <20210910192757.2309100-1-atish.patra@wdc.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Signed-off-by: Atish Patra --- arch/riscv/include/asm/csr.h | 58 ++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) diff --git a/arch/riscv/include/asm/csr.h b/arch/riscv/include/asm/csr.h index 87ac65696871..e4d369830af4 100644 --- a/arch/riscv/include/asm/csr.h +++ b/arch/riscv/include/asm/csr.h @@ -89,9 +89,67 @@ #define CSR_CYCLE 0xc00 #define CSR_TIME 0xc01 #define CSR_INSTRET 0xc02 +#define CSR_HPMCOUNTER3 0xc03 +#define CSR_HPMCOUNTER4 0xc04 +#define CSR_HPMCOUNTER5 0xc05 +#define CSR_HPMCOUNTER6 0xc06 +#define CSR_HPMCOUNTER7 0xc07 +#define CSR_HPMCOUNTER8 0xc08 +#define CSR_HPMCOUNTER9 0xc09 +#define CSR_HPMCOUNTER10 0xc0a +#define CSR_HPMCOUNTER11 0xc0b +#define CSR_HPMCOUNTER12 0xc0c +#define CSR_HPMCOUNTER13 0xc0d +#define CSR_HPMCOUNTER14 0xc0e +#define CSR_HPMCOUNTER15 0xc0f +#define CSR_HPMCOUNTER16 0xc10 +#define CSR_HPMCOUNTER17 0xc11 +#define CSR_HPMCOUNTER18 0xc12 +#define CSR_HPMCOUNTER19 0xc13 +#define CSR_HPMCOUNTER20 0xc14 +#define CSR_HPMCOUNTER21 0xc15 +#define CSR_HPMCOUNTER22 0xc16 +#define CSR_HPMCOUNTER23 0xc17 +#define CSR_HPMCOUNTER24 0xc18 +#define CSR_HPMCOUNTER25 0xc19 +#define CSR_HPMCOUNTER26 0xc1a +#define CSR_HPMCOUNTER27 0xc1b +#define CSR_HPMCOUNTER28 0xc1c +#define CSR_HPMCOUNTER29 0xc1d +#define CSR_HPMCOUNTER30 0xc1e +#define CSR_HPMCOUNTER31 0xc1f #define CSR_CYCLEH 0xc80 #define CSR_TIMEH 0xc81 #define CSR_INSTRETH 0xc82 +#define CSR_HPMCOUNTER3H 0xc83 +#define CSR_HPMCOUNTER4H 0xc84 +#define CSR_HPMCOUNTER5H 0xc85 +#define CSR_HPMCOUNTER6H 0xc86 +#define CSR_HPMCOUNTER7H 0xc87 +#define CSR_HPMCOUNTER8H 0xc88 +#define CSR_HPMCOUNTER9H 0xc89 +#define CSR_HPMCOUNTER10H 0xc8a +#define CSR_HPMCOUNTER11H 0xc8b +#define CSR_HPMCOUNTER12H 0xc8c +#define CSR_HPMCOUNTER13H 0xc8d +#define CSR_HPMCOUNTER14H 0xc8e +#define CSR_HPMCOUNTER15H 0xc8f +#define CSR_HPMCOUNTER16H 0xc90 +#define CSR_HPMCOUNTER17H 0xc91 +#define CSR_HPMCOUNTER18H 0xc92 +#define CSR_HPMCOUNTER19H 0xc93 +#define CSR_HPMCOUNTER20H 0xc94 +#define CSR_HPMCOUNTER21H 0xc95 +#define CSR_HPMCOUNTER22H 0xc96 +#define CSR_HPMCOUNTER23H 0xc97 +#define CSR_HPMCOUNTER24H 0xc98 +#define CSR_HPMCOUNTER25H 0xc99 +#define CSR_HPMCOUNTER26H 0xc9a +#define CSR_HPMCOUNTER27H 0xc9b +#define CSR_HPMCOUNTER28H 0xc9c +#define CSR_HPMCOUNTER29H 0xc9d +#define CSR_HPMCOUNTER30H 0xc9e +#define CSR_HPMCOUNTER31H 0xc9f #define CSR_SSTATUS 0x100 #define CSR_SIE 0x104 -- 2.31.1