[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180304175713.25a44ac6@cakuba.netronome.com>
Date: Sun, 4 Mar 2018 17:57:13 -0800
From: Jakub Kicinski <jakub.kicinski@...ronome.com>
To: Arushi Singhal <arushisinghal19971997@...il.com>
Cc: jdmason@...zu.us, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, oss-drivers@...ronome.com,
outreachy-kernel@...glegroups.com
Subject: Re: [PATCH v2] net: ethernet: Drop unnecessary continue
On Sat, 3 Mar 2018 21:44:56 +0530, Arushi Singhal wrote:
> diff --git a/drivers/net/ethernet/netronome/nfp/nfp_net_main.c b/drivers/net/ethernet/netronome/nfp/nfp_net_main.c
> index 15fa47f..5cd4f3f 100644
> --- a/drivers/net/ethernet/netronome/nfp/nfp_net_main.c
> +++ b/drivers/net/ethernet/netronome/nfp/nfp_net_main.c
> @@ -258,10 +258,8 @@ nfp_net_pf_alloc_vnics(struct nfp_pf *pf, void __iomem *ctrl_bar,
> ctrl_bar += NFP_PF_CSR_SLICE_SIZE;
>
> /* Kill the vNIC if app init marked it as invalid */
> - if (nn->port && nn->port->type == NFP_PORT_INVALID) {
> + if (nn->port && nn->port->type == NFP_PORT_INVALID)
> nfp_net_pf_free_vnic(pf, nn);
> - continue;
> - }
This is an error handling path so the continue makes sense here to
indicate the processing can't ever fall through if more statements are
ever added to the loop. But OK.
> }
>
> if (list_empty(&pf->vnics))
Powered by blists - more mailing lists