summaryrefslogtreecommitdiffstats
path: root/arch/arm/kernel/vmlinux.lds.S
diff options
context:
space:
mode:
authorArd Biesheuvel <ard.biesheuvel@linaro.org>2015-03-24 17:48:07 +0000
committerWill Deacon <will.deacon@arm.com>2015-03-25 11:43:46 +0000
commit12eb3e833961bfe532b763a6e4e817ec87f48bc7 (patch)
tree411ecad03da275823c3adc682767e7eff86cb0af /arch/arm/kernel/vmlinux.lds.S
parente60a1fec44a2fe2c85ac406a5c1161ca2957a4fa (diff)
downloadblackbird-obmc-linux-12eb3e833961bfe532b763a6e4e817ec87f48bc7.tar.gz
blackbird-obmc-linux-12eb3e833961bfe532b763a6e4e817ec87f48bc7.zip
ARM: kvm: assert on HYP section boundaries not actual code size
Using ASSERT() with an expression that involves a symbol that is only supplied through a PROVIDE() definition in the linker script itself is apparently not supported by some older versions of binutils. So instead, rewrite the expression so that only the section boundaries __hyp_idmap_text_start and __hyp_idmap_text_end are used. Note that this reverts the fix in 06f75a1f6200 ("ARM, arm64: kvm: get rid of the bounce page") for the ASSERT() being triggered erroneously when unrelated linker emitted veneers happen to end up in the HYP idmap region. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com>
Diffstat (limited to 'arch/arm/kernel/vmlinux.lds.S')
-rw-r--r--arch/arm/kernel/vmlinux.lds.S2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/kernel/vmlinux.lds.S b/arch/arm/kernel/vmlinux.lds.S
index 2d760df0d57d..808398ec024e 100644
--- a/arch/arm/kernel/vmlinux.lds.S
+++ b/arch/arm/kernel/vmlinux.lds.S
@@ -381,5 +381,5 @@ ASSERT((__arch_info_end - __arch_info_begin), "no machine record defined")
* and should not cross a page boundary.
* The above comment applies as well.
*/
-ASSERT((__hyp_idmap_text_start & ~PAGE_MASK) + __hyp_idmap_size <= PAGE_SIZE,
+ASSERT(__hyp_idmap_text_end - (__hyp_idmap_text_start & PAGE_MASK) <= PAGE_SIZE,
"HYP init code too big or misaligned")
OpenPOWER on IntegriCloud