Received: by 2002:a05:6a10:c7c6:0:0:0:0 with SMTP id h6csp1810184pxy; Mon, 2 Aug 2021 10:44:37 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxFasUVbr8JYfpJM5l/JhnHP9+4EPlWSXrYlWuPo0xaMTPiaKgVEs/c14qrMYz0X57ogssi X-Received: by 2002:a17:906:9a51:: with SMTP id aj17mr16304604ejc.296.1627926277158; Mon, 02 Aug 2021 10:44:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1627926277; cv=none; d=google.com; s=arc-20160816; b=mqFcj8PyxSTZWjo9Rab/M4fyIildguNbt3ZvaV8Bo3wf3SNp2JkoiKY7w6ZLfDJvIo l5s7tcBQq5s6rHEGFz9tkinA8fIY/Bqiw+kF1VKv54v8LSoP8MbIFCXuqrrEJn6Taebs zP70wKw0DDSCL/K1E0ESalSHGihRqSlQcWs2vqqzuy+prLjmKf6D4Czt2qnIRL3Gffdl sApb2gmmZfJvHknOhtufrrku3TjEHYMyl4tBaDylpeAV9OvR/2ICSBYUbSlqEzh5W7Yy 7MEYrEmcctbWvj1a0J4Xe7us9ksKLci/k6QN4HaiQKXSwjq1tgCRkb/xa4cPpJviWfIv wTsw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=tquKXQQBI85AjxtSFl4eX1K8ivQZ3BQ5WYE90BcjoXg=; b=lVQxpl/hIU0SDJqRmYVfTSFH02xWZxqEyQkdfxO4R4EZIZvRlQSGMC0rtCgxlXg8xs lFrpQkf/eMJXFk7ZQ7FYNvgOYf74F+2WA1uIxVz9xMZRsvvZC2/gb8PLyowZ/jSXg27C sOEgpmy9dO993RH0fy92Bi2h/2ZRakykVOqmeS1hjp6l4OpPeZnfLX49rFkLrllznx41 iuTe5QFPXE05Ls6nH9mlL0U9N2Scnc4gVoyOb00AGFGpoHVEarO3pexSeyPzuGduFhp/ cY8A10DnzwDTNxzCCY33r8kh6wkxvOVATgxB5mIKmoBwsZu3Gq44lCiBDb9fcEOtbMG8 AV1A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id p5si10082899ejx.78.2021.08.02.10.44.13; Mon, 02 Aug 2021 10:44:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229716AbhHBRkz (ORCPT + 99 others); Mon, 2 Aug 2021 13:40:55 -0400 Received: from jabberwock.ucw.cz ([46.255.230.98]:50402 "EHLO jabberwock.ucw.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229567AbhHBRky (ORCPT ); Mon, 2 Aug 2021 13:40:54 -0400 Received: by jabberwock.ucw.cz (Postfix, from userid 1017) id B81B11C0B76; Mon, 2 Aug 2021 19:40:43 +0200 (CEST) Date: Mon, 2 Aug 2021 19:40:42 +0200 From: Pavel Machek To: Greg Kroah-Hartman Cc: linux-kernel@vger.kernel.org, stable@vger.kernel.org, Geetha sowjanya , Sunil Kovvuri Goutham , "David S. Miller" , Sasha Levin Subject: Re: [PATCH 5.10 45/67] octeontx2-pf: Fix interface down flag on error Message-ID: <20210802174042.GA26978@amd> References: <20210802134339.023067817@linuxfoundation.org> <20210802134340.561715991@linuxfoundation.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="KsGdsel6WgEHnImy" Content-Disposition: inline In-Reply-To: <20210802134340.561715991@linuxfoundation.org> User-Agent: Mutt/1.5.23 (2014-03-12) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --KsGdsel6WgEHnImy Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi! > This patch fixes the issue by setting the INTF_DOWN flag on > error and free the resources in otx2_stop only if the flag is > not set. Ok. ernet/marvell/octeontx2/nic/otx2_ethtool.c > index 662fb80dbb9d..c6d408de0605 100644 > --- a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_ethtool.c > +++ b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_ethtool.c > @@ -230,15 +230,14 @@ static int otx2_set_channels(struct net_device *dev, > err =3D otx2_set_real_num_queues(dev, channel->tx_count, > channel->rx_count); > if (err) > - goto fail; > + return err; > But with the new flag, this change is not neccessary, right? Plus, it will lead to surprising result of otx2_set_channels() downing interface on failure, no? > pfvf->hw.rx_queues =3D channel->rx_count; > pfvf->hw.tx_queues =3D channel->tx_count; > pfvf->qset.cq_cnt =3D pfvf->hw.tx_queues + pfvf->hw.rx_queues; > =20 > -fail: > if (if_up) > - dev->netdev_ops->ndo_open(dev); > + err =3D dev->netdev_ops->ndo_open(dev); Best regards, Pavel --=20 DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany --KsGdsel6WgEHnImy Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iEYEARECAAYFAmEILhoACgkQMOfwapXb+vKktQCfe506Iq2SZQREkipDcqLbyZlj fNEAni6O4PzXunUBbIBzyuea7ULK5bZn =XtTo -----END PGP SIGNATURE----- --KsGdsel6WgEHnImy--