Received: by 2002:a05:6358:5282:b0:b5:90e7:25cb with SMTP id g2csp3323811rwa; Tue, 23 Aug 2022 02:51:08 -0700 (PDT) X-Google-Smtp-Source: AA6agR7Mgeq30Rq7H2TUM4aaLC7GY6yHSSAOysjdcGS55zeoblUicCDvTK48ezvpB9bPXeIp24Yq X-Received: by 2002:a05:6402:5252:b0:43e:14ec:46f with SMTP id t18-20020a056402525200b0043e14ec046fmr2909509edd.398.1661248268490; Tue, 23 Aug 2022 02:51:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661248268; cv=none; d=google.com; s=arc-20160816; b=0nP917Xv8z800uvtzeIDjoEa0ocSXEvTXW5K/Atbpxjql4ancjVsXa4XkxNtXc6E56 pEZ7lnn9VqKSbh6Sl6jcHUHatzEDKe8Q39Gsr790QWivpG9pITNW8TJ4DZUypYMUscqH J8dC9MUPbI57AAEIyfMNCOatT5+SzNEbd0IsSTf4lwnWGzSKI2E3uV1/kNyH0Kddz0W2 ok/Jocd3/JukbWYk3Z4R9lpVuYPX8hXhlynxr8lIOzLUNOwcTiryjBj/c584PoGvXxiP 3F+7dLxnBV3hwfgihJIB5O6/x0RGA+hWXcghWZLyTB5oggMpHGqWqUpQ/qxElhmHmULn fs7g== 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=LzJTWsAszDVcz7j1buEQM/OSio0gmLFQqtU2gLQNNAM=; b=Cjczo8IdxD3KTEwtQrQVS7yQU8kethD7JZNfH9IVcXLDPwZOqCW67vJuTjhBcZ/FCf 9U9iSOIa37Z/Rh7NJMNVCqoIa7jUAa2i30fu/wr4FoY3pjjcD/FFVwfvbDcSNVn8uqka NxIR7bpuR7js8ff08ghAI6byClGs6FMmgm//zYFJIiD7kmR6+9lkUr9yoEVKW5eOsU2Q znlj1VPjx64nL89ueVrIXzsG5d0pj4/B1ELnpSP4/T09vCtCXmbYp787uNCyWPJ1vhIn RfCBLIPDBkmY7qznw7RelBdmVjlaM+KHzP5sbv3ymM1ZqLjT9oz+YdMn3Y/Lv0f3NK+R 2R+g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=cbz3CEqx; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id m17-20020a50c191000000b004463b58f287si1573070edf.85.2022.08.23.02.50.43; Tue, 23 Aug 2022 02:51:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=cbz3CEqx; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 S241961AbiHWJBJ (ORCPT + 99 others); Tue, 23 Aug 2022 05:01:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45082 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1347510AbiHWJAe (ORCPT ); Tue, 23 Aug 2022 05:00:34 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A1B418276C; Tue, 23 Aug 2022 01:27:30 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 1D1486132D; Tue, 23 Aug 2022 08:27:24 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0CB86C433C1; Tue, 23 Aug 2022 08:27:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1661243243; bh=I7mToTYrlG00p7FiW4DaYlyEvxUMSTtAGzBRGbiFV+Q=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=cbz3CEqxWzH5bD0e5pOMCcm84LpTjBtjPuJfO3cTZqre7lEOg2fbA/C130ErRhCne STZJ3bitoWfoNglrg1tG4vv+ksTeNaPB5mOnS+7sIPl7F95rHRtK83dRoOZNxirv3c b2fY0Z2NY/9em5cqpBC/ndGBSoeliN/pCoFoJVVs= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Vladimir Oltean , Jakub Kicinski Subject: [PATCH 5.19 215/365] net: dsa: felix: fix ethtool 256-511 and 512-1023 TX packet counters Date: Tue, 23 Aug 2022 10:01:56 +0200 Message-Id: <20220823080127.190879077@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220823080118.128342613@linuxfoundation.org> References: <20220823080118.128342613@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Vladimir Oltean commit 40d21c4565bce064c73a03b79a157a3493c518b9 upstream. What the driver actually reports as 256-511 is in fact 512-1023, and the TX packets in the 256-511 bucket are not reported. Fix that. Fixes: 56051948773e ("net: dsa: ocelot: add driver for Felix switch family") Signed-off-by: Vladimir Oltean Signed-off-by: Jakub Kicinski Signed-off-by: Greg Kroah-Hartman --- drivers/net/dsa/ocelot/felix_vsc9959.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) --- a/drivers/net/dsa/ocelot/felix_vsc9959.c +++ b/drivers/net/dsa/ocelot/felix_vsc9959.c @@ -601,7 +601,8 @@ static const struct ocelot_stat_layout v { .offset = 0x87, .name = "tx_frames_below_65_octets", }, { .offset = 0x88, .name = "tx_frames_65_to_127_octets", }, { .offset = 0x89, .name = "tx_frames_128_255_octets", }, - { .offset = 0x8B, .name = "tx_frames_256_511_octets", }, + { .offset = 0x8A, .name = "tx_frames_256_511_octets", }, + { .offset = 0x8B, .name = "tx_frames_512_1023_octets", }, { .offset = 0x8C, .name = "tx_frames_1024_1526_octets", }, { .offset = 0x8D, .name = "tx_frames_over_1526_octets", }, { .offset = 0x8E, .name = "tx_yellow_prio_0", },