Commit b3a07086 authored by Zaid Al-Bassam's avatar Zaid Al-Bassam Committed by Will Deacon

perf: pmuv3: Change GENMASK to GENMASK_ULL

GENMASK macro uses "unsigned long" (32-bit wide on arm and 64-bit
on arm64), This causes build issues when enabling PMUv3 on arm as
it tries to access bits > 31. This patch switches the GENMASK to
GENMASK_ULL, which uses "unsigned long long" (64-bit on both arm
and arm64).
Signed-off-by: default avatarZaid Al-Bassam <zalbassam@google.com>
Acked-by: default avatarMarc Zyngier <maz@kernel.org>
Tested-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Link: https://lore.kernel.org/r/20230317195027.3746949-6-zalbassam@google.comSigned-off-by: default avatarWill Deacon <will@kernel.org>
parent 11fba29a
......@@ -489,7 +489,7 @@ static bool armv8pmu_event_needs_bias(struct perf_event *event)
static u64 armv8pmu_bias_long_counter(struct perf_event *event, u64 value)
{
if (armv8pmu_event_needs_bias(event))
value |= GENMASK(63, 32);
value |= GENMASK_ULL(63, 32);
return value;
}
......@@ -497,7 +497,7 @@ static u64 armv8pmu_bias_long_counter(struct perf_event *event, u64 value)
static u64 armv8pmu_unbias_long_counter(struct perf_event *event, u64 value)
{
if (armv8pmu_event_needs_bias(event))
value &= ~GENMASK(63, 32);
value &= ~GENMASK_ULL(63, 32);
return value;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment