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 |
> -----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>
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 --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);
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(-)