Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp3938290pxj; Mon, 21 Jun 2021 09:46:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwzE4JYE6NWQEbF+0jaIYPD8Z5yMryqJvyGoqyfVNOVTBkGSgzzQ2nthR1vv/hCBz5L7BBZ X-Received: by 2002:a05:6602:2048:: with SMTP id z8mr20444129iod.91.1624294004738; Mon, 21 Jun 2021 09:46:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1624294004; cv=none; d=google.com; s=arc-20160816; b=seVsKWyQXJVgDjPDupeV+TMYegCYnrq7MIfOzwUbrX/62FRa+V33/TDO/U5gRwptP+ kEPFYO7eeg77UUyJmhO49IVPrMGtnlta2P5MtbNy6bEAK3aCxL97jgcPeB82XnDeZHj2 putAqotfVvIgQEUtbQYgL9CDfzyZ6k2VYGaxhUXNZGR2L1+jaZ/gb85BnU/1gT8ywW1V tRp7HcmyYDzA6vC/kzFbMVldnr1SyMalS6yFZL30wYjULdstrpqC9QjI0QV0WJEn7XCe fg4Jnkfxa8dJdMO1Lh9VevkzcTVmi9ghQt5XD9bA0+JSAViKElngJuhVn149LuNS4i4d Mj2Q== 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=GjlC2WS4GyL1Nalll2w7Dviyh3zBKvnacYnIWIhP2R4=; b=0JNU0BIoSHFCyU88JzS+dSJh8SG88LfDzkWskvm6EtfCBrab/eFCGLE2k1eqIL9zFk 7N60mOtkYq66Uh/Hj0+TmKVgh+MY5lxy4YMS1xkZ/KJ6054ODgmx8FT0bf9ektzmvuG4 GK1rr/A0tapnxraFE0rivwZBiN2aHG6+9SsJptormanMFFfsKmblhl84FUwj+sEi+rwG NTw+IAV+mU6yMjiEhOqWgy9kJvT2AL1rig2iwQgMRvaDR9NAcxnTpSdXoQZvaIxS3813 EpZMdKzZsLFoixrqeK5w3hoTlpuJhvD7fxjpiEO0hEqqwJnDCXG6T+qRTI+czTPfsiaS IZZg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Jf5WORZ+; 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 i17si11930462ilk.46.2021.06.21.09.46.31; Mon, 21 Jun 2021 09:46:44 -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=Jf5WORZ+; 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 S230327AbhFUQqy (ORCPT + 99 others); Mon, 21 Jun 2021 12:46:54 -0400 Received: from mail.kernel.org ([198.145.29.99]:33932 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232280AbhFUQlo (ORCPT ); Mon, 21 Jun 2021 12:41:44 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 3D44E61352; Mon, 21 Jun 2021 16:30:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1624293059; bh=UOV2rV+eZq7OoKwtQBu7udLjaoOc8W91F5IlMxF7FlQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Jf5WORZ+XzPPZHIWeVp7S0hb/ROQnJ4Gs0H+iJ4qta4+NYQKNninhEJDUocFWW4in KdoJLMO2JkotZWbPvZwY/4gB+XRw2qkLJwgF48+EUrCgH0bhfccBuv4/Sl1WD2gyfY mdOzlNUmSSzcf+nhJRFFewopdH+o/25xk1b93Snw= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Michael Chan , "David S. Miller" , Sasha Levin Subject: [PATCH 5.12 083/178] bnxt_en: Rediscover PHY capabilities after firmware reset Date: Mon, 21 Jun 2021 18:14:57 +0200 Message-Id: <20210621154925.463862644@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210621154921.212599475@linuxfoundation.org> References: <20210621154921.212599475@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: Michael Chan [ Upstream commit 0afd6a4e8028cc487c240b6cfe04094e45a306e4 ] There is a missing bnxt_probe_phy() call in bnxt_fw_init_one() to rediscover the PHY capabilities after a firmware reset. This can cause some PHY related functionalities to fail after a firmware reset. For example, in multi-host, the ability for any host to configure the PHY settings may be lost after a firmware reset. Fixes: ec5d31e3c15d ("bnxt_en: Handle firmware reset status during IF_UP.") Signed-off-by: Michael Chan Signed-off-by: David S. Miller Signed-off-by: Sasha Levin --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c index 027997c711ab..e9ac20c1c389 100644 --- a/drivers/net/ethernet/broadcom/bnxt/bnxt.c +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt.c @@ -11573,6 +11573,8 @@ static void bnxt_fw_init_one_p3(struct bnxt *bp) bnxt_hwrm_coal_params_qcaps(bp); } +static int bnxt_probe_phy(struct bnxt *bp, bool fw_dflt); + static int bnxt_fw_init_one(struct bnxt *bp) { int rc; @@ -11587,6 +11589,9 @@ static int bnxt_fw_init_one(struct bnxt *bp) netdev_err(bp->dev, "Firmware init phase 2 failed\n"); return rc; } + rc = bnxt_probe_phy(bp, false); + if (rc) + return rc; rc = bnxt_approve_mac(bp, bp->dev->dev_addr, false); if (rc) return rc; -- 2.30.2