summaryrefslogtreecommitdiffstats
path: root/arch/arm64/kernel
diff options
context:
space:
mode:
authorMark Rutland <mark.rutland@arm.com>2017-02-09 15:19:18 +0000
committerWill Deacon <will.deacon@arm.com>2017-02-15 12:20:29 +0000
commit6c23e2ff7013be2c4bbcb7b9b3cc27c763348223 (patch)
treeac620cda6fcbcaf0303b62e4e0689c0034e869f1 /arch/arm64/kernel
parentf705d954634d161db5923fc86cacf0f9e301f73a (diff)
downloadlinux-6c23e2ff7013be2c4bbcb7b9b3cc27c763348223.tar.gz
linux-6c23e2ff7013be2c4bbcb7b9b3cc27c763348223.tar.bz2
linux-6c23e2ff7013be2c4bbcb7b9b3cc27c763348223.zip
arm64: ptrace: add XZR-safe regs accessors
In A64, XZR and the SP share the same encoding (31), and whether an instruction accesses XZR or SP for a particular register parameter depends on the definition of the instruction. We store the SP in pt_regs::regs[31], and thus when emulating instructions, we must be careful to not erroneously read from or write back to the saved SP. Unfortunately, we often fail to be this careful. In all cases, instructions using a transfer register parameter Xt use this to refer to XZR rather than SP. This patch adds helpers so that we can more easily and consistently handle these cases. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Marc Zyngier <marc.zyngier@arm.com> Cc: Will Deacon <will.deacon@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com>
Diffstat (limited to 'arch/arm64/kernel')
0 files changed, 0 insertions, 0 deletions