From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E9975606A322 for ; Fri, 4 Dec 2026 02:30:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=YmS4U/ig; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.a=rsa-sha256 header.s=20260707 header.b=Lmn03oa+ 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-Type:Cc:To:From: Subject:Message-ID:References:Mime-Version:In-Reply-To:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Unsubscribe-Post:List-Owner; bh=HjBCW6PqYfxAHy8on28h3TCZY3v8aGr4Ieta78/DY/c=; b=YmS4U/iglq1DLjV1R3yWTse4VD euma/NNlD5Jv6xgf1XIE9NmCS74HB1bpC/5FIOd5yx94VKSxI5d34VqYyuzHVH94z5tmGVwDZ3gbH s2sO1AfKY1JGfG2P404DBkO2f4ozF7Dvc2OFBmAAcbOvAyP1g9FTdgfdDo1rSJ77HVdzqItHl14gI MOqHhiVRcNxr56FK/9Q0aQOaeuLWMnou6EP7Jaxw2wYaN4+5w1KyYe1wMXzEX1XPYZ1+qatIY9e2O CD8UlVbQe1Fv6ahpesYFr9iofh0fVM7vaR58aMdPLuwOVADadpGOW+2PU6/qNnIEELD7XdOCaCbMZ /AP7QNQA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.100.1 #2 (Red Hat Linux)) id 1xZJ3i-0000000GQYh-0617; Fri, 04 Dec 2026 02:30:02 +0000 Received: from mail-qk1-x748.google.com ([2607:f8b0:4864:20::748]) by bombadil.infradead.org with esmtps (Exim 4.100.1 #2 (Red Hat Linux)) id 1xZJ3e-0000000GQV8-1RBi for linux-arm-kernel@lists.infradead.org; Fri, 04 Dec 2026 02:30:00 +0000 Received: by mail-qk1-x748.google.com with SMTP id af79cd13be357-93f32050e72so118586685a.1 for ; Thu, 03 Dec 2026 18:29:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20260707; t=1796351378; x=1796956178; darn=lists.infradead.org; h=content-type:cc:to:from:subject:message-id:references:mime-version :in-reply-to:date:from:to:cc:subject:date:message-id:reply-to :content-type; bh=HjBCW6PqYfxAHy8on28h3TCZY3v8aGr4Ieta78/DY/c=; b=Lmn03oa+CiwrfpdZsJGuZfOgrNdjFCAHchVsCrU8SJUP5DcXmmsYtdsVZBUcfWAJ5L 2hVjFHbV6pcWEl9xkVi0iNhGAM2fkHy5RVJYy+4vhzov6qHVxsHqdMiSDfxIGp32NIvv WLEi7vVY0qmG94FBvHUQBPxWXwO0tGf8ipyKJGPa1eEex9RiILyGjN1o9wrz74B3MVQk /5gOi0HUX8cEgiiU+BnFwWjn+GYq6305l3b7i/EfAVrPLaoBtomEDJEd6xR8pVTNJFgy 63LncW+Eh9ia1QOYfOy8x1CP7pwFveJ/DDsUkRrUmem0+2pVHI1EeegkI3neACviOMp3 ivgQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796351378; x=1796956178; h=content-type:cc:to:from:subject:message-id:references:mime-version :in-reply-to:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to:content-type; bh=HjBCW6PqYfxAHy8on28h3TCZY3v8aGr4Ieta78/DY/c=; b=EwDnFdmggUYsADtK1EMnbztuzIknrJExE3m/g7oSwtvjXzy5MQAd0W8fYqZ+w8G1W4 pTuNWX27+3rQV/UclEjx6yteuDevo+Pi9KrgdL/fE8kufUUs3HwAaaSIV8VGdpVaPKzg zumAVrl3U1JxGTbeShT6u1T6ov2edrEavb7t005f8AEhdPbiSHZpBJnHmi+30J6dniMJ LD9gOlRB8XsTwTsARxY8iXGz/mVTWjY/e8et7Is5mgI06evXhLUkbwQhP36LuljkkWQp uYaaczSMXaA4IZT5upWSoy/FKGPXfkheLv8kg+XhtxX/gHM5RPpirwIIT4LickmrHQor Dz6g== X-Forwarded-Encrypted: i=1; AL+hErFl0YdIjx6p115aLeUFoRQucOgxe7wvGRNej+cjQ3vJLN5dZWlsu5ZgkW6KV6IgRCYMpvkdnkQ0OZ1vdx2hDBU1@lists.infradead.org X-Gm-Message-State: APuU4Z/0viyyu3iVPhBiu0+u/lxsj5KTaFPwksXPKSaEq4TvqAZjmhT1 XMzdij1NCpzMUwpXN64k7K+HI/x14KgswbqcYtDmwiDi3sRj3kURKy6YgCkTrFVaIyle77VsKfu MQNa/DCS2Jw== X-Received: from qknqa1.prod.google.com ([2002:a05:620a:6481:b0:93e:72cb:e68c]) (user=willemb job=prod-delivery.src-stubby-dispatcher) by 2002:a05:620a:198e:b0:946:2a0:a11b with SMTP id af79cd13be357-94a82804612mr95687385a.35.1796351377754; Thu, 03 Dec 2026 18:29:37 -0800 (PST) Date: Thu, 03 Dec 2026 21:29:37 -0500 In-Reply-To: <20261203-b4-cs7542-ethernet-v7-0-5d9a6ff7bc96@gmail.com> X-Archived-By: Mime-Version: 1.0 References: <20261203-b4-cs7542-ethernet-v7-0-5d9a6ff7bc96@gmail.com> Message-ID: Subject: Re: [PATCH net-next v7 0/3] Add Cortina Systems CS7542 network engine support From: willemb@google.com To: Fil Dunsky via B4 Relay , Andrew Lunn , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Linus Walleij Cc: Philipp Zabel , Hans Ulli Kroll , Russell King , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8"; format=flowed; delsp=yes X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.9.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20261203_182958_437386_0CF03855 X-CRM114-Status: GOOD ( 27.99 ) X-Spam-Score: -9.5 (---------) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIMWL_WL_MED,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_IN_DEF_DKIM_WL autolearn=ham autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 Fil Dunsky via B4 Relay wrote: > Add the CS7542 CPU network datapath with phylink for three GMACs. > Almond+ connects two GMACs to QCA8337 CPU ports handled by DSA. > This series depends on the combined CS7542 global controls v6 series, > posted separately against Linux v7.4-rc4. The consumer acquires the NI, > FE, TM, SCH, QM, DMA and NI-XRAM reset controls exclusively. Board DTS > support is separate. The verified 64 MiB no-map queue-manager reservation > is required. NAND uses PIO; a separate SSP DMA consumer cannot run > concurrently with the shared DMA reset domain. > Use normal NAPI weight 64 and external-DDR QM/TM setup, with no module > parameters. Support scatter-gather TX and multi-buffer RX, bounded > initialization, tracked DMA ownership, shared NI register serialization > and protective reset before freeing active mappings. No checksum/NAT > offload or performance capability is added. > The port byte counters previously wrapped at 4 GiB on 32-bit ARM. > Use the network core's 64-bit per-CPU totals and preserve the existing > error and drop counters. Allow independent MAC addresses on each > netdev. With PAUSE temporarily enabled for testing, QCA8337 PAUSE > frames stopped transmission on both GMACs with different addresses. > Cortina did not generate PAUSE frames under offered line-rate traffic > or when NAPI stopped draining the RX ring, so this series leaves hardware > flow control disabled. > The driver exposes no MAC-level Wake-on-LAN support. The NI > magic-packet comparator uses the > shared MAC prefix and cannot follow arbitrary independent netdev MAC > addresses. PHY-based wake support can be considered separately once > the PHY capability and board wake path are verified. > The driver compiles for ARM with warnings as errors. On Almond+ an > OpenWrt RAM build exercised LAN1 over each of the two QCA8337 CPU > ports with the standard two-byte QCA tag. Five two-packet ICMP > exchanges succeeded while assigning and changing different MAC > addresses for the two GMACs. RX/TX counters increased on the > selected GMAC in each case. All MTD partitions were read-only and > the watchdog returned to OpenWrt. > Earlier combined-kernel Almond+ checks covered reset/probe/removal, LAN1 > protected-data transfers and automatic watchdog return to normal OpenWrt. > Separate earlier fixtures checked 600 UDP echoes, 20 ICMPv6 replies and > 448 scatter-gather/jumbo frames. Protected-region hashes and flash layout > matched; unrelated concurrent settings activity was excluded from any > unchanged-settings claim. These observations predate the new retry/context > fixes and are integration/functional checks, not throughput or offload > results. > --- > Changes in v7: > - Address Andrew Lunn's review. Simplify the FE return path and order > local declarations. Separate RX packet handling from the NAPI loop. > - Allow independent MAC addresses, retain NVMEM probe deferral and > leave hardware pause disabled. > - Link to v6: > https://patch.msgid.link/20261202-b4-cs7542-ethernet-v6-0-a8c1905efa9f@gmail.com > Changes in v6: > - Keep zero-budget NAPI polling limited to TX completions. > - Link to v5: > https://lore.kernel.org/r/20261201-b4-cs7542-ethernet-v5-0-0c079f9c8b1b@gmail.com > Changes in v5: > - Use the network core's 64-bit per-CPU packet and byte totals. > - Pack the MAC register value with get_unaligned_le32(). > - Update the global-controls dependency to v6. > - Link to v4: > https://lore.kernel.org/all/20261127-b4-cs7542-ethernet-v4-0-ea4d8cd6ef18@gmail.com/ > Changes in v4: > - Bound DMA-owned RX head polling and defer retries with the IRQ masked. > - Schedule NAPI with bottom halves disabled from process context. > - Link to v3: > https://lore.kernel.org/all/20261126-b4-cs7542-ethernet-v3-0-5db5d372e1bd@gmail.com/ > Changes in v3: > - Include FCS in RX buffer recycling and retry transient descriptor > ownership. > - Validate the shared MAC prefix and reject sibling-clobbering changes. > - Drop the RESET_CONTROLLER select from the Ethernet consumer. > - Rely on reset provider error propagation instead of redundant status > reads. > - Use bulk deassert on bring-up; preserve all protective assertions on > teardown. > - Link to v2: > https://patch.msgid.link/20261125-b4-cs7542-ethernet-v2-0-d0ea3c6eb375@gmail.com > Changes in v2: > - Use the common parent provider and all seven exclusive reset lines; > remove the virtual reset child, duplicate provider and consumer hook. > - Assert and verify every line without protective-assert rollback; > retain active DMA allocations on any error and deassert in reverse > order. > - Use rgmii-id in the binding example for switch-inserted RX/TX delays. > - Remove module parameters and unused internal-buffer mode; retain the > previous default external-DDR initialization policy. > - Use NAPI weight64, plain static MMIO helpers and goto-based open > cleanup; > retain the lock-protected publication and stopping gates. > - Serialize shared NI RMW and stop on the first scheduler command error. > - Keep MAC preflight before hardware cleanup registration and preserve > a late NVMEM probe defer instead of replacing it with a random MAC. > - Recycle bounded RX fragments also when the frame is dropped. > - Poll already queued RX after open and retain safe closed-port TX > reaping. > - Review Sashiko 231860: existing NI/SCH/NAPI fixes address the older v1; > temporary BM initialization bypass clearing follows the vendor sequence. > - Link to v1: > https://lore.kernel.org/all/20261123-b4-cs7542-ethernet-v1-0-fdb5e8c2d508@gmail.com/ > To: Fil Dunsky > To: Andrew Lunn > To: "David S. Miller" > To: Eric Dumazet > To: Jakub Kicinski > To: Paolo Abeni > To: Rob Herring > To: Krzysztof Kozlowski > To: Conor Dooley > To: Hans Ulli Kroll > To: Linus Walleij > To: Philipp Zabel > To: Russell King > Cc: netdev@vger.kernel.org > Cc: devicetree@vger.kernel.org > Cc: linux-kernel@vger.kernel.org > Cc: linux-arm-kernel@lists.infradead.org > --- > Fil Dunsky (3): > dt-bindings: net: Add Cortina CS7542 network engine > net: cortina: Add CS7542 CPU network datapath > MAINTAINERS: Add CS7542 network engine support > .../bindings/net/cortina,cs7542-ethernet.yaml | 162 ++ > MAINTAINERS | 7 + > drivers/net/ethernet/cortina/Kconfig | 13 + > drivers/net/ethernet/cortina/Makefile | 3 + > drivers/net/ethernet/cortina/cs752x_fe.c | 475 +++++ > drivers/net/ethernet/cortina/cs752x_ne.c | 1893 > ++++++++++++++++++++ > drivers/net/ethernet/cortina/cs752x_ne.h | 13 + > drivers/net/ethernet/cortina/cs752x_sch_tm.c | 688 +++++++ > 8 files changed, 3254 insertions(+) > --- > base-commit: b6a9fa34ce4187cb69d3c588a4bbffc31ce5db8f > change-id: 20261123-b4-cs7542-ethernet-59c15dbc7e7e > prerequisite-message-id: > <20261129-cs7542-syscon-v6-0-553dc4c01460@gmail.com> > prerequisite-patch-id: 27fe25055bcadb3c3fbc8b6788f31c2fb791df38 > prerequisite-patch-id: ae69b5cca6f4604972300a89411bdca0ea19ab57 > prerequisite-patch-id: 55dc4f1e91fc85340c4422438225f50fdf636799 > prerequisite-patch-id: 66fccae72a8f951ac0ee182490e98543af29bd89 > prerequisite-patch-id: 7fbe9405265ef3d1ec62811415a46c0061afd7c8 > prerequisite-patch-id: 01ece2c91e080d5cae6af81944159373776484ca > Best regards, > -- > Fil Dunsky Does not apply cleanly to net-next. Please respin.