diff mbox series

net: ethernet: litex: Remove unnecessary print function dev_err()

Message ID 20211105014217.38681-1-vulab@iscas.ac.cn (mailing list archive)
State Accepted
Commit 827beb7781d3dbba1a8cd8dc364cc3cb3fc13b11
Delegated to: Netdev Maintainers
Headers show
Series net: ethernet: litex: Remove unnecessary print function dev_err() | expand

Checks

Context Check Description
netdev/fixes_present success Fixes tag not required for -next series
netdev/subject_prefix warning Target tree name not specified in the subject
netdev/cover_letter success Single patches do not need cover letters
netdev/patch_count success Link
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 0 this patch: 0
netdev/cc_maintainers warning 2 maintainers not CCed: kuba@kernel.org davem@davemloft.net
netdev/build_clang success Errors and warnings before: 0 this patch: 0
netdev/module_param success Was 0 now: 0
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/verify_fixes success No Fixes tag
netdev/build_allmodconfig_warn success Errors and warnings before: 0 this patch: 0
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 11 lines checked
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0
netdev/tree_selection success Guessing tree name failed - patch did not apply

Commit Message

Xu Wang Nov. 5, 2021, 1:42 a.m. UTC
The print function dev_err() is redundant because
platform_get_irq() already prints an error.

Signed-off-by: Xu Wang <vulab@iscas.ac.cn>
---
 drivers/net/ethernet/litex/litex_liteeth.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

Comments

Cai,Huoqing Nov. 5, 2021, 3:15 a.m. UTC | #1
On 05 11月 21 01:42:17, Xu Wang wrote:
> The print function dev_err() is redundant because
> platform_get_irq() already prints an error.
>
Reviewed-by: Cai Huoqing <caihuoqing@baidu.com>
> Signed-off-by: Xu Wang <vulab@iscas.ac.cn>
> ---
>  drivers/net/ethernet/litex/litex_liteeth.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/drivers/net/ethernet/litex/litex_liteeth.c b/drivers/net/ethernet/litex/litex_liteeth.c
> index 3d9385a4989b..ab9fa1525053 100644
> --- a/drivers/net/ethernet/litex/litex_liteeth.c
> +++ b/drivers/net/ethernet/litex/litex_liteeth.c
> @@ -242,10 +242,8 @@ static int liteeth_probe(struct platform_device *pdev)
>  	priv->dev = &pdev->dev;
>  
>  	irq = platform_get_irq(pdev, 0);
> -	if (irq < 0) {
> -		dev_err(&pdev->dev, "Failed to get IRQ %d\n", irq);
> +	if (irq < 0)
>  		return irq;
> -	}
>  	netdev->irq = irq;
>  
>  	priv->base = devm_platform_ioremap_resource_byname(pdev, "mac");
> -- 
> 2.25.1
>
patchwork-bot+netdevbpf@kernel.org Nov. 5, 2021, 10:20 a.m. UTC | #2
Hello:

This patch was applied to netdev/net.git (master)
by David S. Miller <davem@davemloft.net>:

On Fri,  5 Nov 2021 01:42:17 +0000 you wrote:
> The print function dev_err() is redundant because
> platform_get_irq() already prints an error.
> 
> Signed-off-by: Xu Wang <vulab@iscas.ac.cn>
> ---
>  drivers/net/ethernet/litex/litex_liteeth.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)

Here is the summary with links:
  - net: ethernet: litex: Remove unnecessary print function dev_err()
    https://git.kernel.org/netdev/net/c/827beb7781d3

You are awesome, thank you!
diff mbox series

Patch

diff --git a/drivers/net/ethernet/litex/litex_liteeth.c b/drivers/net/ethernet/litex/litex_liteeth.c
index 3d9385a4989b..ab9fa1525053 100644
--- a/drivers/net/ethernet/litex/litex_liteeth.c
+++ b/drivers/net/ethernet/litex/litex_liteeth.c
@@ -242,10 +242,8 @@  static int liteeth_probe(struct platform_device *pdev)
 	priv->dev = &pdev->dev;
 
 	irq = platform_get_irq(pdev, 0);
-	if (irq < 0) {
-		dev_err(&pdev->dev, "Failed to get IRQ %d\n", irq);
+	if (irq < 0)
 		return irq;
-	}
 	netdev->irq = irq;
 
 	priv->base = devm_platform_ioremap_resource_byname(pdev, "mac");