From patchwork Wed Mar 29 01:30:19 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Chan X-Patchwork-Id: 13191821 X-Patchwork-Delegate: kuba@kernel.org Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 15890C76196 for ; Wed, 29 Mar 2023 01:30:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229780AbjC2Bag (ORCPT ); Tue, 28 Mar 2023 21:30:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38044 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229484AbjC2Baf (ORCPT ); Tue, 28 Mar 2023 21:30:35 -0400 Received: from mail-qv1-xf29.google.com (mail-qv1-xf29.google.com [IPv6:2607:f8b0:4864:20::f29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 85C0210CE for ; Tue, 28 Mar 2023 18:30:34 -0700 (PDT) Received: by mail-qv1-xf29.google.com with SMTP id 59so10557254qva.11 for ; Tue, 28 Mar 2023 18:30:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; t=1680053433; h=mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:from:to:cc:subject:date:message-id:reply-to; bh=GPZ4DRLXgCe2fCIsUnM5NKh52x4WNSwBcSVU2f5xzr4=; b=KCdX7aKs9Cu4W3XoOzVJw/yb3NgyTMgFPOonjnXVM5wdq4rPrHAOW3k0IbLzcDq9c4 MmXShwVDpL1zcS2wGdSpV69M0xuJ/WWCU5YJqg5ayRoGA8rFeHQfm7NyJVZdF5gNZNDF eXsxpsdE8lwyos0gHjYvKIDWptz3CTihRO804= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1680053433; 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=GPZ4DRLXgCe2fCIsUnM5NKh52x4WNSwBcSVU2f5xzr4=; b=BxAp9fzFMHOUHwDRKFio2S4u0YidyLdfJ3hI3kfU4v9U0yarQJOHERrIDo+lBbU4+w ZVE3ALmXxtLtsijPsk6vrHROAFAx9ExneH4R10/qHHVFq2J6n4N1Sfj4u9JVqVmnd2Dj 1iEzLEk+EBYNVXoZhqKlH52JWzLdu/NY8rBhQVb64SqQf5wE4bC5hp8v7j9yXqGSjpe9 cfBCyJ1iLpYW3kekdkqArCh9epIxBkCRp5/APGTUJNNDVRIM3WZ0E9N3IILWjp3lH27A ovsA0sCvqnZ8gJh83RQOZPfBkf4RlQvkAueAhxu1ZNZQA+IOXDBDZF5AWGNDyYZJdiaU 4nbQ== X-Gm-Message-State: AAQBX9ep42/494sK2iwvaFCr92ej40Uv3O71tDI0UD+1S7V/X1QPNASs oVbUjniAc/azMa93XbVS5zYyHQ== X-Google-Smtp-Source: AKy350bz4R2euXD7wwBqM625ksg0PibzhAdDYyyo5MaOuQcIUkK/Mp69OogaSJcTO4vBSiYA4i7J7w== X-Received: by 2002:a05:6214:c6e:b0:5c2:a8b0:d71a with SMTP id t14-20020a0562140c6e00b005c2a8b0d71amr27809353qvj.43.1680053433478; Tue, 28 Mar 2023 18:30:33 -0700 (PDT) Received: from lvnvda1597.lvn.broadcom.net ([192.19.161.250]) by smtp.gmail.com with ESMTPSA id l15-20020ad4408f000000b005dd8b9345b0sm4223402qvp.72.2023.03.28.18.30.31 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Tue, 28 Mar 2023 18:30:32 -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, Kalesh AP , Pavan Chebbi , Somnath Kotur Subject: [PATCH net 1/3] bnxt_en: Fix reporting of test result in ethtool selftest Date: Tue, 28 Mar 2023 18:30:19 -0700 Message-Id: <20230329013021.5205-2-michael.chan@broadcom.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20230329013021.5205-1-michael.chan@broadcom.com> References: <20230329013021.5205-1-michael.chan@broadcom.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org X-Patchwork-Delegate: kuba@kernel.org From: Kalesh AP When the selftest command fails, driver is not reporting the failure by updating the "test->flags" when bnxt_close_nic() fails. Fixes: eb51365846bc ("bnxt_en: Add basic ethtool -t selftest support.") Reviewed-by: Pavan Chebbi Reviewed-by: Somnath Kotur Signed-off-by: Kalesh AP Signed-off-by: Michael Chan Reviewed-by: Simon Horman --- drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c b/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c index ec573127b707..7658a06b8d05 100644 --- a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c @@ -3738,6 +3738,7 @@ static void bnxt_self_test(struct net_device *dev, struct ethtool_test *etest, bnxt_ulp_stop(bp); rc = bnxt_close_nic(bp, true, false); if (rc) { + etest->flags |= ETH_TEST_FL_FAILED; bnxt_ulp_start(bp, rc); return; }