arm64: entry.S: convert el1_sync
commitb55a5a1b0a7d4f51b6c8eec0d4d78ace8f5fa2b3
authorJames Morse <james.morse@arm.com>
Thu, 2 Nov 2017 12:12:39 +0000 (2 12:12 +0000)
committerWill Deacon <will.deacon@arm.com>
Thu, 2 Nov 2017 15:55:41 +0000 (2 15:55 +0000)
tree58ce729296e93870cab0e40248a9d75d05e1d60c
parent84d0fb1bb6257d5d5d45f5e3554ab441b4ff5a74
arm64: entry.S: convert el1_sync

el1_sync unmasks exceptions on a case-by-case basis, debug exceptions
are unmasked, unless this was a debug exception. IRQs are unmasked
for instruction and data aborts only if the interupted context had
irqs unmasked.

Following our 'dai' order, el1_dbg should run with everything masked.
For the other cases we can inherit whatever we interrupted.

Add a macro inherit_daif to set daif based on the interrupted pstate.

Signed-off-by: James Morse <james.morse@arm.com>
Reviewed-by: Julien Thierry <julien.thierry@arm.com>
Reviewed-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
arch/arm64/include/asm/assembler.h
arch/arm64/kernel/entry.S