Skip to contentSkip to conversation

mmc: sdhci-msm: Remove unnecessary error log

PATCH Applied Jia Yang 4 participants 4 messages Apr 9, 2021 – May 26, 2021

Subsystems (3)
lore
Share & tools
lore

Jia Yang

author
#0 lore raw

PATCH 1/1 mmc: sdhci-msm: Remove unnecessary error log

devm_ioremap_resource() has recorded error log, so it's unnecessary to record log again.

---
 drivers/mmc/host/sdhci-msm.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)
drivers/mmc/host/sdhci-msm.c +2 -6
index d170c919e6e4..e44b7a66b73c 100644
@@ -1863,7 +1863,6 @@ static int sdhci_msm_ice_init(struct sdhci_msm_host *msm_host,
 	struct mmc_host *mmc = msm_host->mmc;
 	struct device *dev = mmc_dev(mmc);
 	struct resource *res;
-	int err;
 
 	if (!(cqhci_readl(cq_host, CQHCI_CAP) & CQHCI_CAP_CS))
 		return 0;
@@ -1881,11 +1880,8 @@ static int sdhci_msm_ice_init(struct sdhci_msm_host *msm_host,
 	}
 
 	msm_host->ice_mem = devm_ioremap_resource(dev, res);
-	if (IS_ERR(msm_host->ice_mem)) {
-		err = PTR_ERR(msm_host->ice_mem);
-		dev_err(dev, "Failed to map ICE registers; err=%d\n", err);
-		return err;
-	}
+	if (IS_ERR(msm_host->ice_mem))
+		return PTR_ERR(msm_host->ice_mem);
 
 	if (!sdhci_msm_ice_supported(msm_host))
 		goto disable;
Signature · 1 line
2.25.1
Reviewed-by on v1 1/1
#1 lore raw
Quoted 5 lines · Jia Yang

devm_ioremap_resource() has recorded error log, so it's unnecessary to record log again.

Thanks,
Mani

Quoted 33 lines
---
 drivers/mmc/host/sdhci-msm.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)
drivers/mmc/host/sdhci-msm.c +2 -6
index d170c919e6e4..e44b7a66b73c 100644
@@ -1863,7 +1863,6 @@ static int sdhci_msm_ice_init(struct sdhci_msm_host *msm_host,
 	struct mmc_host *mmc = msm_host->mmc;
 	struct device *dev = mmc_dev(mmc);
 	struct resource *res;
-	int err;
 
 	if (!(cqhci_readl(cq_host, CQHCI_CAP) & CQHCI_CAP_CS))
 		return 0;
@@ -1881,11 +1880,8 @@ static int sdhci_msm_ice_init(struct sdhci_msm_host *msm_host,
 	}
 
 	msm_host->ice_mem = devm_ioremap_resource(dev, res);
-	if (IS_ERR(msm_host->ice_mem)) {
-		err = PTR_ERR(msm_host->ice_mem);
-		dev_err(dev, "Failed to map ICE registers; err=%d\n", err);
-		return err;
-	}
+	if (IS_ERR(msm_host->ice_mem))
+		return PTR_ERR(msm_host->ice_mem);
 
 	if (!sdhci_msm_ice_supported(msm_host))
 		goto disable;
Signature · 1 line
2.25.1
#2 lore raw
In reply to Jia Yang
Quoted 6 lines · Jia Yang

devm_ioremap_resource() has recorded error log, so it's unnecessary to record log again.

Applied for next, thanks!

Kind regards
Uffe

Quoted 33 lines
---
 drivers/mmc/host/sdhci-msm.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)
drivers/mmc/host/sdhci-msm.c +2 -7
index d170c919e6e4..e44b7a66b73c 100644
@@ -1863,7 +1863,6 @@ static int sdhci_msm_ice_init(struct sdhci_msm_host *msm_host,
        struct mmc_host *mmc = msm_host->mmc;
        struct device *dev = mmc_dev(mmc);
        struct resource *res;
-       int err;
 
        if (!(cqhci_readl(cq_host, CQHCI_CAP) & CQHCI_CAP_CS))
                return 0;
@@ -1881,11 +1880,8 @@ static int sdhci_msm_ice_init(struct sdhci_msm_host *msm_host,
        }
 
        msm_host->ice_mem = devm_ioremap_resource(dev, res);
-       if (IS_ERR(msm_host->ice_mem)) {
-               err = PTR_ERR(msm_host->ice_mem);
-               dev_err(dev, "Failed to map ICE registers; err=%d\n", err);
-               return err;
-       }
+       if (IS_ERR(msm_host->ice_mem))
+               return PTR_ERR(msm_host->ice_mem);
 
        if (!sdhci_msm_ice_supported(msm_host))
                goto disable;
--

2.25.1

#3 lore raw
In reply to Jia Yang
This patch was applied to qcom/linux.git (refs/heads/for-next):

Hello:

This patch was applied to qcom/linux.git (refs/heads/for-next):

Quoted 8 lines · On Fri, 9 Apr 2021 09:54:24 +0800 you wrote:

devm_ioremap_resource() has recorded error log, so it's unnecessary to record log again.

---
 drivers/mmc/host/sdhci-msm.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

Here is the summary with links:
- [-next] mmc: sdhci-msm: Remove unnecessary error log

    https://git.kernel.org/qcom/c/ffa4877c0a29

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html