Skip to content

Commit

Permalink
mmc: dw_mmc: hi3789cv200: Obviously always return success in remove c…
Browse files Browse the repository at this point in the history
…allback

dw_mci_pltfm_remove() returns 0 unconditionally and returning an error
in a platform remove callback isn't very sensible. (The only effect of
the latter is that the device core emits a generic warning and then
removes the device anyhow.)

So return 0 unconditionally to make it obvious there is no error
forwarded to the upper layers.

This is a preparation for making platform remove callbacks return void.

Signed-off-by: Uwe Kleine-König <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Ulf Hansson <[email protected]>
  • Loading branch information
Uwe Kleine-König authored and storulf committed Jul 12, 2022
1 parent 68eab51 commit 5069935
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion drivers/mmc/host/dw_mmc-hi3798cv200.c
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,9 @@ static int dw_mci_hi3798cv200_remove(struct platform_device *pdev)
clk_disable_unprepare(priv->drive_clk);
clk_disable_unprepare(priv->sample_clk);

return dw_mci_pltfm_remove(pdev);
dw_mci_pltfm_remove(pdev);

return 0;
}

static const struct of_device_id dw_mci_hi3798cv200_match[] = {
Expand Down

0 comments on commit 5069935

Please sign in to comment.