[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen master] xen: arm: ensure that the boot code is <4K in size
commit 6d848a95df61a76bdf9069b4ba9286d6358784d8 Author: Ian Campbell <ian.campbell@xxxxxxxxxx> AuthorDate: Mon Jul 21 13:59:59 2014 +0100 Commit: Ian Campbell <ian.campbell@xxxxxxxxxx> CommitDate: Thu Jul 24 16:23:17 2014 +0100 xen: arm: ensure that the boot code is <4K in size This avoids having to deal with the 1:1 boot mapping crossing a section or page boundary. Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx> Acked-by: Julien Grall <julien.grall@xxxxxxxxxx> --- xen/arch/arm/arm32/head.S | 2 ++ xen/arch/arm/arm64/head.S | 2 ++ xen/arch/arm/xen.lds.S | 6 ++++++ 3 files changed, 10 insertions(+), 0 deletions(-) diff --git a/xen/arch/arm/arm32/head.S b/xen/arch/arm/arm32/head.S index 0a95b68..2547ce1 100644 --- a/xen/arch/arm/arm32/head.S +++ b/xen/arch/arm/arm32/head.S @@ -457,6 +457,8 @@ fail: PRINT("- Boot failed -\r\n") 1: wfe b 1b +GLOBAL(_end_boot) + /* Copy Xen to new location and switch TTBR * r1:r0 ttbr * r2 source address diff --git a/xen/arch/arm/arm64/head.S b/xen/arch/arm/arm64/head.S index 4f0ea2d..b71b6f0 100644 --- a/xen/arch/arm/arm64/head.S +++ b/xen/arch/arm/arm64/head.S @@ -487,6 +487,8 @@ fail: PRINT("- Boot failed -\r\n") 1: wfe b 1b +GLOBAL(_end_boot) + /* Copy Xen to new location and switch TTBR * x0 ttbr * x1 source address diff --git a/xen/arch/arm/xen.lds.S b/xen/arch/arm/xen.lds.S index be55dad..079e085 100644 --- a/xen/arch/arm/xen.lds.S +++ b/xen/arch/arm/xen.lds.S @@ -178,3 +178,9 @@ SECTIONS .stab.indexstr 0 : { *(.stab.indexstr) } .comment 0 : { *(.comment) } } + +/* + * We require that Xen is loaded at a 4K boundary, so this ensures that any + * code running on the boot time identity map cannot cross a section boundary. + */ +ASSERT( _end_boot - start <= PAGE_SIZE, "Boot code is larger than 4K") -- generated by git-patchbot for /home/xen/git/xen.git#master _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |