mmc: fsl_esdhc_imx: Handle the "broken-cd" property
authorFabio Estevam <festevam@gmail.com>
Mon, 6 Jan 2020 23:11:27 +0000 (20:11 -0300)
committerStefano Babic <sbabic@denx.de>
Tue, 14 Jan 2020 21:47:15 +0000 (22:47 +0100)
commit29230f389db7b714393a722bfaab1d44d41b8fca
treeec7ff8338ab8cea932fe1832a7929d2edc61b472
parentbc9b06533a99b61c10544dc343b313fe8e8f63ac
mmc: fsl_esdhc_imx: Handle the "broken-cd" property

When no GPIO is used to read the card detect status the following
error is seen:

MMC:   FSL_SDHC: 0, FSL_SDHC: 1
Loading Environment from MMC... MMC: no card present
*** Warning - No block device, using default environment

Fix it by handling the "broken-cd" property in the same way
that drivers/mmc/sdhci.c does, which considers that the SD card
is present when the "broken-cd" property is passed.

Tested on a imx6ul-evk board.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
Reviewed-by: Stefano Babic <sbabic@denx.de>
drivers/mmc/fsl_esdhc_imx.c