]> git.baikalelectronics.ru Git - kernel.git/commit
arm64: sysreg: Clean up instructions for modifying PSTATE fields
authorSuzuki K Poulose <suzuki.poulose@arm.com>
Sun, 16 Sep 2018 22:17:23 +0000 (23:17 +0100)
committerCatalin Marinas <catalin.marinas@arm.com>
Mon, 17 Sep 2018 13:56:01 +0000 (14:56 +0100)
commit026f91a66f2acc83004b3bdbe133cb033a9ef11a
treea3e826a31a325dcce06d412a055d7fd70608b23d
parentd0455d3e4ab75fe7c07e86c46d2132786881dcca
arm64: sysreg: Clean up instructions for modifying PSTATE fields

Instructions for modifying the PSTATE fields which were not supported
in the older toolchains (e.g, PAN, UAO) are generated using macros.
We have so far used the normal sys_reg() helper for defining the PSTATE
fields. While this works fine, it is really difficult to correlate the
code with the Arm ARM definition.

As per Arm ARM, the PSTATE fields are defined only using Op1, Op2 fields,
with fixed values for Op0, CRn. Also the CRm field has been reserved
for the Immediate value for the instruction. So using the sys_reg()
looks quite confusing.

This patch cleans up the instruction helpers by bringing them
in line with the Arm ARM definitions to make it easier to correlate
code with the document. No functional changes.

Cc: Will Deacon <will.deacon@arm.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
arch/arm64/include/asm/sysreg.h
arch/arm64/kernel/cpufeature.c