From patchwork Mon Aug 19 07:25:13 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Furong Xu <0x1207@gmail.com> X-Patchwork-Id: 13768019 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 2EB2FC3DA4A for ; Mon, 19 Aug 2024 07:27:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: MIME-Version:Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-Type: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=GMxRPL+T8UIjCQfC5kIWgTFU9+0G6pZaJzB9qUuJpIw=; b=HkJahDxOpLPqdgdzbv0VZTr5Ac fG0VXTtak0aVP0tw3bRAmzRCB1N7anD9wiYkm9y1W5WAE22aX6bqx3y8csSXVFp1gxSWW4gCQJMWx xBI9Kr3WcK+Iwk+ffhcyD7BFvr3DSLTBYX+iUIfNY9Jy8XrY2ujXDekJ7apmB2qjveLq48M3LfhWs rq44bzNj4oCpY23wQNi8FJcFkkOxPKZ845xHB6hbxl9k1hlvbCnMcuiX4Y8krT389jQ4twHQvnLe3 GveMEOgrQojInHhSH2soQkJGUU5BsbSH3Z/bRProP0oNp1+aGHYPZBaqwdDIaeaA/hC/nkvWn0xlC NjjJlGAg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sfwnE-00000000dTT-3kIz; Mon, 19 Aug 2024 07:27:08 +0000 Received: from mail-pl1-x629.google.com ([2607:f8b0:4864:20::629]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sfwm6-00000000dEI-22Rd for linux-arm-kernel@lists.infradead.org; Mon, 19 Aug 2024 07:26:13 +0000 Received: by mail-pl1-x629.google.com with SMTP id d9443c01a7336-20203988f37so25271825ad.1 for ; Mon, 19 Aug 2024 00:25:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1724052357; x=1724657157; darn=lists.infradead.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=GMxRPL+T8UIjCQfC5kIWgTFU9+0G6pZaJzB9qUuJpIw=; b=XdEWHLZgz/SOEOMCGgZWia6sMIWrvCv2qTri8hymRLItCLgZyAyHoKfEtXGUNG/dOL Zd/6hzNhLbc3vi+uSlMKOUzDPvOFWUXTcqevaMUiGBt+fbpKBYIWmhHeoEclEtSzIMbU 8BRAidai4JtiDT/nn0opZ+GZtoYxKM12B4CZAaOPICRtjVLA/tw9VWVwN6/g58IT0qZM rk4dJOAVIQlCYTv+TJKwUQY1HPTRzuDBEUHZNRgendh5rZbhjorYbmkQfdvsJr8Ab+1c oFef567Dh4mfsX7gMBg7eGAV0U9J0azMtNQJ5Z2k2auR4qnzdax0ZEJlGKeHPJNdMl0X Eu4A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724052357; x=1724657157; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=GMxRPL+T8UIjCQfC5kIWgTFU9+0G6pZaJzB9qUuJpIw=; b=OE0cZ/kP1YPZvlh32yKqIdD204HdEV/6TEUt7wyfZ8Cfh7yca96XWUNZY/tMtgk46f NOFG2zXmqg/zIa5dAkqzz6lQWRGp/KVy0JaTcbPKMXMNJ6boedZ7nhEpKy5siC6do06i BDCZYlR3xqOKDoAxE22QLmk8bhDC1cK8OgRMwPH+kPLILUMOLiA4B4ug1V409x5l9bCs RiHzHeZWADHu3QaEsPyrYyVHGUepwT6l3Uw5+gAshdn1KvVUrGQoThfPWPoWQQHbkuxO BopekYjh1IAognIqV4rUFZv7sLgMRhP8b6p1o9X1yfsCI72sshpH1ULOxlk9ZIl+5zXZ gjgg== X-Forwarded-Encrypted: i=1; AJvYcCWkLvWv1qkloxtt4kQz1DSa4FuKaow65FEheVrWYRhND0ouQtQRYiYs8Ntlh06gRGWvBMRS8HVgsHuqwG94V/AnIlWkLwPH/u7AKe4Tq7VajfvZ3q0= X-Gm-Message-State: AOJu0YwKbEhsQYpt1FAbyEHVrb3rCbqdTZZty9klBixQ/7fVu7HnXVwp ffL2l1wfL+Dz9h8RTYPYgp8nvAkBN1lW8TtMvAI5fy5nEkqBPZTh X-Google-Smtp-Source: AGHT+IFs9U2vy6o8hrcgBG0WljZK09J5u0ZU7PDrc/0pefVklhHx0XndlbBF0rFOTVbCQeZRG7NQag== X-Received: by 2002:a17:903:2303:b0:1ff:4967:66a with SMTP id d9443c01a7336-20203e88843mr117933405ad.14.1724052356689; Mon, 19 Aug 2024 00:25:56 -0700 (PDT) Received: from localhost.localdomain ([129.146.253.192]) by smtp.googlemail.com with ESMTPSA id d9443c01a7336-201f02faa5dsm58340855ad.2.2024.08.19.00.25.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Aug 2024 00:25:56 -0700 (PDT) From: Furong Xu <0x1207@gmail.com> To: Serge Semin , Andrew Lunn , Vladimir Oltean , "David S. Miller" , Alexandre Torgue , Jose Abreu , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Maxime Coquelin , Joao Pinto Cc: netdev@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, xfr@outlook.com, Furong Xu <0x1207@gmail.com> Subject: [PATCH net-next v3 0/7] net: stmmac: FPE via ethtool + tc Date: Mon, 19 Aug 2024 15:25:13 +0800 Message-Id: X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240819_002558_563171_41A28BDB X-CRM114-Status: UNSURE ( 9.58 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Move the Frame Preemption(FPE) over to the new standard API which uses ethtool-mm/tc-mqprio/tc-taprio. Changes in v3: 1. avoid races among ISR, workqueue, link update and register configuration. 2. update FPE verification retry logic, so it retries and fails as expected. Changes in v2: 1. refactor FPE verification processe 2. suspend/resume and kselftest-ethtool_mm, all test cases passed 3. handle TC:TXQ remapping for DWMAC CORE4+ Furong Xu (7): net: stmmac: move stmmac_fpe_cfg to stmmac_priv data net: stmmac: drop stmmac_fpe_handshake net: stmmac: refactor FPE verification processe net: stmmac: configure FPE via ethtool-mm net: stmmac: support fp parameter of tc-mqprio net: stmmac: support fp parameter of tc-taprio net: stmmac: silence FPE kernel logs .../net/ethernet/stmicro/stmmac/dwmac4_core.c | 10 +- drivers/net/ethernet/stmicro/stmmac/dwmac5.c | 96 ++++++++- drivers/net/ethernet/stmicro/stmmac/dwmac5.h | 11 +- .../ethernet/stmicro/stmmac/dwxgmac2_core.c | 4 +- drivers/net/ethernet/stmicro/stmmac/hwif.h | 20 +- drivers/net/ethernet/stmicro/stmmac/stmmac.h | 25 +++ .../ethernet/stmicro/stmmac/stmmac_ethtool.c | 107 ++++++++++ .../net/ethernet/stmicro/stmmac/stmmac_main.c | 192 +++++++++--------- .../net/ethernet/stmicro/stmmac/stmmac_tc.c | 115 +++++++---- include/linux/stmmac.h | 28 --- 10 files changed, 430 insertions(+), 178 deletions(-)