Now working on the software part, that really stunned me. 😀
I thought that should be already perfectly supported by openwrt driver…But after I check the driver carefully, I think I have to modify that code or find another way.
The code is under linux kernel source, source/drivers/mmc/host/mmc_spi.c
There is a note in that source…
58 * - MMC depends on a different chipselect management policy than the 59 * SPI interface currently supports for shared bus segments: it needs 60 * to issue multiple spi_message requests with the chipselect active, 61 * using the results of one message to decide the next one to issue. 62 * 63 * Pending updates to the programming interface, this driver expects 64 * that it not share the bus with other drivers (precluding conflicts).
Does that mean this driver can not work with the exists SPI flash?
And there is a good solution but for other router chip.
I did not try that yet, it might be able to work on RT5350 but need more checks.
I do not want to use GPIO for this, but this way looks much easier.
This part will cost some time
Any idea is welcome here. Please leave a comment, that will help a lot.