Im trying to compile mainline for the Milkv Duo S. I dont get any output when using a device tree from mainline. However I can get console output when using the device tree from the 2.0.1 release. Ive gotten it to boot but I cant get it to load the SD card, getting stuck at:
Earlier in the boot I can see the pinctrl module having an issue.
[ 0.731541] sg2000-pinctrl 300100000001000.pinctrl: probe with driver sg2000-pinctrl failed with error -12
It would make sense that it cannot load the SD card because it cannot mux the pins as needed. I decompiled the 2.0.1 device tree and have been modifying it to try to get the SD card to mount.
My two questions are:
Why would there be no console output when using the mainline device tree? It could be related to the pin mux but it works if I remove the old pin mux device tree entry, meaning the console is earlier in the process.
Why is the sg2000-pinctrl module failing to probe? -12 is ENOMEM, but I cant think of a reason for it not being able to allocate.
I was able to get console output using the mainline generated device tree by removing the resets property from uart0. Here is what my device tree looks like:
I am now getting messages from pinctrl and I can see it mux uart0:
...
[ 0.727466] sg2000-pinctrl 3001000.pinctrl: found group selector 0 for uart0-cfg.uart0-pins
[ 0.727479] sg2000-pinctrl 3001000.pinctrl: found group selector 0 for uart0-cfg.uart0-pins
[ 0.727495] sg2000-pinctrl 3001000.pinctrl: request pin 3332 (UART0_TX) for 4140000.serial
[ 0.727509] sg2000-pinctrl 3001000.pinctrl: request pin 3331 (UART0_RX) for 4140000.serial
...
But I still cannot get it to see the sd. I do not see any logs for it muxing the sdhci0 or mmc config, so Im wondering if it is and if there is a way to probe it / force it.
Turns out I was missing some required drivers under STMicro for to get the SDHC to work. I can now boot to the sd card but dont have ethernet. Im getting the following kernel logs:
I have that enabled and im still seeing the error. Im thinking it is something with my device tree. Do you know if the pinctrl is needed to mux any pins for it?