Booting PPC Linux
I have a uImage + dtb that use to boot on a MPC8544-like system a few months ago.
After rebasing my code, it did not work.
I notice that in arch/ppc/lib/ppclinux.c the kernel is now called with the device tree as a parameter.
After investigation, I copied the device tree to within 8MB of the kernel entry point (0x0). It booted.
Is the DTB relocation a missing step?
Otherwise any suggestions on what I should look at (different kernel image)?
I have already been through the Barebox code and U-boot code (U-boot does relocate the device tree).
Cheers.
_______________________________________________
barebox mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/barebox
Quoted 5 lines · Renaud Barbier
I have a uImage + dtb that use to boot on a MPC8544-like system a few months ago.
After rebasing my code, it did not work.
Quoted 7 lines
I notice that in
arch/ppc/lib/ppclinux.cthe kernel is now called with the device tree as a parameter.After investigation, I copied the device tree to within 8MB of the kernel entry point (
0x0). It booted.Is the DTB relocation a missing step?
Yes, it seems so. barebox holds the device tree in malloced space. This is likely outside 8MB of the kernel entry point. I was not aware of that restriction.
Sascha
Signature · 9 lines
Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
Quoted 9 lines · Sascha Hauer
Quoted 8 lines · Renaud Barbier
I have a uImage + dtb that use to boot on a MPC8544-like system a few months ago.
After rebasing my code, it did not work.
I notice that in
arch/ppc/lib/ppclinux.cthe kernel is now called with the device tree as a parameter.
Quoted 7 lines
Quoted 4 lines
After investigation, I copied the device tree to within 8MB of the kernel entry point (
0x0). It booted.Is the DTB relocation a missing step?
Yes, it seems so. barebox holds the device tree in malloced space. This is likely outside 8MB of the kernel entry point. I was not aware of that restriction.
I think I found the limitation in Linux.
In arch/powerpc/mm/init_32.c:
/*
* address of the limit of what is accessible with initial MMU setup -
* 256MB usually, but only 16MB on 601.
*/phys_addr_t __initial_memory_limit_addr = (phys_addr_t)0x10000000;
The book E specific code (arch/ppc/mm/fsl_booke_mmu.c) adjusts this variable
to 256MB but the highest I was able to put the DTB is below 64MB.
It may be limited by another function call.
The available memory may be limited to 8 or 16MB on other CPUs (601 and 8xx).
Thanks.
Quoted 5 lines
Sascha
Signature · 12 lines
Renaud Barbier 14, Links Place 3/2 great Michael House Edinburgh, EH67EN Tel: +44 131 561 3532 -------------------------------------------------------------------------------- _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox