* [PATCH] sh: Fix address calculation of Initrd
@ 2010-10-05 8:16 Nobuhiro Iwamatsu
2010-10-05 8:17 ` Paul Mundt
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Nobuhiro Iwamatsu @ 2010-10-05 8:16 UTC (permalink / raw)
To: linux-sh
From: Nobuhiro Iwamatsu <iwamatsu.nobuhiro@renesas.com>
Signed-off-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
---
arch/sh/kernel/setup.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/arch/sh/kernel/setup.c b/arch/sh/kernel/setup.c
index f24d0ea..4e27846 100644
--- a/arch/sh/kernel/setup.c
+++ b/arch/sh/kernel/setup.c
@@ -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);
--
1.7.1
^ permalink raw reply related [flat|nested] 4+ messages in thread* Re: [PATCH] sh: Fix address calculation of Initrd
2010-10-05 8:16 [PATCH] sh: Fix address calculation of Initrd Nobuhiro Iwamatsu
@ 2010-10-05 8:17 ` Paul Mundt
2010-10-05 8:34 ` Nobuhiro Iwamatsu
2010-10-05 9:26 ` Paul Mundt
2 siblings, 0 replies; 4+ messages in thread
From: Paul Mundt @ 2010-10-05 8:17 UTC (permalink / raw)
To: linux-sh
On Tue, Oct 05, 2010 at 05:16:08PM +0900, Nobuhiro Iwamatsu wrote:
> From: Nobuhiro Iwamatsu <iwamatsu.nobuhiro@renesas.com>
>
> Signed-off-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
Can you describe what exactly the issue is? Is this broken on 29 bit or
32 bit? Did you test both?
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] sh: Fix address calculation of Initrd
2010-10-05 8:16 [PATCH] sh: Fix address calculation of Initrd Nobuhiro Iwamatsu
2010-10-05 8:17 ` Paul Mundt
@ 2010-10-05 8:34 ` Nobuhiro Iwamatsu
2010-10-05 9:26 ` Paul Mundt
2 siblings, 0 replies; 4+ messages in thread
From: Nobuhiro Iwamatsu @ 2010-10-05 8:34 UTC (permalink / raw)
To: linux-sh
Hi,
2010/10/5 Paul Mundt <lethal@linux-sh.org>:
> On Tue, Oct 05, 2010 at 05:16:08PM +0900, Nobuhiro Iwamatsu wrote:
>> From: Nobuhiro Iwamatsu <iwamatsu.nobuhiro@renesas.com>
>>
>> Signed-off-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
>
> Can you describe what exactly the issue is?
Because there is it on physics memory, start value fails in the check
by PAGE_OFFSET.
And __pa() is not necessary for the same reason.
> Is this broken on 29 bit or
> 32 bit? Did you test both?
Yes, I tested on both.
Best regards,
Nobuhiro
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] sh: Fix address calculation of Initrd
2010-10-05 8:16 [PATCH] sh: Fix address calculation of Initrd Nobuhiro Iwamatsu
2010-10-05 8:17 ` Paul Mundt
2010-10-05 8:34 ` Nobuhiro Iwamatsu
@ 2010-10-05 9:26 ` Paul Mundt
2 siblings, 0 replies; 4+ messages in thread
From: Paul Mundt @ 2010-10-05 9:26 UTC (permalink / raw)
To: linux-sh
On Tue, Oct 05, 2010 at 05:34:29PM +0900, Nobuhiro Iwamatsu wrote:
> Hi,
>
> 2010/10/5 Paul Mundt <lethal@linux-sh.org>:
> > On Tue, Oct 05, 2010 at 05:16:08PM +0900, Nobuhiro Iwamatsu wrote:
> >> From: Nobuhiro Iwamatsu <iwamatsu.nobuhiro@renesas.com>
> >>
> >> Signed-off-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
> >
> > Can you describe what exactly the issue is?
>
> Because there is it on physics memory, start value fails in the check
> by PAGE_OFFSET.
> And __pa() is not necessary for the same reason.
>
> > Is this broken on 29 bit or
> > 32 bit? Did you test both?
>
> Yes, I tested on both.
>
Ok, applied, thanks.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2010-10-05 9:26 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-10-05 8:16 [PATCH] sh: Fix address calculation of Initrd Nobuhiro Iwamatsu
2010-10-05 8:17 ` Paul Mundt
2010-10-05 8:34 ` Nobuhiro Iwamatsu
2010-10-05 9:26 ` Paul Mundt
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).