xen/arm32: entry: Document the purpose of r11 in the traps handler
authorJulien Grall <julien.grall@linaro.org>
Fri, 2 Feb 2018 14:19:25 +0000 (14:19 +0000)
committerStefano Stabellini <sstabellini@kernel.org>
Fri, 2 Feb 2018 19:35:07 +0000 (11:35 -0800)
commitdd855aa430f2da9b677c145f0c625a82aaa97110
treefc3cd1828945dcd99e0ce9a1ed35a8d99881cbd6
parent665c4b6aa79eb21b1aada9f7f98fb5cb7f03743a
xen/arm32: entry: Document the purpose of r11 in the traps handler

It took me a bit of time to understand why __DEFINE_TRAP_ENTRY is
storing the original stack pointer in r11. It is working in pair with
return_traps_entry where sp will be restored from r11.

This is fine because per the AAPCS r11 must be preserved by the
subroutine. So in return_from_trap, r11 will still contain the original
stack pointer.

Add some documentation in the code to point the 2 sides to each other.

Signed-off-by: Julien Grall <julien.grall@linaro.org>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
xen/arch/arm/arm32/entry.S