Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp5050286ybe; Tue, 17 Sep 2019 01:33:53 -0700 (PDT) X-Google-Smtp-Source: APXvYqwLrzSqsm3D5Ee5SUuKbxVS32bVep9tNxAA4H1esxQNfzChWhtTnDT8lrQOeb4sXYJod2lz X-Received: by 2002:a17:906:2311:: with SMTP id l17mr3679569eja.12.1568709232912; Tue, 17 Sep 2019 01:33:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568709232; cv=none; d=google.com; s=arc-20160816; b=S7pQzA4DcPfgBBswbFeWBhXmRrCGoZ2HpDGxW4Wm7+NutBr26H0L0Vhsu98ICK2bvu HSK0LDj6jQN7jFjaIa2BilrnsQT/OLht6NSu6siuO20bFc2CDtvrQDbxD6Y//xaoXBaz 2tL2fP48j4jl14I0tA22+cc4m4RkFhI2xQswwIkMerKzXcldULJtUDjn9PRG3vGgE24U lyaC8W7wplx/yHDGqaypKjmSOar4j+6nSm8ypfA3qLKUkOSm1FdxPjiTRhERjopRFoml oR59o5dE1IREtUyhym8YodP8RfAvpr4ih69AQ6V0NYBmy1C0SvNZh/NplzPW5msFJxnc zmzA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date:dkim-signature; bh=QJL+aqYGZOzi+1S1uVjyRsVzuSiyBunq1zPtSdS5Ngk=; b=fg0t1IY/FDPKHOt4HFLABQIa1YwPB/YicDwjgUM6gIjxqfuGx/c6iYpSomtwJ7vypJ AbaIK25tjhnGcy7RhjV16eH6J0aS4aRqYJQ03m1nPc3iHa6rrZHPV00pl+CYtmGrd59g HJz/1nzUCLrwT1aLVVr534Jg9Jtmr3rLjxXubpUoD41kxBoxMdyscaGUwa+NCP/vew9R Z36v1TdkGVgfVP7qjXpZcoFwZfprkd4cFW76DU+nXLv3f0AsafGSbnVw40bZ12/TTGRt MNb0D+Ch+v97RppnJ0qV3/Ovfpiicx687eHZAMK4u1TrfSeNe+VTEzOHX3ocFt/MB52g XRPQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@netronome-com.20150623.gappssmtp.com header.s=20150623 header.b=Rz68VtLW; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l3si934825edc.109.2019.09.17.01.33.29; Tue, 17 Sep 2019 01:33:52 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@netronome-com.20150623.gappssmtp.com header.s=20150623 header.b=Rz68VtLW; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2392029AbfIQCpH (ORCPT + 99 others); Mon, 16 Sep 2019 22:45:07 -0400 Received: from mail-pg1-f193.google.com ([209.85.215.193]:36246 "EHLO mail-pg1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729186AbfIQCpH (ORCPT ); Mon, 16 Sep 2019 22:45:07 -0400 Received: by mail-pg1-f193.google.com with SMTP id m29so1156365pgc.3 for ; Mon, 16 Sep 2019 19:45:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=netronome-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :organization:mime-version:content-transfer-encoding; bh=QJL+aqYGZOzi+1S1uVjyRsVzuSiyBunq1zPtSdS5Ngk=; b=Rz68VtLWPZve67DrfVuadUoQESUa/AG3FLXnc1mEM/oGiyx7RvQUip+zD8MQFeNf28 VEhhRInbuOaFMUT31f7om6pr70JSKpzjFNnqn+dbYGgKZLNzCtE5/RHxLN0kA/dUv34R RgDXH/lF0ynANJsinx49g1DdmV5XA3Kv/RBykEeawam3G4HGo7tJEi1XoldqK7K+JQEp watvx1kvG/qJGKC76rWIdzqLJkUQ7MXqjZbbvSzV22xVXJPMd7fDIguidj4U3EGd/0Ny TUJBtLtmD25QrJvZZ3MoxipyDnQc0ZZeoT4AOKIQwXGfRv3Ckfqeii/LtepH3BJEC2xv sUyg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:organization:mime-version:content-transfer-encoding; bh=QJL+aqYGZOzi+1S1uVjyRsVzuSiyBunq1zPtSdS5Ngk=; b=R81lZuFpe1Il3mLEr6bwVszjUpOhOPsySFxRMevPhFVfKm4Tt++0VzoTkpJf9fsBCb TkjEScuqlW4SrGJEUHbJE4r6kpx5T6k3V2whijkKuscMctQRq8EciQfEtCwHfvJ1RW5w MkJI9SD18oUzibPLDYItgcCUi7pQBKxucNtr3FCjRA1h/OBfu/hp4ccel+CbjbuezR+B 6+3ZdiWUt+og4LbyamUEhOxJoQHMBC2uCGt8B9unNzd5hiGerpvlt35UjRyuCJr9aA6z DhhN4uxhDlzx1BDvmIE3n0U0Sg4zEx3781VByICaANwEDLsrlkGW2f974XRv4cKA8hDd CSGQ== X-Gm-Message-State: APjAAAXIukxSJ41wV6ZUbjuSI9DQT8nRID8qHNvIMGNUvjHk9EiEI4YY +grevk9l1St4gF+1m0luf3ysdg== X-Received: by 2002:a17:90a:f48f:: with SMTP id bx15mr2543032pjb.75.1568688305762; Mon, 16 Sep 2019 19:45:05 -0700 (PDT) Received: from cakuba.netronome.com ([2601:646:8e00:e18::2]) by smtp.gmail.com with ESMTPSA id j10sm507304pjn.3.2019.09.16.19.45.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Sep 2019 19:45:05 -0700 (PDT) Date: Mon, 16 Sep 2019 19:45:02 -0700 From: Jakub Kicinski To: zhong jiang Cc: , , , , Subject: Re: [PATCH 2/3] nfp: Drop unnecessary continue in nfp_net_pf_alloc_vnics Message-ID: <20190916194502.0c014667@cakuba.netronome.com> In-Reply-To: <1567568784-9669-3-git-send-email-zhongjiang@huawei.com> References: <1567568784-9669-1-git-send-email-zhongjiang@huawei.com> <1567568784-9669-3-git-send-email-zhongjiang@huawei.com> Organization: Netronome Systems, Ltd. MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 4 Sep 2019 11:46:23 +0800, zhong jiang wrote: > Continue is not needed at the bottom of a loop. > > Signed-off-by: zhong jiang > --- > drivers/net/ethernet/netronome/nfp/nfp_net_main.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) > > diff --git a/drivers/net/ethernet/netronome/nfp/nfp_net_main.c b/drivers/net/ethernet/netronome/nfp/nfp_net_main.c > index 986464d..68db47d 100644 > --- a/drivers/net/ethernet/netronome/nfp/nfp_net_main.c > +++ b/drivers/net/ethernet/netronome/nfp/nfp_net_main.c > @@ -205,10 +205,8 @@ static void nfp_net_pf_free_vnics(struct nfp_pf *pf) > 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; > - } Ugh, I already nack at least one patch like this, this continue makes the _intent_ of the code more clear, the compiler will ignore it anyway. I guess there's no use in fighting the bots.. > } > > if (list_empty(&pf->vnics))