What I want to do:
I am working on a project where we want to update our RPi on boot. We are working with buildroot successfully for almost one year. Now I am trying to get it work with U-boot.
What versions I am working with:
- RPi 3
- buildroot 2017.05 which contains U-boot 2017.03
What I already have read:
I have read over 100 web pages. My main inspirations are:
- http://elinux.org/RPi_U-Boot
- http://ltekieli.com/buildroot-with-raspberry-pi-u-boot/ (where I also posted a comment to ask for advice)
- and the official Raspberry forums where I posted the exact same question
What I have done so far:
So I build on a Debian (32bits). I configure buildroot with raspberrypi3_defconfig
, and in the bootloader menu I select U-boot and set the U-boot config to rpi_3_32b
. The simple rpi
config does not work (hangs in rainbow) and obviously I am unable to build with rpi_3
config as it implies 64bits, which my host is not able to provide. (If I really must switch to 64bits for host and RPi and U-boot, I think I would be able to do it, but I am fairly sure I should be able to achieve my project with 32bits too.)
In the linux menuconfig of buildroot, I also changed some kernel settings to have early printk, logging level to 7 and to enable low-level debug.
What I am able to do:
I can boot and stop in U-boot menu.
The problem now:
When I proceed the fatload+bootz commands, I only get the starting kernel message and it hangs there. I am connected through UART serial line and I also have the official RPi touchscreen on the DSI. I tried to change the console in the bootargs since there are different minds on the web, I tried ttyAMA0, ttyS0, tty0, tty1.
But if I only changed the kernel= line in the config.txt, my RPi hangs in rainbow screen. I had to disable the overlay setting to fix this.
Since I get no output at all, it is really difficult to guess what the problem is... Any advice would be welcome :)
Update 2017-06-15
Here are some more information regarding the comments I received:
- The link to the RPi forums is in a comment. As I do not have enough reputation, I cannot post more than 2 links here, sorry...
- If in
config.txt
I replacekernel=u-boot.bin
bykernel=zImage
, it boots properly. Also inconfig.txt
, I had to disable the pi3 overlays otherwise U-boot does not work and I got stuck in the rainbow screen. - Building buildroot with
raspberrypi3_64_defconfig
and U-boot withrpi_3
(instead ofrpi_3_32b
), the compilation fails