Hi
On 12. 02. 19 12:22, Roland Hieber wrote:
If I remember correctly, there was a patch changing that behaviour... Ah
yes, commit abc0447440d6 [0]:
ARM: dts: bcm2835-rpi: re-enable booting from SD card
Kernel commit a19adf8d86e822eba502486524127595372c85f6 [0] changed the
RPi1 device tree from &sdhci to &sdhost, which was imported in barebox
commit d14b844b08635c717fb52a294ed8d6872e260315. It seems that barebox
does not have a driver for brcm,bcm2835-sdhost (yet), which resulted in
barebox unable to boot from SD card. However, the driver for
brcm,bcm2835-sdhci worked fine in the past.
Although the upstream change was made for good reasons, the simplest
change for barebox for now is to revert to using &sdhci and disable
&sdhost.
[0]: https://git.pengutronix.de/cgit/barebox/commit/?h=master&id=abc0447440d6
The "solution" was a small device tree fix. Could this be related to
your problem? Unfortunately no one here has a RPi Compute Module, but
there were already similar questions in the last month. (Cc Moritz)
Ah, thanks for pointing this out. That commit only touched device tree
for R.Pi 1. I tried to do something similar on Compute Module 3 by
adding the following into bcm2837-rpi-3.dts:
&sdhci {
pinctrl-0 = <&emmc_gpio48>;
/delete-property/ mmc-pwrseq;
/delete-property/ non-removable;
/delete-property/ #address-cells;
/delete-property/ #size-cells;
/delete-node/ wifi@1;
};
&sdhost {
status = "disabled";
};
Unfortunately it fails to boot like that with the last things printed
out being:
initcall-> rpi_devices_init+0x0/0x138
register_device: bcm2835_fb0
bcm2835_mci 3f300000.sdhci@xxxxxxxxxxx: Wanted 400000 hz, returning
divider 313 (626) which yields 399361 hz
bcm2835_mci 3f300000.sdhci@xxxxxxxxxxx: Changing bus width to 1
bcm2835_mci 3f300000.sdhci@xxxxxxxxxxx: IO settings: bus width=0,
frequency=400000 Hz
bcm2835_mci 3f300000.sdhci@xxxxxxxxxxx: Changing bus width to 1
bcm2835_mci 3f300000.sdhci@xxxxxxxxxxx: IO settings: bus width=0,
frequency=400000 Hz
One possible reason for this might be that pin functions aren't
re-assigned. I think pinctrl isn't implemented for bcm2835. It probably
works on R.Pi 1 because there firmware already assigns correct pin
functions by default before jumping to Bearbox.
I'll see if I can implement pinctrl. It shouldn't be much work since
most things already seem to be implemented in gpio-bcm2835.c.
Best regards
Tomaž
_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox