Some compilers complain about unaligned opcodes with the strings embedded in the text section. Therefore move the panic strings to the rodata section to avoid the compile error. Also, make the bad_exception point to string instead of passing the first four characters of the string as a pointer to the panic function. Finally, there is no need to map the panic strings into Hyp mode, as the panic function is called from SVC mode in the host SVC address space. Cc: Will Deacon <will.deacon@xxxxxxx> Cc: Marc Zyngier <marc.zyngier@xxxxxxx> Signed-off-by: Christoffer Dall <c.dall@xxxxxxxxxxxxxxxxxxxxxx> --- arch/arm/kvm/interrupts.S | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/arch/arm/kvm/interrupts.S b/arch/arm/kvm/interrupts.S index 3b3ab73..3bb0f5b 100644 --- a/arch/arm/kvm/interrupts.S +++ b/arch/arm/kvm/interrupts.S @@ -303,7 +303,7 @@ THUMB( orr r2, r2, #PSR_T_BIT ) mrs r1, ELR_hyp ldr r2, =BSYM(panic) msr ELR_hyp, r2 - ldr r0, \panic_str + ldr r0, =\panic_str eret .endm @@ -485,6 +485,11 @@ hyp_fiq: .ltorg +__kvm_hyp_code_end: + .globl __kvm_hyp_code_end + + .section ".rodata" + und_die_str: .ascii "unexpected undefined exception in Hyp mode at: %#08x" pabt_die_str: @@ -494,5 +499,3 @@ dabt_die_str: svc_die_str: .ascii "unexpected HVC/SVC trap in Hyp mode at: %#08x" -__kvm_hyp_code_end: - .globl __kvm_hyp_code_end -- 1.7.9.5 _______________________________________________ kvmarm mailing list kvmarm@xxxxxxxxxxxxxxxxxxxxx https://lists.cs.columbia.edu/cucslists/listinfo/kvmarm