Skip to contentSkip to conversation

media: camss: ispif: Remove redundant dev_err call in msm_ispif_subdev_init()

PATCH Applied Yang Yingliang 3 participants 3 messages Apr 9, 2021 – May 26, 2021

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 media: camss: ispif: Remove redundant dev_err call in msm_ispif_subdev_init()

There is a error message within devm_ioremap_resource already, so remove the dev_err call to avoid redundant error message.

---
 drivers/media/platform/qcom/camss/camss-ispif.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)
drivers/media/platform/qcom/camss/camss-ispif.c +2 -6
index a30e453de162..37611c8861da 100644
@@ -1145,17 +1145,13 @@ int msm_ispif_subdev_init(struct camss *camss,
 
 	r = platform_get_resource_byname(pdev, IORESOURCE_MEM, res->reg[0]);
 	ispif->base = devm_ioremap_resource(dev, r);
-	if (IS_ERR(ispif->base)) {
-		dev_err(dev, "could not map memory\n");
+	if (IS_ERR(ispif->base))
 		return PTR_ERR(ispif->base);
-	}
 
 	r = platform_get_resource_byname(pdev, IORESOURCE_MEM, res->reg[1]);
 	ispif->base_clk_mux = devm_ioremap_resource(dev, r);
-	if (IS_ERR(ispif->base_clk_mux)) {
-		dev_err(dev, "could not map memory\n");
+	if (IS_ERR(ispif->base_clk_mux))
 		return PTR_ERR(ispif->base_clk_mux);
-	}
 
 	/* Interrupt */
 
Signature · 1 line
2.25.1
Reviewed-by on v1 1/1
#1 lore raw

Hi Yang,

Thanks for the patch.

Quoted 25 lines · Yang Yingliang

There is a error message within devm_ioremap_resource already, so remove the dev_err call to avoid redundant error message.

---
 drivers/media/platform/qcom/camss/camss-ispif.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)
drivers/media/platform/qcom/camss/camss-ispif.c +1 -3
index a30e453de162..37611c8861da 100644
@@ -1145,17 +1145,13 @@ int msm_ispif_subdev_init(struct camss *camss,
 
        r = platform_get_resource_byname(pdev, IORESOURCE_MEM, res->reg[0]);
        ispif->base = devm_ioremap_resource(dev, r);
-       if (IS_ERR(ispif->base)) {
-               dev_err(dev, "could not map memory\n");
+       if (IS_ERR(ispif->base))
                return PTR_ERR(ispif->base);
-       }
 

drivers/media/platform/qcom/camss/camss-ispif.c int msm_ispif_subdev_init(struct camss *camss, · line 1157

Quoted 10 lines
drivers/media/platform/qcom/camss/camss-ispif.c +1 -3
        r = platform_get_resource_byname(pdev, IORESOURCE_MEM, res->reg[1]);
        ispif->base_clk_mux = devm_ioremap_resource(dev, r);
-       if (IS_ERR(ispif->base_clk_mux)) {
-               dev_err(dev, "could not map memory\n");
+       if (IS_ERR(ispif->base_clk_mux))
                return PTR_ERR(ispif->base_clk_mux);
-       }
 
        /* Interrupt */
 
#2 lore raw
In reply to Yang Yingliang
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 13:06:33 +0800 you wrote:

There is a error message within devm_ioremap_resource already, so remove the dev_err call to avoid redundant error message.

[...]

Here is the summary with links:
- [-next] media: camss: ispif: Remove redundant dev_err call in msm_ispif_subdev_init()

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

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