mmc: sdhci-msm: Fix slot indexing in driver

Fix slot indexing in driver for mmc and sdcard per
new indexing in dt.

Change-Id: Ie960cd9c1a616c1a9d98aa862a3944515d184628
Signed-off-by: Ram Prakash Gupta <quic_rampraka@quicinc.com>
Signed-off-by: Sarthak Garg <quic_sartgarg@quicinc.com>
Signed-off-by: Maramaina Naresh <quic_mnaresh@quicinc.com>
Signed-off-by: Jayasri Bhattacharyya <quic_jbhattac@quicinc.com>
This commit is contained in:
Jayasri Bhattacharyya 2023-10-04 10:10:40 +05:30
parent d20049aee9
commit c73d3a8dd3

View File

@ -5273,11 +5273,11 @@ static int sdhci_msm_probe(struct platform_device *pdev)
goto pltfm_free;
if (pdev->dev.of_node) {
ret = of_alias_get_id(pdev->dev.of_node, "sdhc");
if (ret <= 0)
ret = of_alias_get_id(pdev->dev.of_node, "mmc");
if (ret < 0)
dev_err(&pdev->dev, "get slot index failed %d\n", ret);
else if (ret <= 2)
sdhci_slot[ret-1] = msm_host;
sdhci_slot[ret] = msm_host;
}
/*