From patchwork Wed Jun 7 07:54:05 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Chan X-Patchwork-Id: 13270119 X-Patchwork-Delegate: kuba@kernel.org Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net [23.128.96.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E76507465 for ; Wed, 7 Jun 2023 07:54:46 +0000 (UTC) Received: from mail-qv1-xf35.google.com (mail-qv1-xf35.google.com [IPv6:2607:f8b0:4864:20::f35]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3690812C for ; Wed, 7 Jun 2023 00:54:45 -0700 (PDT) Received: by mail-qv1-xf35.google.com with SMTP id 6a1803df08f44-62615694bb9so48057556d6.0 for ; Wed, 07 Jun 2023 00:54:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; t=1686124484; x=1688716484; h=mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:from:to:cc:subject:date:message-id:reply-to; bh=0OufplTNJwSbnUq24EenH4KnxC2gWFpCoV7GUxnomWc=; b=RQcfD/mZzArj4G1bxpQwSZ75oN6/7SGRTUFlVp7OM6xIwf3K4wpRVkIsL5hgZeHgYL PyUC8VWIPYtwOZPBk9k+tNuxvCN7qMOevshwDF4oTisaThzpD0Kbtv/zu5Q7udtuuZg9 ug5xJXYogVcfmH5rkEfo/CKqpXZ5CXCGLQkUk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1686124484; x=1688716484; h=mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=0OufplTNJwSbnUq24EenH4KnxC2gWFpCoV7GUxnomWc=; b=Z/fdmrR2DIqQ5E1rXVm/pAhR8Lcv9smA4CPPA1TdFZkKrZ88rSWcf6hJZ63Ismp2g7 6W/ptGPymWf1DIisZowehP+jb4Q+e+Eq14jImDK1IggOhSWY1FEsgHxmYDZsxW20izjM ikVMX3YH9/xJhz1KceqzZs7VLhTujLF6KL2liVLdjNRAC2cxtK1LYPkw4P7m+FbwY4Ye uWZ6Dq9cz01jDN/zxYWZRC3uNVgX8djoGgSqsqyYnPpIz7BYpD515UeBWJPVngAY+PBp eB7dQwqsLMsB0aY0ktopivBIzIko++pEtBJrpK/gn5nVvJ5N3QN3GcdGCrVAwvM4cQWh vUQQ== X-Gm-Message-State: AC+VfDw7Km9Eq7M+bK5RzINMYtpcLVSvdEsuWd2fM06ac4nSbFdfjMQh ip4BmoIgvxr0AniD2JTmRyXseQ== X-Google-Smtp-Source: ACHHUZ6PEPP2YRej8grIx9ouO8QIocDF8HdTwOTckZA7VBkv+0stWBKGJ682b2wu8POHl10zRiFQig== X-Received: by 2002:a05:6214:d0a:b0:626:17b2:5583 with SMTP id 10-20020a0562140d0a00b0062617b25583mr2114271qvh.0.1686124484123; Wed, 07 Jun 2023 00:54:44 -0700 (PDT) Received: from lvnvda5233.lvn.broadcom.net ([192.19.161.250]) by smtp.gmail.com with ESMTPSA id cs12-20020ad44c4c000000b00626362f1bf1sm5850817qvb.63.2023.06.07.00.54.42 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 07 Jun 2023 00:54:43 -0700 (PDT) From: Michael Chan To: davem@davemloft.net Cc: netdev@vger.kernel.org, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, gospo@broadcom.com, Sreekanth Reddy , Pavan Chebbi Subject: [PATCH net 2/6] bnxt_en: Don't issue AP reset during ethtool's reset operation Date: Wed, 7 Jun 2023 00:54:05 -0700 Message-Id: <20230607075409.228450-3-michael.chan@broadcom.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20230607075409.228450-1-michael.chan@broadcom.com> References: <20230607075409.228450-1-michael.chan@broadcom.com> Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net X-Patchwork-Delegate: kuba@kernel.org From: Sreekanth Reddy Only older NIC controller's firmware uses the PROC AP reset type. Firmware on 5731X/5741X and newer chips does not support this reset type. When bnxt_reset() issues a series of resets, this PROC AP reset may actually fail on these newer chips because the firmware is not ready to accept this unsupported command yet. Avoid this unnecessary error by skipping this reset type on chips that don't support it. Fixes: 7a13240e3718 ("bnxt_en: fix ethtool_reset_flags ABI violations") Reviewed-by: Pavan Chebbi Signed-off-by: Sreekanth Reddy Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c b/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c index 2dd8ee4a6f75..8fd5071d8b09 100644 --- a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c @@ -3831,7 +3831,7 @@ static int bnxt_reset(struct net_device *dev, u32 *flags) } } - if (req & BNXT_FW_RESET_AP) { + if (!BNXT_CHIP_P4_PLUS(bp) && (req & BNXT_FW_RESET_AP)) { /* This feature is not supported in older firmware versions */ if (bp->hwrm_spec_code >= 0x10803) { if (!bnxt_firmware_reset_ap(dev)) {