Open 8bitgc opened 3 years ago
This seems to work. Compiled with CONFIG_MMC_BROKEN_CD and tested on a PinePhone with a broken card detection switch. https://github.com/8bitgc/Jumpdrive/tree/master/test
Reopening the issue as this needs to be implemented to Jumpdrive.
This may allow PinePhones with damaged SD sockets to boot off SD.
Damaged card detect switch in microSD socket causes U-Boot to halt with:
It fails even though U-Boot is running from the SD card itself. mmc_start_init tries to initialize the card and fails on the card detection.
https://gitlab.com/pine64-org/u-boot/-/blob/master/drivers/mmc/mmc.c#L2867-2879
CONFIG_MMC_BROKEN_CD should allow U-Boot to continue ignoring the state of the card detection pin.
Some background information in this post https://forum.pine64.org/showthread.php?tid=13775