[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZoLjOTs2ywnw5v_x@J2N7QTR9R3>
Date: Mon, 1 Jul 2024 18:11:21 +0100
From: Mark Rutland <mark.rutland@....com>
To: "Rob Herring (Arm)" <robh@...nel.org>
Cc: Russell King <linux@...linux.org.uk>,
Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...hat.com>,
Arnaldo Carvalho de Melo <acme@...nel.org>,
Namhyung Kim <namhyung@...nel.org>,
Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
Jiri Olsa <jolsa@...nel.org>, Ian Rogers <irogers@...gle.com>,
Adrian Hunter <adrian.hunter@...el.com>,
Will Deacon <will@...nel.org>, Marc Zyngier <maz@...nel.org>,
Oliver Upton <oliver.upton@...ux.dev>,
James Morse <james.morse@....com>,
Suzuki K Poulose <suzuki.poulose@....com>,
Zenghui Yu <yuzenghui@...wei.com>,
Catalin Marinas <catalin.marinas@....com>,
James Clark <james.clark@....com>,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
linux-perf-users@...r.kernel.org, kvmarm@...ts.linux.dev
Subject: Re: [PATCH v2 02/12] perf: arm_pmuv3: Drop unnecessary
IS_ENABLED(CONFIG_ARM64) check
On Wed, Jun 26, 2024 at 04:32:26PM -0600, Rob Herring (Arm) wrote:
> The IS_ENABLED(CONFIG_ARM64) check for threshold support is unnecessary.
> The purpose is to not enable thresholds on arm32, but if threshold is
> non-zero, the check against threshold_max() just above here will have
> errored out because threshold_max() is always 0 on arm32.
>
> Signed-off-by: Rob Herring (Arm) <robh@...nel.org>
Acked-by: Mark rutland <mark.rutland@....com>
Mark.
> ---
> v2:
> - new patch
> ---
> drivers/perf/arm_pmuv3.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/perf/arm_pmuv3.c b/drivers/perf/arm_pmuv3.c
> index 8ed5c3358920..3e51cd7062b9 100644
> --- a/drivers/perf/arm_pmuv3.c
> +++ b/drivers/perf/arm_pmuv3.c
> @@ -1045,7 +1045,7 @@ static int armv8pmu_set_event_filter(struct hw_perf_event *event,
> return -EINVAL;
> }
>
> - if (IS_ENABLED(CONFIG_ARM64) && th) {
> + if (th) {
> config_base |= FIELD_PREP(ARMV8_PMU_EVTYPE_TH, th);
> config_base |= FIELD_PREP(ARMV8_PMU_EVTYPE_TC,
> armv8pmu_event_threshold_control(attr));
>
> --
> 2.43.0
>
Powered by blists - more mailing lists