Received: by 2002:a05:6a11:4021:0:0:0:0 with SMTP id ky33csp2319529pxb; Mon, 20 Sep 2021 18:42:43 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx/dzfBqPw8GSj+qg2V6lHdGC+V54I5UMBJ3AQpq/ddGm7q5Hn6XeaCaqrKWKqf2q+bsvS7 X-Received: by 2002:a02:ac01:: with SMTP id a1mr12859141jao.93.1632188562917; Mon, 20 Sep 2021 18:42:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1632188562; cv=none; d=google.com; s=arc-20160816; b=sqlcjKR3afjSqauFwSTPacngE01yymmHDhdK8YbEOBjgXlVmfgUukizTc2NHGnkw77 7FPjwHsqh8btq8pap1xy5vdaXKIFEvjuyd/AvdTe+t59Hmkw1khIWrhz9nwzJARytZqy IJDQ0Yd3HbiUIWkGw2oqgCPSX89plqfqmMUgOjarbYuEdlXGnZVYvTQKalEYz5Bpvro7 YQ0teoxXYozQYZN0vXkAgt/ZhSHuhxqyMJ27S1p594vF34cezlWXu2psSdLf4263kxCe PdscWvoZFJd9Z+iKSAUQ7Q/lFzuvnsi+UcLttA2VEFxhnKRHCEc7V/KcxgHxLooL/aae 7AGQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=pZrvC8yozdTHF7atIg9dETRzEpKyJAvs2lJbKC7/cwM=; b=aTeRewuN1CAuHAw34T8AODzGKgOP9FiVR8BEL0HfOHt8uvSDpeAkKJi5RBLV1Sp7cx noLKmK7mAUlydqk1WpLVYOdGaf2cbAGwqzusxdx3MiyprcGUX0AiHaoj3EKuNGrOxAWa qvvmrERSTLoatz9iKSXpD5uce+pyiAIHgvRv6T8D3iLxHDglwbuVpDRqgCh5y7LzDLFi rkf+z7Ptjh2S3ml4wXVDC4hUsyiCDHIhLvipf+3nURaBf26shOK6XEsq4XRD2NMPIjXq dHTas7rhQgKJySdY+e1w8T/x/rRbqxJUDjMW3gsTTpT5vgdTsbhFxyP1UTV13fwXQ/Ve YQcw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=umsLqCeQ; 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=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m1si15543199ilu.13.2021.09.20.18.42.31; Mon, 20 Sep 2021 18:42:42 -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; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=umsLqCeQ; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244538AbhITQze (ORCPT + 99 others); Mon, 20 Sep 2021 12:55:34 -0400 Received: from mail.kernel.org ([198.145.29.99]:39398 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244181AbhITQvI (ORCPT ); Mon, 20 Sep 2021 12:51:08 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 0734461213; Mon, 20 Sep 2021 16:49:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1632156567; bh=Yj1TZDy2FUjXAXfIjbZskgaCeCbx9tYsqXQSQSi/SP8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=umsLqCeQSP4SDv17meNL98mFRXoFYDHktvpG8a9YYkCJWsZW1YhptBxZcHGRFq++a IkGz/uDWdCr6gMND1hD3P7GsvMnJda7uVi+h8IMdrO9sEvG4Hp7QyvCjSSVVKLn4Mv LnVonLjzB1zaWGc8k4LhBKc1v+CIB5FPX8DjZChU= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Adrian Bunk , YunQiang Su , Shai Malin , Jakub Kicinski Subject: [PATCH 4.4 118/133] bnx2x: Fix enabling network interfaces without VFs Date: Mon, 20 Sep 2021 18:43:16 +0200 Message-Id: <20210920163916.484032500@linuxfoundation.org> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20210920163912.603434365@linuxfoundation.org> References: <20210920163912.603434365@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Adrian Bunk commit 52ce14c134a003fee03d8fc57442c05a55b53715 upstream. 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 Acked-by: Shai Malin Link: https://lore.kernel.org/r/20210912190523.27991-1-bunk@kernel.org Signed-off-by: Jakub Kicinski Signed-off-by: Greg Kroah-Hartman --- drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c +++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c @@ -1246,7 +1246,7 @@ int bnx2x_iov_init_one(struct bnx2x *bp, /* SR-IOV capability was enabled but there are no VFs*/ if (iov->total == 0) { - err = -EINVAL; + err = 0; goto failed; }