From patchwork Mon Dec 27 08:00:27 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Chan X-Patchwork-Id: 12699591 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 418E4C433EF for ; Mon, 27 Dec 2021 08:00:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231484AbhL0IAx (ORCPT ); Mon, 27 Dec 2021 03:00:53 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48460 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231146AbhL0IAw (ORCPT ); Mon, 27 Dec 2021 03:00:52 -0500 Received: from mail-ua1-x935.google.com (mail-ua1-x935.google.com [IPv6:2607:f8b0:4864:20::935]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7E0CFC06173E for ; Mon, 27 Dec 2021 00:00:52 -0800 (PST) Received: by mail-ua1-x935.google.com with SMTP id v12so13805415uar.7 for ; Mon, 27 Dec 2021 00:00:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=bX99B9F2Plzl2HdNd9guHkkpbB45Va/ck9nixgyGEMc=; b=KDgy/TKBqVidNyPgGnhnvrH49OGzYsBjNnFZqQ4PSjcWR1alwxifKrKBik+MnkPlhF tloM2mhx9dqyhVNlJnBp+v7fix/4zYGbm7JYxDAYpiL00h1zzKn33Wq7X/DoayY/RFG8 MUbCuhB8LPe3Kir6vJxD63Cp0oFpKm1ATy++w= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=bX99B9F2Plzl2HdNd9guHkkpbB45Va/ck9nixgyGEMc=; b=gSXfaA+84Zb9+JRG6cFjzvbaTV3pWP3Pp8jIZWMT1GW1yDMswX5PmJZqpvgT8/2jJc JGQVnBJ9p5/7R8lhhPsuOJCPtTcAABDaJqW1sr3MDc2DrBHoZ0WzJa8bAIlPIkVVgTNG GEA0bEtXhCx2NO38dmiT5pdJEzYrJb5ntuxHfXYQCxnHnGOM44TSUQI+IbiJrswT4Laj nR7HCA7OLB2oDKb1DswCBMaUBbTTijuL5DLKo6T8RCGepTu76rXn6AgknIltFdJtg+TU 8ln1SG0LN7jcqqfkcW4xB+SWo5Kl2n3MePVNjvjGrL+b1bmC9Ac5Icj3X5XkRK5Jv3hG jQXw== X-Gm-Message-State: AOAM53298rpg0c67SMvKlLN0FuNMEfxPYMceE1mzZXNMTOHWVseyTygk AxSG9UHZBwJILhhmAsz7WPfaMil+lwoyBU2M X-Google-Smtp-Source: ABdhPJx9wHjOUGRzB859qYuS2Nq5Giav5vRjIqfq4K7VYmAKsESUzJW2wrNoTNVT/8Ab4OTwvC1iog== X-Received: by 2002:a05:6102:3714:: with SMTP id s20mr4018500vst.3.1640592051356; Mon, 27 Dec 2021 00:00:51 -0800 (PST) Received: from localhost.swdvt.lab.broadcom.net ([192.19.223.252]) by smtp.gmail.com with ESMTPSA id o1sm2907587vkc.35.2021.12.27.00.00.50 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 27 Dec 2021 00:00:51 -0800 (PST) From: Michael Chan To: davem@davemloft.net Cc: netdev@vger.kernel.org, kuba@kernel.org, gospo@broadcom.com Subject: [PATCH net-next 2/7] bnxt_en: Log error report for dropped doorbell Date: Mon, 27 Dec 2021 03:00:27 -0500 Message-Id: <1640592032-8927-3-git-send-email-michael.chan@broadcom.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1640592032-8927-1-git-send-email-michael.chan@broadcom.com> References: <1640592032-8927-1-git-send-email-michael.chan@broadcom.com> Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org X-Patchwork-Delegate: kuba@kernel.org Log the unrecognized error report type value as well. Reviewed-by: Andy Gospodarek Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c index 11255131abbc..53101d00768c 100644 --- a/drivers/net/ethernet/broadcom/bnxt/bnxt.c +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt.c @@ -2044,7 +2044,9 @@ static u16 bnxt_agg_ring_id_to_grp_idx(struct bnxt *bp, u16 ring_id) static void bnxt_event_error_report(struct bnxt *bp, u32 data1, u32 data2) { - switch (BNXT_EVENT_ERROR_REPORT_TYPE(data1)) { + u32 err_type = BNXT_EVENT_ERROR_REPORT_TYPE(data1); + + switch (err_type) { case ASYNC_EVENT_CMPL_ERROR_REPORT_BASE_EVENT_DATA1_ERROR_TYPE_INVALID_SIGNAL: netdev_err(bp->dev, "1PPS: Received invalid signal on pin%lu from the external source. Please fix the signal and reconfigure the pin\n", BNXT_EVENT_INVALID_SIGNAL_DATA(data2)); @@ -2052,8 +2054,12 @@ static void bnxt_event_error_report(struct bnxt *bp, u32 data1, u32 data2) case ASYNC_EVENT_CMPL_ERROR_REPORT_BASE_EVENT_DATA1_ERROR_TYPE_PAUSE_STORM: netdev_warn(bp->dev, "Pause Storm detected!\n"); break; + case ASYNC_EVENT_CMPL_ERROR_REPORT_BASE_EVENT_DATA1_ERROR_TYPE_DOORBELL_DROP_THRESHOLD: + netdev_warn(bp->dev, "One or more MMIO doorbells dropped by the device!\n"); + break; default: - netdev_err(bp->dev, "FW reported unknown error type\n"); + netdev_err(bp->dev, "FW reported unknown error type %u\n", + err_type); break; } }