From: Christophe Leroy <christophe.leroy@csgroup.eu>
To: cp <carlojpisani@gmail.com>, linuxppc-dev@lists.ozlabs.org
Cc: paulus@samba.org, torvalds@linux-foundation.org
Subject: Re: ppc32 doesn't boot when linkaddr=0x00900000
Date: Mon, 27 Sep 2021 08:53:26 +0200 [thread overview]
Message-ID: <9e87cf45-cf83-2aaf-20e2-575a14e29245@csgroup.eu> (raw)
In-Reply-To: <CA+QBN9AFNSf3+U4iMhwZx7c69MLk-BtSbVODBEA97ObYWRczbQ@mail.gmail.com>
Hi,
Le 25/09/2021 à 11:49, cp a écrit :
> hi
> I am new to this list. Hope this is the right place to ask.
>
> I am working with a PPC405GP board, and as far as I understand, the
> support for ppc40x platforms like Acadia and Walnut were dropped with
> kernel 5.8.0, so this seems like a pretty straightforward question,
> but extensive experiments from kernel 4.11 to kernel 5.7.19 haven't
> shown a really clear, up-to-date answer.
>
> In k4.11 .. k5.7.19, when the kernel size is bigger than 8 MB, the
> final kernel doesn't boot but rather arch/powerpc/boot/main.c dies
> before the first message from the kernel shows up.
>
> Why?
>
...
>
> The following is the same kernel, compiled with the same .config, but
> with two link_addr values
>
> A) with link_addr=0x0080.0000
...
> Finalizing device tree... flat tree at 0xf23b80
...
> B) with link_addr=0x0080.0000
...
> Finalizing device tree... flat tree at 0x1023b80
...
> Any ideas?
> I am lost ...
>
As you can see above, when it works you have "flat tree at 0xf23b80",
when it fails you have "flat tree at 0x1023b80".
The reason for the failure is likely that ppc 40x only maps 16 Mbytes at
startup, so when your device tree is outside that map if fails.
See
https://elixir.bootlin.com/linux/v5.15-rc2/source/arch/powerpc/kernel/head_40x.S#L656
Called from
https://elixir.bootlin.com/linux/v5.15-rc2/source/arch/powerpc/kernel/head_40x.S#L56
As you can see it maps one 16Mbytes page.
Allthough I'm not an expert on 40x I think it should be easy to map a
second 16Mbytes page to get 32Mbytes mapped. I will send a patch later
today for you to test.
Christophe
next prev parent reply other threads:[~2021-09-27 6:54 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-25 9:49 ppc32 doesn't boot when linkaddr=0x00900000 cp
2021-09-25 12:24 ` Christophe Leroy
2021-09-27 6:53 ` Christophe Leroy [this message]
2021-09-27 19:20 ` [PATCH] powerpc/40x: Map 32Mbytes of memory at startup cp
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9e87cf45-cf83-2aaf-20e2-575a14e29245@csgroup.eu \
--to=christophe.leroy@csgroup.eu \
--cc=carlojpisani@gmail.com \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=paulus@samba.org \
--cc=torvalds@linux-foundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).