Received: by 2002:a05:6358:7058:b0:131:369:b2a3 with SMTP id 24csp7549277rwp; Tue, 18 Jul 2023 17:51:49 -0700 (PDT) X-Google-Smtp-Source: APBJJlESqNTNDZ9HvEpvJGTEzL02iJw8FbcGt5Kl+l4UzPWhm87R63tzKMF/4V+ksBWaZKfgBXlG X-Received: by 2002:a17:903:48c:b0:1b8:7483:d47a with SMTP id jj12-20020a170903048c00b001b87483d47amr13475631plb.37.1689727909346; Tue, 18 Jul 2023 17:51:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689727909; cv=none; d=google.com; s=arc-20160816; b=EhoJ62cDsMCgaptXKBYA3CAckIPODkpSFD7cArdmw6UdOUnHMsKCxJb00g14AcpBZZ XUyvYG0hsU9+JqAnXp4TMe9BLKevFsuEVy5VsKI7hiO9VY6B0uV50xPyf9laHA+4QgwG PmfntRJSrKfKaDEahvHgLznQvLCDdfV1p4NC2IvwA1aefYqRRiZGgmqwGFxy81/M5ALQ wR+/OtmgoxwiqSAGId4Ajvy+NdW4CHO0Jz9hMjLav9uaTnKsG8wzzFgopUo26mIuGoD+ CIRqWFl2wZh/GmdO4WSGrlXj/mdAtqEA6KauRSY+nyfIWCLTOLR8fUkN7dQwNltY6UHV CTBg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-disposition:mime-version:message-id :subject:to:from:date; bh=mHY+1oH0Tgef7BNwDp0vFm2rZ8de64Px74Z8PHY05JY=; fh=U78joW4LQQwfOIONL4n1MTnuN/QLLK4L8T4ZhPfDc0o=; b=ZegtK38wWUBca1Utf+xNRTcFD4ph/ePo4mVdKo0Dbyd/wmHq7JTan5+7ncDUeyu1gk 0zX9bA9NP7C5wGWfHe3a4DWVBi6lX4gTGUH7VRJZ9Liz75j/ulw1nKBWuuIQj4uKZgmg p40ZTrr3CfaY8By+KIsvFI2mr53kxvx/bazqAtScWmZQ6isJK2vAXgUxnn3sLnRLZ+l5 okotPMnj//1FkjC9eNVn0QCYDMVMuxRCnVBDUVlNgmaB+3qBk+jYCAvB+aCAfk7VEdTO RTIO+H84rgv8o3Yn8r5pdUl76X9qdaVH4ownw4oLzo7Xe4VxkEHWFbv5x5RtSJsoKZy9 g9AQ== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id p17-20020a170902c71100b001b809828a8fsi2307879plp.366.2023.07.18.17.51.37; Tue, 18 Jul 2023 17:51:49 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229756AbjGSAkK (ORCPT + 99 others); Tue, 18 Jul 2023 20:40:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44730 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229670AbjGSAkJ (ORCPT ); Tue, 18 Jul 2023 20:40:09 -0400 Received: from pidgin.makrotopia.org (pidgin.makrotopia.org [185.142.180.65]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 90F9D13D; Tue, 18 Jul 2023 17:40:07 -0700 (PDT) Received: from local by pidgin.makrotopia.org with esmtpsa (TLS1.3:TLS_AES_256_GCM_SHA384:256) (Exim 4.96) (envelope-from ) id 1qLvEO-0002TA-0d; Wed, 19 Jul 2023 00:39:52 +0000 Date: Wed, 19 Jul 2023 01:39:36 +0100 From: Daniel Golle To: Felix Fietkau , John Crispin , Sean Wang , Mark Lee , Lorenzo Bianconi , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Matthias Brugger , AngeloGioacchino Del Regno , Sujuan Chen , Bo Jiao , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org Subject: [PATCH net] net: ethernet: mtk_eth_soc: always mtk_get_ib1_pkt_type Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_BLOCKED,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 entries and bind debugfs files would display wrong data on NETSYS_V2 and later because instead of using mtk_get_ib1_pkt_type the driver would use MTK_FOE_IB1_PACKET_TYPE which corresponds to NETSYS_V1(.x) SoCs. Use mtk_get_ib1_pkt_type so entries and bind records display correctly. Fixes: 03a3180e5c09e ("net: ethernet: mtk_eth_soc: introduce flow offloading support for mt7986") Signed-off-by: Daniel Golle --- drivers/net/ethernet/mediatek/mtk_ppe_debugfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/mediatek/mtk_ppe_debugfs.c b/drivers/net/ethernet/mediatek/mtk_ppe_debugfs.c index 316fe2e70fead..1a97feca77f23 100644 --- a/drivers/net/ethernet/mediatek/mtk_ppe_debugfs.c +++ b/drivers/net/ethernet/mediatek/mtk_ppe_debugfs.c @@ -98,7 +98,7 @@ mtk_ppe_debugfs_foe_show(struct seq_file *m, void *private, bool bind) acct = mtk_foe_entry_get_mib(ppe, i, NULL); - type = FIELD_GET(MTK_FOE_IB1_PACKET_TYPE, entry->ib1); + type = mtk_get_ib1_pkt_type(ppe->eth, entry->ib1); seq_printf(m, "%05x %s %7s", i, mtk_foe_entry_state_str(state), mtk_foe_pkt_type_str(type)); -- 2.41.0