diff mbox series

net: netvsc: remove break after return

Message ID 1646933534-29493-1-git-send-email-ssengar@linux.microsoft.com (mailing list archive)
State Accepted
Commit 8cf5ab362dce8acff7d2d28a967cdb2d8e9f7b13
Delegated to: Netdev Maintainers
Headers show
Series net: netvsc: remove break after return | 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 success CCed 9 of 9 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 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, 7 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

Saurabh Singh Sengar March 10, 2022, 5:32 p.m. UTC
In function netvsc_process_raw_pkt for VM_PKT_DATA_USING_XFER_PAGES
case there is already a 'return' statement which results 'break'
as dead code

Signed-off-by: Saurabh Sengar <ssengar@linux.microsoft.com>
---
 drivers/net/hyperv/netvsc.c | 1 -
 1 file changed, 1 deletion(-)

Comments

Haiyang Zhang March 10, 2022, 6:06 p.m. UTC | #1
> -----Original Message-----
> From: Saurabh Sengar <ssengar@linux.microsoft.com>
> Sent: Thursday, March 10, 2022 12:32 PM
> To: Saurabh Singh Sengar <ssengar@microsoft.com>; Haiyang Zhang <haiyangz@microsoft.com>;
> KY Srinivasan <kys@microsoft.com>; Stephen Hemminger <sthemmin@microsoft.com>;
> wei.liu@kernel.org; Dexuan Cui <decui@microsoft.com>; davem@davemloft.net; kuba@kernel.org;
> linux-hyperv@vger.kernel.org; netdev@vger.kernel.org; linux-kernel@vger.kernel.org
> Subject: [PATCH] net: netvsc: remove break after return
> 
> In function netvsc_process_raw_pkt for VM_PKT_DATA_USING_XFER_PAGES
> case there is already a 'return' statement which results 'break'
> as dead code
> 
> Signed-off-by: Saurabh Sengar <ssengar@linux.microsoft.com>
> ---
>  drivers/net/hyperv/netvsc.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
> index e675d10..9442f75 100644
> --- a/drivers/net/hyperv/netvsc.c
> +++ b/drivers/net/hyperv/netvsc.c
> @@ -1630,7 +1630,6 @@ static int netvsc_process_raw_pkt(struct hv_device *device,
> 
>  	case VM_PKT_DATA_USING_XFER_PAGES:
>  		return netvsc_receive(ndev, net_device, nvchan, desc);
> -		break;
> 
>  	case VM_PKT_DATA_INBAND:

Thanks.
Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
patchwork-bot+netdevbpf@kernel.org March 12, 2022, 7 a.m. UTC | #2
Hello:

This patch was applied to netdev/net-next.git (master)
by Jakub Kicinski <kuba@kernel.org>:

On Thu, 10 Mar 2022 09:32:14 -0800 you wrote:
> In function netvsc_process_raw_pkt for VM_PKT_DATA_USING_XFER_PAGES
> case there is already a 'return' statement which results 'break'
> as dead code
> 
> Signed-off-by: Saurabh Sengar <ssengar@linux.microsoft.com>
> ---
>  drivers/net/hyperv/netvsc.c | 1 -
>  1 file changed, 1 deletion(-)

Here is the summary with links:
  - net: netvsc: remove break after return
    https://git.kernel.org/netdev/net-next/c/8cf5ab362dce

You are awesome, thank you!
diff mbox series

Patch

diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
index e675d10..9442f75 100644
--- a/drivers/net/hyperv/netvsc.c
+++ b/drivers/net/hyperv/netvsc.c
@@ -1630,7 +1630,6 @@  static int netvsc_process_raw_pkt(struct hv_device *device,
 
 	case VM_PKT_DATA_USING_XFER_PAGES:
 		return netvsc_receive(ndev, net_device, nvchan, desc);
-		break;
 
 	case VM_PKT_DATA_INBAND:
 		netvsc_receive_inband(ndev, net_device, desc);