diff mbox series

[net-next] net: lan966x: Fix duplicate check in frame extraction

Message ID 20211201145351.152208-1-horatiu.vultur@microchip.com (mailing list archive)
State Accepted
Commit a290cf692779ccce6dbb05398fad32d035bfd313
Delegated to: Netdev Maintainers
Headers show
Series [net-next] net: lan966x: Fix duplicate check in frame extraction | expand

Checks

Context Check Description
netdev/tree_selection success Clearly marked for net-next
netdev/fixes_present success Fixes tag not required for -next series
netdev/subject_prefix success Link
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 success CCed 5 of 5 maintainers
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 Fixes tag looks correct
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

Commit Message

Horatiu Vultur Dec. 1, 2021, 2:53 p.m. UTC
The blamed commit generates the following smatch static checker warning:

 drivers/net/ethernet/microchip/lan966x/lan966x_main.c:515 lan966x_xtr_irq_handler()
         warn: duplicate check 'sz < 0' (previous on line 502)

This patch fixes this issue removing the duplicate check 'sz < 0'

Fixes: d28d6d2e37d10d ("net: lan966x: add port module support")
Signed-off-by: Horatiu Vultur <horatiu.vultur@microchip.com>
---
 drivers/net/ethernet/microchip/lan966x/lan966x_main.c | 5 -----
 1 file changed, 5 deletions(-)

Comments

patchwork-bot+netdevbpf@kernel.org Dec. 2, 2021, 12:20 p.m. UTC | #1
Hello:

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

On Wed, 1 Dec 2021 15:53:51 +0100 you wrote:
> The blamed commit generates the following smatch static checker warning:
> 
>  drivers/net/ethernet/microchip/lan966x/lan966x_main.c:515 lan966x_xtr_irq_handler()
>          warn: duplicate check 'sz < 0' (previous on line 502)
> 
> This patch fixes this issue removing the duplicate check 'sz < 0'
> 
> [...]

Here is the summary with links:
  - [net-next] net: lan966x: Fix duplicate check in frame extraction
    https://git.kernel.org/netdev/net-next/c/a290cf692779

You are awesome, thank you!
diff mbox series

Patch

diff --git a/drivers/net/ethernet/microchip/lan966x/lan966x_main.c b/drivers/net/ethernet/microchip/lan966x/lan966x_main.c
index e9e4dca6542d..be5e2b3a7f43 100644
--- a/drivers/net/ethernet/microchip/lan966x/lan966x_main.c
+++ b/drivers/net/ethernet/microchip/lan966x/lan966x_main.c
@@ -512,11 +512,6 @@  static irqreturn_t lan966x_xtr_irq_handler(int irq, void *args)
 			*buf = val;
 		}
 
-		if (sz < 0) {
-			err = sz;
-			break;
-		}
-
 		skb->protocol = eth_type_trans(skb, dev);
 
 		netif_rx_ni(skb);