Commit 901c28c2 authored by Nobuhiro Iwamatsu's avatar Nobuhiro Iwamatsu Committed by Paul Mundt

sh: Fix address calculation of Initrd

Signed-off-by: default avatarNobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
Signed-off-by: default avatarPaul Mundt <lethal@linux-sh.org>
parent bde40898
......@@ -135,8 +135,9 @@ void __init check_for_initrd(void)
goto disable;
}
if (unlikely(start < PAGE_OFFSET)) {
pr_err("initrd start < PAGE_OFFSET\n");
if (unlikely(start < __MEMORY_START)) {
pr_err("initrd start (%08lx) < __MEMORY_START(%x)\n",
start, __MEMORY_START);
goto disable;
}
......@@ -157,7 +158,7 @@ void __init check_for_initrd(void)
/*
* Address sanitization
*/
initrd_start = (unsigned long)__va(__pa(start));
initrd_start = (unsigned long)__va(start);
initrd_end = initrd_start + INITRD_SIZE;
memblock_reserve(__pa(initrd_start), INITRD_SIZE);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment