mirror of
https://gitee.com/open-loongarch/linux-6.12.git
synced 2026-10-25 20:47:11 +08:00
mmc: loongson2: Fix error code in loongson2_mmc_resource_request()
There is a cut and paste bug so we accidentally return the wrong
variable. It should be "ret" instead of PTR_ERR(host->clk).
Fixes: 2115772014bd ("mmc: loongson2: Add Loongson-2K SD/SDIO controller driver")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Reviewed-by: Binbin Zhou <zhoubinbin@loongson.cn>
Link: https://lore.kernel.org/r/847bf395-6d62-49c9-a39d-8e82c5b17bf7@sabinyo.mountain
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: maoxiaochuan <maoxiaochuan@loongson.cn>
This commit is contained in:
committed by
maoxiaochuan
parent
77dca90f0e
commit
1a5da03e7c
@@ -886,7 +886,7 @@ static int loongson2_mmc_resource_request(struct platform_device *pdev,
|
||||
if (host->clk) {
|
||||
ret = devm_clk_rate_exclusive_get(dev, host->clk);
|
||||
if (ret)
|
||||
return PTR_ERR(host->clk);
|
||||
return ret;
|
||||
|
||||
host->current_clk = clk_get_rate(host->clk);
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user