I want to try the setup of the CM3 module using Buildroot.
I would like to ask for feedback on the experience and support of the community by using Mender with Buildroot. Are there people out there successfully using this board for deployment?
Hi,
Actually Buildroot does provide some options to bring mender in, although the option comes with Grub2 as well.
I am testing this at the moment, but I am a bit stuck in defining the Grub for the Pi3.
Any hints?
Yeah, most parts of the Mender are part of Buildroot is upstream, but the board specific parts need to be provided.
I would not recommend you to go down the GRUB path on Pi3, as never have gotten it to work with GRUB on those specific boards. We simply rely on a U-Boot integration instead , e.g in our Yocto layers.
I think I am in a good way with the information provided.
However, now I am stuck at uBoot, which is not finding the kernel. Most likely some ignorance on my side.
Do you know if the repo you mentioned (mender-config) is a working project?
I have never tried it personally so can not comment on if it is functional. But looking at it, it seems to have he major parts in place.
To debug the problem with U-Boot not being able to find the kernel, I would look trough the boot.scr, and maybe try running these steps manually to isolate the problem
When tried ls mmc 0:2 the directory was displayed.
You are indeed correct, that option was missing and by changing that, the uImage file was found.
I also had to change the 0006 patch to consider the bcm2710-rpi-cm3.dtb.
By ls mmc 0:2 /boot I can see the above files mentioned.
At boot, it actually says starting kernel, quickly jumps to the image with 4 berries on top and then the screen goes entire black
At least we can say up to this point, this code is able to load uboot and pass a kernel to the system.
And I think I see the problem. The bootargs are missing a root= kernel argument in the boot.scr.
It should be something like this:
# This fetches bootargs from the RPi boot firmware which populates it in the dtb file
fdt addr ${fdt_addr} && fdt get value bootargs /chosen bootargs
run mender_setup
mmc dev ${mender_uboot_dev}
load ${mender_uboot_root} ${kernel_addr_r} /boot/uImage
bootm ${kernel_addr_r} - ${fdt_addr}
run mender_try_to_recover
I think that the Raspberry Pi will get the bootargs from cmdline.txt file in boot partition. So that one should be updated to contain root=${mender_kernel_root}, which is expanded when you run mender_setup
Hi Mirzak,
Since it is lunch time, I went for a fresh clean make now that we are at this point.
I’ll be back as soon as the ttyTV show ends and implement that.
Please note that this is important, to pickup the bootargs from the RPi boot firmware. It will probably boot without this, but you will notice some drop in functionality if you do not pass on the bootargs from RPi bootfirmware to the Linux kernel.