Received: by 2002:a05:6a10:6d25:0:0:0:0 with SMTP id gq37csp1794677pxb; Mon, 13 Sep 2021 05:48:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxKikUIdDmM0rM99jf4YptQRzXnkdmXZvXH65fbH7tyMR8YlUXiwUtb0fRKSQSudFTDl1HY X-Received: by 2002:a02:711e:: with SMTP id n30mr9581132jac.3.1631537319224; Mon, 13 Sep 2021 05:48:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631537319; cv=none; d=google.com; s=arc-20160816; b=GUKdB/NUEhZbFZaskEL2uXJdw1vjZ2Z+gWuy8RJkSKQbkAzYtgCqXH92zwo0aMt4Hs dnQ0h0cjhhRdpi/nzPNVD+fV7lcIzpZy5n0Hmt3G3XTxBHDt0GwdD1TUdgWxhDD5hgCZ 1mtjkHygScpKUM2P5BRvmYq7xvfumbZsRPkrx5Fo2CAZSwCA4+roONRtZgZsieloNg6R 1Xo8xTrWqBmgZ6c0nqcvGfZEEUdxtLIw9msNc9iSKwug/5AyxfppF4oGEcJjfgdP5fHi PyZzLaxj22+kMeUYAqTOC9Ny2kvc4sbWvMTw8e/0Es4r91habLCCSinmgNt7iwTeYCZj UroA== 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=46hBwN/oYiBRLv9e1k/+KQDKTvL7fep1stjBY8a/K+Q=; b=F+/8AWmE9b0oknQ4AguOZkoUeE8M8HF70v6rW9APXjKc4M9+p2haBTGx4u0ZoiGxyx EEt5pBQGmDntoWGHD8FZy5f8YxZs9kUPkqfxKtP3oEWi3iCCXvUVn/lLYWJGVtFtFuE/ e023t/bOPss2GBylFTNhPY97DvsrN7zgGAaN6CQHrrQrPQonDs5x9dbUhsVE3JYuo00h f5ZxD6AhHqOx8gTwdZPda6vCUppGy6OHJubH6zxX+HYfwZUPX4oDLHg9qGvStRl7JoRv OOjy5bTm3s8cZSydqHPLLBrOzxyC4oRoMzUB+7LzjzrBDtHybA+7Yl8SIrJ07+CNvgqL +i1A== 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q22si6310020jae.93.2021.09.13.05.48.28; Mon, 13 Sep 2021 05:48:39 -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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239187AbhIMKvq (ORCPT + 99 others); Mon, 13 Sep 2021 06:51:46 -0400 Received: from mail.stusta.mhn.de ([141.84.69.5]:57596 "EHLO mail.stusta.mhn.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238690AbhIMKvq (ORCPT ); Mon, 13 Sep 2021 06:51:46 -0400 X-Greylist: delayed 505 seconds by postgrey-1.27 at vger.kernel.org; Mon, 13 Sep 2021 06:51:45 EDT Received: from [127.0.0.1] (localhost [127.0.0.1]) by mail.stusta.mhn.de (Postfix) with ESMTPSA id 4H7NMS5XB0z1cv; Mon, 13 Sep 2021 12:41:56 +0200 (CEST) Date: Mon, 13 Sep 2021 13:41:54 +0300 From: Adrian Bunk To: Shai Malin Cc: Ariel Elior , Sudarsana Reddy Kalluru , GR-everest-linux-l2 , "netdev@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH] bnx2x: Fix enabling network interfaces without VFs Message-ID: <20210913104154.GT11834@localhost> References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Sep 13, 2021 at 08:14:33AM +0000, Shai Malin wrote: > On 9/12/2021 at 10:08PM, Adrian Bunk Wrote: > > This function is called to enable SR-IOV when available, > > not enabling interfaces without VFs was a regression. > > > > Fixes: 65161c35554f ("bnx2x: Fix missing error code in bnx2x_iov_init_one()") > > Signed-off-by: Adrian Bunk > > Reported-by: YunQiang Su > > Tested-by: YunQiang Su > > Cc: stable@vger.kernel.org > > --- > > drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c > > b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c > > index f255fd0b16db..6fbf735fca31 100644 > > --- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c > > +++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c > > @@ -1224,7 +1224,7 @@ int bnx2x_iov_init_one(struct bnx2x *bp, int > > int_mode_param, > > > > /* SR-IOV capability was enabled but there are no VFs*/ > > if (iov->total == 0) { > > - err = -EINVAL; > > + err = 0; > > goto failed; > > } > > Thanks for reporting this issue! > But the complete fix should also not use "goto failed". > Instead, please create a new "goto skip_vfs" so it will skip > the log of "Failed err=". Is this really desirable? It is a debug print not enabled by default, and trying to enable SR-IOV did fail. cu Adrian