summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorArd Biesheuvel <ardb@kernel.org>2020-06-12 11:21:35 +0100
committerRussell King <rmk+kernel@armlinux.org.uk>2020-06-13 11:11:18 +0100
commitdb227c19e68db353e4cc6c99b6bc86bb24736943 (patch)
treebd3a465bb4cb24f075257d062ffcfe9a2ec9a8d6 /net
parent39c3e304567a013ac096ca8747fe53b44a76e44b (diff)
ARM: 8985/1: efi/decompressor: deal with HYP mode boot gracefully
EFI on ARM only supports short descriptors, and given that it mandates that the MMU and caches are on, it is implied that booting in HYP mode is not supported. However, implementations of EFI exist (i.e., U-Boot) that ignore this requirement, which is not entirely unreasonable, given that it makes HYP mode inaccessible to the operating system. So let's make sure that we can deal with this condition gracefully. We already tolerate booting the EFI stub with the caches off (even though this violates the EFI spec as well), and so we should deal with HYP mode boot with MMU and caches either on or off. - When the MMU and caches are on, we can ignore the HYP stub altogether, since we can carry on executing at HYP. We do need to ensure that we disable the MMU at HYP before entering the kernel proper. - When the MMU and caches are off, we have to drop to SVC mode so that we can set up the page tables using short descriptors. In this case, we need to install the HYP stub as usual, so that we can return to HYP mode before handing over to the kernel proper. Tested-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Ard Biesheuvel <ardb@kernel.org> Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Diffstat (limited to 'net')
0 files changed, 0 insertions, 0 deletions