diff options
author | Mark Rutland <mark.rutland@arm.com> | 2018-06-15 18:47:23 +0300 |
---|---|---|
committer | Marc Zyngier <marc.zyngier@arm.com> | 2018-06-21 11:14:54 +0300 |
commit | 6ebdf4db8fa564a150f46d32178af0873eb5abbb (patch) | |
tree | 02be276f8b9df33f97f9ff14ef4c4126ad787ce1 /tools/perf/util/scripting-engines/trace-event-python.c | |
parent | ba56bc3a0786992755e6804fbcbdc60ef6cfc24c (diff) | |
download | linux-6ebdf4db8fa564a150f46d32178af0873eb5abbb.tar.xz |
arm64: Introduce sysreg_clear_set()
Currently we have a couple of helpers to manipulate bits in particular
sysregs:
* config_sctlr_el1(u32 clear, u32 set)
* change_cpacr(u64 val, u64 mask)
The parameters of these differ in naming convention, order, and size,
which is unfortunate. They also differ slightly in behaviour, as
change_cpacr() skips the sysreg write if the bits are unchanged, which
is a useful optimization when sysreg writes are expensive.
Before we gain yet another sysreg manipulation function, let's
unify these with a common helper, providing a consistent order for
clear/set operands, and the write skipping behaviour from
change_cpacr(). Code will be migrated to the new helper in subsequent
patches.
Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Reviewed-by: Dave Martin <dave.martin@arm.com>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Diffstat (limited to 'tools/perf/util/scripting-engines/trace-event-python.c')
0 files changed, 0 insertions, 0 deletions