Message ID | 3dcae9413c511de10304421665bd57f47427a4a0.1533656958.git.petrm@mellanox.com (mailing list archive) |
---|---|
State | Accepted |
Delegated to: | Ido Schimmel |
Headers | show
Return-Path: <linux-mlxsw-bounces+patchwork-linux-mlxsw=patchwork.kernel.org@lists.ozlabs.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 9AF071057 for <patchwork-linux-mlxsw@patchwork.kernel.org>; Tue, 7 Aug 2018 15:53:38 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8806328707 for <patchwork-linux-mlxsw@patchwork.kernel.org>; Tue, 7 Aug 2018 15:53:38 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7B1CF294AB; Tue, 7 Aug 2018 15:53:38 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=2.0 tests=BAD_ENC_HEADER,BAYES_00, DKIM_SIGNED,MAILING_LIST_MULTI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id BC59B28707 for <patchwork-linux-mlxsw@patchwork.kernel.org>; Tue, 7 Aug 2018 15:53:37 +0000 (UTC) Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 41lJvy6Hw4zDqRM for <patchwork-linux-mlxsw@patchwork.kernel.org>; Wed, 8 Aug 2018 01:53:34 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dmarc=pass (p=none dis=none) header.from=mellanox.com Authentication-Results: lists.ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=Mellanox.com header.i=@Mellanox.com header.b="dyjQs01v"; dkim-atps=neutral X-Original-To: linux-mlxsw@lists.ozlabs.org Delivered-To: linux-mlxsw@lists.ozlabs.org Authentication-Results: lists.ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=mellanox.com (client-ip=104.47.1.50; helo=eur01-ve1-obe.outbound.protection.outlook.com; envelope-from=petrm@mellanox.com; receiver=<UNKNOWN>) Authentication-Results: lists.ozlabs.org; dmarc=pass (p=none dis=none) header.from=mellanox.com Authentication-Results: lists.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=Mellanox.com header.i=@Mellanox.com header.b="dyjQs01v"; dkim-atps=neutral Received: from EUR01-VE1-obe.outbound.protection.outlook.com (mail-ve1eur01on0050.outbound.protection.outlook.com [104.47.1.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 41lJv60fKSzDqCG for <linux-mlxsw@lists.ozlabs.org>; Wed, 8 Aug 2018 01:52:49 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Mellanox.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=RaBH7fIgRMswqCKHIi67N+qh6ZHzUsBIvL28Ra7z7Rs=; b=dyjQs01vDWb13afK7WLKUVPLvhdvvCJJUaph77hNVQzifHGVXJA1h0FlWtbjZCbfw0QU1CRvzVy1S4+wyo6UOA9wvZ5SuJIOWEX5JfYDcm9LlcTi7TJgOOn0HzVQ3P6GygXaJW8xgtjiR3+eXzm6P+ogWrYVlundJ/fT6VjHgVE= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=petrm@mellanox.com; Received: from t540p (78.45.160.211) by AM6PR05MB4183.eurprd05.prod.outlook.com (2603:10a6:209:40::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1017.15; Tue, 7 Aug 2018 15:52:41 +0000 From: Petr Machata <petrm@mellanox.com> To: <linux-internal@mellanox.com> Subject: [PATCH net-next mlxsw] mlxsw: spectrum: Include RFC-2819 counters in stats length Message-Id: <3dcae9413c511de10304421665bd57f47427a4a0.1533656958.git.petrm@mellanox.com> Date: Tue, 07 Aug 2018 17:52:36 +0200 User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux) MIME-Version: 1.0 X-Originating-IP: [78.45.160.211] X-ClientProxiedBy: VI1P193CA0002.EURP193.PROD.OUTLOOK.COM (2603:10a6:800:bd::12) To AM6PR05MB4183.eurprd05.prod.outlook.com (2603:10a6:209:40::28) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 774b908e-1626-4ea5-41a9-08d5fc7dcf38 X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: BCL:0; PCL:0; RULEID:(7020095)(4652040)(8989117)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(5600074)(711020)(4618075)(2017052603328)(7153060)(7193020); SRVR:AM6PR05MB4183; X-Microsoft-Exchange-Diagnostics: 1; AM6PR05MB4183; 3:2LALjSQSgiBHnVNTz8F1i8GEhU4j6ZheH8QDaT7pcSYTsv8ET/ZQhUMXlkVfMTu00i6BTkoAGefyhAFKFGxtNvobHrFpBSkb+Y+4Tw7uIauN6W9jiHcUHzNhMROPPseUZ9C1g1JAvLfZOYNXFBNpW6Aapn0oxI3vPN15I5aiRzm2Hea/X60IJKcy1vGkX3nNGKI55Dc7eQvbjgj+Tu7JR4ctjorpqGLqyY8kG95/JLTy7EhdkZQKLSxNII/WQlZf; 25:RrzzT2XbfLatF9QWNmdOP/R/8cELCokKQXRFoxdtiW1FtCwV7VqIdF7ftZN4IMqlnkdsVooVDxKC61A9XNrN2IHr5nNKP+q8ohkGZRiQ+pqR1nB/TEd54YsRixUcx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yP07NWlaqkkQzY6vIEJEt3VUgSsqHdbl+MQFRwNlgro+0uHO3yxHaA1Y+/Cg86ZLsL7kWUOlV1DW2geza/LppwHFwSRKJ4Y9b7dvI/F2+SwWy4FUGr19bN+P9z8hyv4kc+1TPq/yDb1WryVMc2LWd7Z6S0891aBDgVkQVfYNqRwAG86KQ3uldDLbrwh9FXM3CiGhvpJHdTW7MkhwRIJQkPzs95TvN02fhQLvF36raQ== X-Microsoft-Antispam-PRVS: <AM6PR05MB418316053553C7AFCED60639DB270@AM6PR05MB4183.eurprd05.prod.outlook.com> X-Exchange-Antispam-Report-Test: UriScan:; X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(10201501046)(3002001)(3231311)(944501410)(52105095)(93006095)(93001095)(6055026)(149027)(150027)(6041310)(20161123558120)(20161123562045)(20161123564045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(6072148)(201708071742011)(7699016); SRVR:AM6PR05MB4183; BCL:0; PCL:0; RULEID:; SRVR:AM6PR05MB4183; X-Forefront-PRVS: 0757EEBDCA X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(136003)(376002)(39860400002)(346002)(366004)(396003)(189003)(199004)(305945005)(105586002)(106356001)(6862004)(8936002)(6486002)(386003)(2351001)(25786009)(53936002)(26005)(16586007)(37006003)(52116002)(2906002)(81156014)(48376002)(3846002)(6116002)(316002)(58126008)(51416003)(50466002)(81166006)(6496006)(8676002)(118296001)(7736002)(478600001)(97736004)(36756003)(2616005)(86362001)(66066001)(956004)(476003)(5660300001)(6636002)(486006)(16526019)(186003)(47776003)(68736007)(6666003); DIR:OUT; SFP:1101; SCL:1; SRVR:AM6PR05MB4183; H:t540p; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; Received-SPF: None (protection.outlook.com: mellanox.com does not designate permitted sender hosts) X-Microsoft-Exchange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VcJ286AeYYBzFpyNa+ps+/JptVcAW+iG7XTHLv+Qmp3MeF6bE0uyBd7lFpoIzxRsRUUPuPaJqKHooonnNXyi02gOIdHwN7oYydi8lVFjr8=; 7:kXeK8X5jVCvafkXvNagpwj492zpp9WP1vkkKDDnMZAV64+Jp/uIye+8PLl2ClqXj9DyIrH9pWt5uHb1FEeIFt94hEa20Y/VN5DOBQr3478lmZjGqc9b7CcunkXTz1jaP8MV23UxC7IhBFCRdey+OUy+V5enIYHWs7dzO12eiQ+VH8Mzdmdx/7PTwpgtlvlmg1F/SoSfWvGEn755NdGcWDNdUjnLW4xXxnb9B11a2uMPV1ZNgUpLBOygcDMvfljrg SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Aug 2018 15:52:41.8844 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 774b908e-1626-4ea5-41a9-08d5fc7dcf38 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6PR05MB4183 X-BeenThere: linux-mlxsw@lists.ozlabs.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: mlxsw driver development <linux-mlxsw.lists.ozlabs.org> List-Unsubscribe: <https://lists.ozlabs.org/options/linux-mlxsw>, <mailto:linux-mlxsw-request@lists.ozlabs.org?subject=unsubscribe> List-Archive: <http://lists.ozlabs.org/pipermail/linux-mlxsw/> List-Post: <mailto:linux-mlxsw@lists.ozlabs.org> List-Help: <mailto:linux-mlxsw-request@lists.ozlabs.org?subject=help> List-Subscribe: <https://lists.ozlabs.org/listinfo/linux-mlxsw>, <mailto:linux-mlxsw-request@lists.ozlabs.org?subject=subscribe> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: linux-mlxsw-bounces+patchwork-linux-mlxsw=patchwork.kernel.org@lists.ozlabs.org X-Virus-Scanned: ClamAV using ClamSMTP |
Series |
[net-next,mlxsw] mlxsw: spectrum: Include RFC-2819 counters in stats length
|
expand
|
diff --git a/drivers/net/ethernet/mellanox/mlxsw/spectrum.c b/drivers/net/ethernet/mellanox/mlxsw/spectrum.c index 6a0235395ac4..264e3aa805da 100644 --- a/drivers/net/ethernet/mellanox/mlxsw/spectrum.c +++ b/drivers/net/ethernet/mellanox/mlxsw/spectrum.c @@ -1971,6 +1971,7 @@ static struct mlxsw_sp_port_hw_stats mlxsw_sp_port_hw_tc_stats[] = { #define MLXSW_SP_PORT_HW_TC_STATS_LEN ARRAY_SIZE(mlxsw_sp_port_hw_tc_stats) #define MLXSW_SP_PORT_ETHTOOL_STATS_LEN (MLXSW_SP_PORT_HW_STATS_LEN + \ + MLXSW_SP_PORT_HW_RFC_2819_STATS_LEN + \ (MLXSW_SP_PORT_HW_PRIO_STATS_LEN + \ MLXSW_SP_PORT_HW_TC_STATS_LEN) * \ IEEE_8021QAZ_MAX_TCS)
The function mlxsw_sp_port_get_sset_count() is supposed to return the total number of ethtool strings that mlxsw supports. Specifically for names of statistic counters (the only string type that mlxsw supports as of now), that number is stored in MLXSW_SP_PORT_ETHTOOL_STATS_LEN. However, when adding RFC-2891 counters, that define wasn't updated to include the new counters. As a result, ethtool snips out the counters towards the end of the list, which contains per-TC counters, and only the first three traffic classes end up being reported. Fix by adding MLXSW_SP_PORT_HW_RFC_2819_STATS_LEN as appropriate. Fixes: 1222d15a01c7 ("mlxsw: spectrum: Expose counters for various packet sizes") Signed-off-by: Petr Machata <petrm@mellanox.com> --- drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 1 + 1 file changed, 1 insertion(+)