Message ID | 20240217005738.3744121-19-atishp@rivosinc.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel+bounces-69615-ouuuleilei=gmail.com@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:693c:2685:b0:108:e6aa:91d0 with SMTP id mn5csp88763dyc; Fri, 16 Feb 2024 17:14:23 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCUQg/wIFF9HPUwhtiJmWEH7Me3HGVdxkC7z0cb9rEENkIPHnRZ08ocuHGN36P8Vm7u+sSvaQ5q42GMkqIpMF0jtq+T5pQ== X-Google-Smtp-Source: AGHT+IHiU9f71r4xxxaLnLvQrqa6Ab5J0YLxpUWxe9bKQOT31PbXSsuQuUyLb+Ya5rcQJmxQOkR9 X-Received: by 2002:a05:6358:1093:b0:178:f497:ab3f with SMTP id j19-20020a056358109300b00178f497ab3fmr6357259rwi.14.1708132463455; Fri, 16 Feb 2024 17:14:23 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708132463; cv=pass; d=google.com; s=arc-20160816; b=g2hNOIVurj5AfwIAcDjV3j9fcD7nuUrwO719t6pZAw0ifA2h+rX1U/LqbHJMqpEtAt /6+jd9Xrqi1WVlF7xB22QH8QeiETnKI0UW72ZOFDu0PER7CxIymOu+FRk4k/SSBE63a6 9CmBjABch3X64nBsysL89e1y7xphOjF8QnETT4AWK94cEizwN2H5f10RBbkqxUEXlapA 2pIOs5LaafXOQ9AA8qb2qZeO5Nucallmthb9SvYarr2habXSE/Ytgx9Udlp8NfKfGjyC Zbg6t3I4GzO2coqI+CPhHeXDf6WKBnvW6960tPM0P1T9WaXWyHVQTDkHLUEU+dg3xk3Y A9xQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=cWbguiNHtTSYUYCLfEbpuKVHcWVD1RqHX9iqh/aIsVE=; fh=VCn6lt55QOKjzv0Hbz5VO3vbW0BxeXx0oGBGk4MoX4I=; b=ThNBAgVXbH1I84dYHA5iUXXdZWugiORafdsgCptnyPRZ1IBOeUdfkDuBkP9+xzaALu t8810q+n8mA0ErmoGIq25jdWz8FncO8bc823lQM6cmXtcu36iCv8kDx6mK8XFk9GQEgT FoAf6AAtnFhY24FbH00J6Y0KoCXTaxcElqsUBWRGrn8XemiAa+WTFfz8J5+BS1/LYa4x A7XRJxLDS8VJlussPL7KGe9ELxlIhk4dCwQOhiee5/gL+Ky8A/ZkzDg8T1Aj3QmI7HBL XR2JeO4421pQ2Ig/wmvpUPF7/LHKxNQtzqJITf8B6zCJKlJ6DbzGa1RtqfqLyY+8jz1H n2gw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@rivosinc-com.20230601.gappssmtp.com header.s=20230601 header.b=15b4Ycma; arc=pass (i=1 spf=pass spfdomain=rivosinc.com dkim=pass dkdomain=rivosinc-com.20230601.gappssmtp.com); spf=pass (google.com: domain of linux-kernel+bounces-69615-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-69615-ouuuleilei=gmail.com@vger.kernel.org" Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id x22-20020a63b216000000b005dc3694a2f9si697971pge.659.2024.02.16.17.14.23 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 16 Feb 2024 17:14:23 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-69615-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@rivosinc-com.20230601.gappssmtp.com header.s=20230601 header.b=15b4Ycma; arc=pass (i=1 spf=pass spfdomain=rivosinc.com dkim=pass dkdomain=rivosinc-com.20230601.gappssmtp.com); spf=pass (google.com: domain of linux-kernel+bounces-69615-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-69615-ouuuleilei=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 2211AB2438E for <ouuuleilei@gmail.com>; Sat, 17 Feb 2024 01:06:14 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 3A3D83D397; Sat, 17 Feb 2024 00:59:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=rivosinc-com.20230601.gappssmtp.com header.i=@rivosinc-com.20230601.gappssmtp.com header.b="15b4Ycma" Received: from mail-il1-f180.google.com (mail-il1-f180.google.com [209.85.166.180]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 51EB237707 for <linux-kernel@vger.kernel.org>; Sat, 17 Feb 2024 00:59:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.166.180 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708131545; cv=none; b=KzMiPbeCR0wXlxbxb7Gi7AKiTxTs1KQN5WXgzENqTanTMU1vH6HqLsQrARg6m5izQyT8ZV/4LHGYJtijRGbuwwz5p0Ydn+arrP8wkFchzYShC7jdKcIP3pfsszEQbfv8Bscx7AUBHshNaLlae/SDe2NfSbRS+agzkonNr75wq8Y= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708131545; c=relaxed/simple; bh=6lKVIYDNOU41w+9SFv6M4hQwtiitlAdvXeYzgOV4WlM=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=us3+AWSv6U1mK6v/29FffI8uGJ3AWszqvcwWiS+hIYJg31C+HyKF/hTh1hyed28IWnRDTAiphbtA1T0a+xOMN5Nff77cIq1xpaBf3SMbgTUHeC+04m5Sbi9rplN9R8QqvH3JIJTlBGYoRaY6z+p1t4rU8JIKG0/P/4I44Guc6QY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=rivosinc.com; spf=pass smtp.mailfrom=rivosinc.com; dkim=pass (2048-bit key) header.d=rivosinc-com.20230601.gappssmtp.com header.i=@rivosinc-com.20230601.gappssmtp.com header.b=15b4Ycma; arc=none smtp.client-ip=209.85.166.180 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=rivosinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=rivosinc.com Received: by mail-il1-f180.google.com with SMTP id e9e14a558f8ab-36423c819a3so11324905ab.0 for <linux-kernel@vger.kernel.org>; Fri, 16 Feb 2024 16:59:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20230601.gappssmtp.com; s=20230601; t=1708131541; x=1708736341; darn=vger.kernel.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=cWbguiNHtTSYUYCLfEbpuKVHcWVD1RqHX9iqh/aIsVE=; b=15b4YcmaldKJshPz118OunfDLwsP68dHf26xNv+QRH7EHSkD/a4dQMd3lxOmIpzWbw dDhe/1YYq2h6WbKci7g6ZiT0Req8DeXWw/tEaHptSwa2kFKzhg9KZL5GKY6Zr4FGeCq/ iyvRQg3+7Ffua5lUIk43wLR0mBsif0RTk1oxmqzaytwApLbginPpG/090Ha4j1TCAMDj sZwcgC0DxfHupoTJ9ZDrXgIS5JKZQdguh6DiiHeSoHEbVgDUaL0sWoFaqQ0kCuwRyC1r zGu2AZ4Z4XALv3WHPwKqlLq2qd59mXX12Awm6YHs+UrRhaG2cIRrKhTgN42KkL3lr6P4 bsJA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708131541; x=1708736341; 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=cWbguiNHtTSYUYCLfEbpuKVHcWVD1RqHX9iqh/aIsVE=; b=qInFNeg/0rPKlFw4vyLT9JoVfIUyzr0C5BCbYSIyprZBIon6yoK7yqcZzjiiIpCyfq uIlTu/IT32ag8RgGSrsDF9IODBO48A8CNe7Ntix8gA1G8oVNzmK+7zG79g3/xfs94c3V RxBjGB6gVLWt7kyp68ME8fj77+0KqkrbEXcfyn0RPqHehMuJUOYt1GmfBNH/5Z3sU6k9 WtDpTKaHYoDnTLH/qZPMYc75BGaRDqY+J4gGHhH9AqOVfzxfSIL5epk7hhlTrb5o3doi fQGPmYZe/3qjrFLRG0ApMwkRj67tYfcrQj6U4vB9ulReUh5npN9bByrEWuBSF92akxrM MWSA== X-Gm-Message-State: AOJu0YzACCkGcegPYNhcG/W3x0TmyOrvGrk06I0/zV8s8IgpDZ6ZrSja y0HJnhcQKCtIOTABq1zRl/6U/hS2KfPLX8xMl35GUXkQeqNYgvFJQFlRUXM1HSISEmPd0bQaPNx x X-Received: by 2002:a92:c5cd:0:b0:365:44:1edb with SMTP id s13-20020a92c5cd000000b0036500441edbmr4716100ilt.3.1708131541456; Fri, 16 Feb 2024 16:59:01 -0800 (PST) Received: from atishp.ba.rivosinc.com ([64.71.180.162]) by smtp.gmail.com with ESMTPSA id d188-20020a6336c5000000b005dc89957e06sm487655pga.71.2024.02.16.16.58.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 16 Feb 2024 16:59:01 -0800 (PST) From: Atish Patra <atishp@rivosinc.com> To: linux-kernel@vger.kernel.org Cc: Atish Patra <atishp@rivosinc.com>, Adrian Hunter <adrian.hunter@intel.com>, Alexander Shishkin <alexander.shishkin@linux.intel.com>, Alexandre Ghiti <alexghiti@rivosinc.com>, Andrew Jones <ajones@ventanamicro.com>, Anup Patel <anup@brainfault.org>, Arnaldo Carvalho de Melo <acme@kernel.org>, Atish Patra <atishp@atishpatra.org>, Christian Brauner <brauner@kernel.org>, =?utf-8?b?Q2zDqW1lbnQgTMOpZ2Vy?= <cleger@rivosinc.com>, Conor Dooley <conor@kernel.org>, devicetree@vger.kernel.org, Evan Green <evan@rivosinc.com>, Guo Ren <guoren@kernel.org>, Heiko Stuebner <heiko@sntech.de>, Ian Rogers <irogers@google.com>, Ingo Molnar <mingo@redhat.com>, James Clark <james.clark@arm.com>, Jing Zhang <renyu.zj@linux.alibaba.com>, Jiri Olsa <jolsa@kernel.org>, Ji Sheng Teoh <jisheng.teoh@starfivetech.com>, John Garry <john.g.garry@oracle.com>, Jonathan Corbet <corbet@lwn.net>, Kan Liang <kan.liang@linux.intel.com>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>, kvm-riscv@lists.infradead.org, kvm@vger.kernel.org, Ley Foon Tan <leyfoon.tan@starfivetech.com>, linux-doc@vger.kernel.org, linux-perf-users@vger.kernel.org, linux-riscv@lists.infradead.org, Mark Rutland <mark.rutland@arm.com>, Namhyung Kim <namhyung@kernel.org>, Palmer Dabbelt <palmer@dabbelt.com>, Paul Walmsley <paul.walmsley@sifive.com>, Peter Zijlstra <peterz@infradead.org>, Rob Herring <robh+dt@kernel.org>, Samuel Holland <samuel.holland@sifive.com>, Weilin Wang <weilin.wang@intel.com>, Will Deacon <will@kernel.org>, kaiwenxue1@gmail.com, Yang Jihong <yangjihong1@huawei.com> Subject: [PATCH RFC 18/20] tools arch uapi: Sync the uinstd.h header file for RISC-V Date: Fri, 16 Feb 2024 16:57:36 -0800 Message-Id: <20240217005738.3744121-19-atishp@rivosinc.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240217005738.3744121-1-atishp@rivosinc.com> References: <20240217005738.3744121-1-atishp@rivosinc.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: <linux-kernel.vger.kernel.org> List-Subscribe: <mailto:linux-kernel+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kernel+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1791106705920252648 X-GMAIL-MSGID: 1791106705920252648 |
Series |
Add Counter delegation ISA extension support
|
|
Commit Message
Atish Patra
Feb. 17, 2024, 12:57 a.m. UTC
The uninstd.h has been changed since it's last sync. Update it so
that perf tool can use the new RISC-V specific syscall in perf tool.
Signed-off-by: Atish Patra <atishp@rivosinc.com>
---
tools/arch/riscv/include/uapi/asm/unistd.h | 14 +++++++++++++-
1 file changed, 13 insertions(+), 1 deletion(-)
diff --git a/tools/arch/riscv/include/uapi/asm/unistd.h b/tools/arch/riscv/include/uapi/asm/unistd.h index f506cca520b0..950ab3fd4409 100644 --- a/tools/arch/riscv/include/uapi/asm/unistd.h +++ b/tools/arch/riscv/include/uapi/asm/unistd.h @@ -15,11 +15,14 @@ * along with this program. If not, see <https://www.gnu.org/licenses/>. */ -#ifdef __LP64__ +#if defined(__LP64__) && !defined(__SYSCALL_COMPAT) #define __ARCH_WANT_NEW_STAT #define __ARCH_WANT_SET_GET_RLIMIT #endif /* __LP64__ */ +#define __ARCH_WANT_SYS_CLONE3 +#define __ARCH_WANT_MEMFD_SECRET + #include <asm-generic/unistd.h> /* @@ -40,3 +43,12 @@ #define __NR_riscv_flush_icache (__NR_arch_specific_syscall + 15) #endif __SYSCALL(__NR_riscv_flush_icache, sys_riscv_flush_icache) + +/* + * Allows userspace to query the kernel for CPU architecture and + * microarchitecture details across a given set of CPUs. + */ +#ifndef __NR_riscv_hwprobe +#define __NR_riscv_hwprobe (__NR_arch_specific_syscall + 14) +#endif +__SYSCALL(__NR_riscv_hwprobe, sys_riscv_hwprobe)