Mount SD Card Partition
Hi @vowstar ! Thanks for the step-by-step tutorial. Yes, I could reach the minimal Linux Instalation in k210 board ! Very Thanks!
However, the mission is read the SD Card of this board with minimal installation also. I have tried check some tools at busybox menu and buildroot menu, but it gave me some errors to compile.
Please, how can I set the correct parts at buildroot and/or busybox to mount the SD Card, properly?
Very Thanks and Best Regards!
Sorry for late reply, the card need compile filesystem in kernel, and write a dts to mapping sd card gpio to spi/sdcard driver, it is possible, but need time to debug
Seems the sdcard GPIO's are mapped now with kernel 5.13 but still I'm not seeing a block device for some reason. Any ideas? Was hoping to eventually get something cross compiled and uploaded to the sdcard vs wearing out the internal flash each time (and my patience).
I got it working with kernel 6.3, with a slightly modified configuration. I also used u-boot, but this is probably irrelevant.
First I modified the sdcard config to specify the board so linux includes the DTB by itself. I have 2 partitions on the SD, cant remember what the first one is on the top of my head but probably FAT32, and the second one ext2 (dont forget to update the sd-card config to point to partition 2). Put the linux kernel + DTB (not sure why this is neccesary, u-boot wont boot linux without it but it doesnt help linux detect the SD card) on the first partition according to u-boots instructions. Then you can boot u-boot, it will load linux which should now detect the SD card. You can probably skip u-boot, but this is how I did it.
I made a fork which updated linux to 6.3, I'll also be putting the SD config on there so it should be easy to follow.
@lypanov If you still need this, checkout https://github.com/JAicewizard/k210-linux-nommu/tree/master