diff mbox

[-next] hwrng: exynos - remove redundant dev_err call in exynos_trng_probe()

Message ID 1515591059-73230-1-git-send-email-weiyongjun1@huawei.com (mailing list archive)
State Not Applicable
Headers show

Commit Message

Wei Yongjun Jan. 10, 2018, 1:30 p.m. UTC
There is a error message within devm_ioremap_resource
already, so remove the dev_err call to avoid redundant
error message.

Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
 drivers/char/hw_random/exynos-trng.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)


--
To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Comments

Krzysztof Kozlowski Jan. 10, 2018, 2:24 p.m. UTC | #1
On Wed, Jan 10, 2018 at 2:30 PM, Wei Yongjun <weiyongjun1@huawei.com> wrote:
> There is a error message within devm_ioremap_resource
> already, so remove the dev_err call to avoid redundant
> error message.
>
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---
>  drivers/char/hw_random/exynos-trng.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)

Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>

Best regards,
Krzysztof
--
To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Łukasz Stelmach Jan. 11, 2018, 11:13 a.m. UTC | #2
It was <2018-01-10 śro 14:30>, when Wei Yongjun wrote:
> There is a error message within devm_ioremap_resource
> already, so remove the dev_err call to avoid redundant
> error message.
>
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>

Acked-by: Łukasz Stelmach <l.stelmach@samsung.com>

> ---
>  drivers/char/hw_random/exynos-trng.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/char/hw_random/exynos-trng.c b/drivers/char/hw_random/exynos-trng.c
> index 34d6f51..4c8a2be 100644
> --- a/drivers/char/hw_random/exynos-trng.c
> +++ b/drivers/char/hw_random/exynos-trng.c
> @@ -129,10 +129,8 @@ static int exynos_trng_probe(struct platform_device *pdev)
>  
>  	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
>  	trng->mem = devm_ioremap_resource(&pdev->dev, res);
> -	if (IS_ERR(trng->mem)) {
> -		dev_err(&pdev->dev, "Could not map IO resources.\n");
> +	if (IS_ERR(trng->mem))
>  		return PTR_ERR(trng->mem);
> -	}
>  
>  	pm_runtime_enable(&pdev->dev);
>  	ret = pm_runtime_get_sync(&pdev->dev);
>
>
>
>
Herbert Xu Jan. 18, 2018, 12:03 p.m. UTC | #3
On Wed, Jan 10, 2018 at 01:30:59PM +0000, Wei Yongjun wrote:
> There is a error message within devm_ioremap_resource
> already, so remove the dev_err call to avoid redundant
> error message.
> 
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>

Patch applied.  Thanks.
diff mbox

Patch

diff --git a/drivers/char/hw_random/exynos-trng.c b/drivers/char/hw_random/exynos-trng.c
index 34d6f51..4c8a2be 100644
--- a/drivers/char/hw_random/exynos-trng.c
+++ b/drivers/char/hw_random/exynos-trng.c
@@ -129,10 +129,8 @@  static int exynos_trng_probe(struct platform_device *pdev)
 
 	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
 	trng->mem = devm_ioremap_resource(&pdev->dev, res);
-	if (IS_ERR(trng->mem)) {
-		dev_err(&pdev->dev, "Could not map IO resources.\n");
+	if (IS_ERR(trng->mem))
 		return PTR_ERR(trng->mem);
-	}
 
 	pm_runtime_enable(&pdev->dev);
 	ret = pm_runtime_get_sync(&pdev->dev);