Skip to content

Commit 168054c

Browse files
Dan Carpenterstorulf
authored andcommitted
mmc: sdhci-sprd: Fix error code in sdhci_sprd_tuning()
Return an error code if sdhci_sprd_get_best_clk_sample() fails. Currently, it returns success. Fixes: d83d251 ("mmc: sdhci-sprd: Add SD HS mode online tuning") Signed-off-by: Dan Carpenter <[email protected]> Reviewed-by: Wenchao Chen <[email protected]> Reviewed-by: Baolin Wang <[email protected]> Acked-by: Adrian Hunter <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Ulf Hansson <[email protected]>
1 parent 1202d61 commit 168054c

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/mmc/host/sdhci-sprd.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -644,6 +644,7 @@ static int sdhci_sprd_tuning(struct mmc_host *mmc, struct mmc_card *card,
644644
best_clk_sample = sdhci_sprd_get_best_clk_sample(mmc, value);
645645
if (best_clk_sample < 0) {
646646
dev_err(mmc_dev(host->mmc), "all tuning phase fail!\n");
647+
err = best_clk_sample;
647648
goto out;
648649
}
649650

0 commit comments

Comments
 (0)