[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20240724-perf_set_event_limit-v1-2-e680c93eca55@rivosinc.com>
Date: Wed, 24 Jul 2024 15:54:12 -0700
From: Charlie Jenkins <charlie@...osinc.com>
To: Peter Zijlstra <peterz@...radead.org>, Ingo Molnar <mingo@...hat.com>,
Arnaldo Carvalho de Melo <acme@...nel.org>,
Namhyung Kim <namhyung@...nel.org>, Mark Rutland <mark.rutland@....com>,
Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
Jiri Olsa <jolsa@...nel.org>, Ian Rogers <irogers@...gle.com>,
Adrian Hunter <adrian.hunter@...el.com>, Atish Patra <atishp@...osinc.com>
Cc: linux-perf-users@...r.kernel.org, linux-kernel@...r.kernel.org,
Charlie Jenkins <charlie@...osinc.com>
Subject: [PATCH 2/2] perf: Document PERF_EVENT_IOC_SET_EVENT_LIMIT
Introduce PERF_EVENT_IOC_SET_EVENT_LIMIT and explain the differences
between it and PERF_EVENT_IOC_REFRESH.
Signed-off-by: Charlie Jenkins <charlie@...osinc.com>
---
tools/perf/design.txt | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/tools/perf/design.txt b/tools/perf/design.txt
index aa8cfeabb743..1626ae83785a 100644
--- a/tools/perf/design.txt
+++ b/tools/perf/design.txt
@@ -439,6 +439,11 @@ Additionally, non-inherited overflow counters can use
to enable a counter for 'nr' events, after which it gets disabled again.
+PERF_EVENT_IOC_REFRESH will increment the event limit by 'nr' and enable the
+event. To increment the event limit without enabling it, use the following:
+
+ ioctl(fd, PERF_EVENT_IOC_INC_EVENT_LIMIT, nr);
+
A process can enable or disable all the counter groups that are
attached to it, using prctl:
--
2.44.0
Powered by blists - more mailing lists