summaryrefslogtreecommitdiffstats
path: root/arch/blackfin/mach-common/arch_checks.c
diff options
context:
space:
mode:
authorMike Frysinger <vapier.adi@gmail.com>2009-03-05 10:33:36 +0100
committerBryan Wu <cooloney@kernel.org>2009-03-05 10:33:36 +0100
commitf7e989ab64f926e34bafea0752431e1fd6a618f3 (patch)
treeb0c070d0701209ef9045e4fb5eada70afe945d19 /arch/blackfin/mach-common/arch_checks.c
parentBlackfin arch: fix bug - The SPORT_HYS bit is not set for BF561 0.5 (diff)
downloadlinux-f7e989ab64f926e34bafea0752431e1fd6a618f3.tar.xz
linux-f7e989ab64f926e34bafea0752431e1fd6a618f3.zip
Blackfin arch: make sure people do not set the kernel load address too high
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
Diffstat (limited to 'arch/blackfin/mach-common/arch_checks.c')
-rw-r--r--arch/blackfin/mach-common/arch_checks.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/arch/blackfin/mach-common/arch_checks.c b/arch/blackfin/mach-common/arch_checks.c
index 98133b968f7b..b3a2e3fa15e3 100644
--- a/arch/blackfin/mach-common/arch_checks.c
+++ b/arch/blackfin/mach-common/arch_checks.c
@@ -62,3 +62,8 @@
#if (CONFIG_BOOT_LOAD & 0x3)
# error "The kernel load address must be 4 byte aligned"
#endif
+
+/* The entire kernel must be able to make a 24bit pcrel call to start of L1 */
+#if ((0xffffffff - L1_CODE_START + 1) + CONFIG_BOOT_LOAD) > 0x1000000
+# error "The kernel load address is too high; keep it below 10meg for safety"
+#endif