Message ID | 20230411200409.455355-1-ahalaney@redhat.com |
---|---|
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp2833951vqo; Tue, 11 Apr 2023 13:22:38 -0700 (PDT) X-Google-Smtp-Source: AKy350Z/ZEqIp0VAQUmiRWURzRS+SFqmAt/NkueFiQcL6cTygp7ft4gCo9lz/2SeQ0SU1+4ZIy87 X-Received: by 2002:a17:90b:4b49:b0:246:bb31:e848 with SMTP id mi9-20020a17090b4b4900b00246bb31e848mr7948389pjb.36.1681244558503; Tue, 11 Apr 2023 13:22:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681244558; cv=none; d=google.com; s=arc-20160816; b=VX0r8T9iP1g4OlCa4XNHDfAzFJ6zMoBWZQ/YiMyyjwWy9WDIVH45ujmQjAolySIwdw 2A6HDI9tDa0umT4s+xTG3H/YegwLuxD+UJwFlNoe85ApPB7ybAeR0p+pdoB16yi3OYbQ 0BCROC6G82rBnb2RO3HznHPk/x6D9tXai1xLtedEa+Flk5iQ2Fq3ZRSk33lzEh468Lpc XNSE9BabUtHmyhR+AVbl14n0OAGxd8gqxuhEE6fInXNHG9M9Rdq61GvAscInpzhw0LXG nDrSOwk+bm2hNeiOBdaxLRyH605SN1ONvqIJH2UloT38DdbZ6vCSgko8k3kqvpF9HASy Kt2g== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=cxcg4D7oOn+vhVnnmmIAydop7TdCDBp1rp6PwiTdQPw=; b=dQ2FoFZXQxQntDN2ypGJ/TrPJz83b1t+Wk1TV7cGDrWRr6ClSj5EAHC8oTk5F2v/8Q a5vdket+lQr+cI0/hp8yuvNSp5+V+mcBpSC0/8qB1DRqu0lkX7TiBAsezduBwAutrFOc v08oYERn53xBxA7IrQNfSzyfxymOmRMC3ls+nL0nWsrlvuu4I807OBK+yejcy1+LrHsb KmIxskV1V90aZfHuG+n8CEajoRYqt4Rw93XHnUmc1I5FqHv7z0t0iPQZD3YyDfU8eXXE b2vHi+rP8ZqX8gc3F3i1WY//g1I0QZNv5EhrJcWArmMa/Rf5K+zkbwNrlWF/+0MHsx1D DHbw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=iNGUMYXg; 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=redhat.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x21-20020a63f715000000b00513af1fa0b5si13660239pgh.797.2023.04.11.13.22.25; Tue, 11 Apr 2023 13:22:38 -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=@redhat.com header.s=mimecast20190719 header.b=iNGUMYXg; 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=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229555AbjDKUFQ (ORCPT <rfc822;leviz.kernel.dev@gmail.com> + 99 others); Tue, 11 Apr 2023 16:05:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49782 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229485AbjDKUFO (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Tue, 11 Apr 2023 16:05:14 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AFC784228 for <linux-kernel@vger.kernel.org>; Tue, 11 Apr 2023 13:04:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1681243466; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=cxcg4D7oOn+vhVnnmmIAydop7TdCDBp1rp6PwiTdQPw=; b=iNGUMYXgOsuDTVO1ldoAGf09MRwjRca251MVio7z/NRinx5IeDuPLxr9ylk+wKm0ejuc7s PsLQQdZT2roF+tTCgVAAn9Fy1gHcpTf2STZNey5r9xImH8voFy/mmeNs7zNSK/9S5jp8pA y1zkzJ7d3RyttT5VyDP00/3TDHKTaWk= Received: from mail-ot1-f71.google.com (mail-ot1-f71.google.com [209.85.210.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-668-DH4_6QzbPwapVfGdL7pWXg-1; Tue, 11 Apr 2023 16:04:25 -0400 X-MC-Unique: DH4_6QzbPwapVfGdL7pWXg-1 Received: by mail-ot1-f71.google.com with SMTP id r16-20020a9d7cd0000000b006a149b4ad1cso562786otn.23 for <linux-kernel@vger.kernel.org>; Tue, 11 Apr 2023 13:04:25 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1681243464; 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=cxcg4D7oOn+vhVnnmmIAydop7TdCDBp1rp6PwiTdQPw=; b=5nabmWVbeF1R6tvX5EfVFKm1u5RQm/2yzZvkFnN/mDbKKIWTNb6cB/hvMOqaM8WwIX fKbRgwP5/JPw5MAUVR+6M237y3SlznvSItBzZTrlrD5P/ElyS9PDoW7gfTgM78hOfGkm GQ9nPxlXq0tUo4mV+QtMpHiIJnut/G6CZ7OHjkhfM+MsZo4GzM9mpZVMBAkLw60wAbte fENqWUwdCtW1de/T8tbhoOuR65vAgxPhSrobyu2BkoJSq0TiAj6LujN3ceakbp3A/lKq LTquZV3FYP+V4WJdZ3CyBCq5P7IHrA7MW0SpBVPM9su5J6YhUJSo0kb7p+g0RNdaq4KM e02A== X-Gm-Message-State: AAQBX9cIj1qoem43B3g4jHFCDROmGskH8EGD5mrHxWcVUCKbV4e/T2tq m8gWGZe7lGwutdGj0q4sqEjo1yfDEwKmTBcMRo8Msw3HmxiXrbxP2r86JDGgArXMNOkrQgoAuTy +qZ857kCWL2Oox/SQNz+8n/tY+bkKjpOkOd0C84IrrdfltCHg2pdf4afWMmhYYwGEO0cSrAcIz+ flIF98PPLIvxY= X-Received: by 2002:aca:d743:0:b0:386:9720:77da with SMTP id o64-20020acad743000000b00386972077damr5007485oig.26.1681243464629; Tue, 11 Apr 2023 13:04:24 -0700 (PDT) X-Received: by 2002:aca:d743:0:b0:386:9720:77da with SMTP id o64-20020acad743000000b00386972077damr5007433oig.26.1681243464151; Tue, 11 Apr 2023 13:04:24 -0700 (PDT) Received: from halaney-x13s.attlocal.net (104-53-165-62.lightspeed.stlsmo.sbcglobal.net. [104.53.165.62]) by smtp.gmail.com with ESMTPSA id e20-20020a056808149400b00387764759a3sm5868545oiw.24.2023.04.11.13.04.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Apr 2023 13:04:23 -0700 (PDT) From: Andrew Halaney <ahalaney@redhat.com> To: linux-kernel@vger.kernel.org Cc: agross@kernel.org, andersson@kernel.org, konrad.dybcio@linaro.org, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, vkoul@kernel.org, bhupesh.sharma@linaro.org, wens@csie.org, jernej.skrabec@gmail.com, samuel@sholland.org, mturquette@baylibre.com, peppe.cavallaro@st.com, alexandre.torgue@foss.st.com, joabreu@synopsys.com, mcoquelin.stm32@gmail.com, richardcochran@gmail.com, linux@armlinux.org.uk, veekhee@apple.com, tee.min.tan@linux.intel.com, mohammad.athari.ismail@intel.com, jonathanh@nvidia.com, ruppala@nvidia.com, bmasney@redhat.com, andrey.konovalov@linaro.org, linux-arm-msm@vger.kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, ncai@quicinc.com, jsuraj@qti.qualcomm.com, hisunil@quicinc.com, echanude@redhat.com, Andrew Halaney <ahalaney@redhat.com> Subject: [PATCH net-next v4 00/12] Add EMAC3 support for sa8540p-ride Date: Tue, 11 Apr 2023 15:03:57 -0500 Message-Id: <20230411200409.455355-1-ahalaney@redhat.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-type: text/plain Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE autolearn=unavailable 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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1762912694170410856?= X-GMAIL-MSGID: =?utf-8?q?1762912694170410856?= |
Series |
Add EMAC3 support for sa8540p-ride
|
|
Message
Andrew Halaney
April 11, 2023, 8:03 p.m. UTC
This is a forward port / upstream refactor of code delivered downstream by Qualcomm over at [0] to enable the DWMAC5 based implementation called EMAC3 on the sa8540p-ride dev board. From what I can tell with the board schematic in hand, as well as the code delivered, the main changes needed are: 1. A new address space layout for dwmac5/EMAC3 MTL/DMA regs 2. A new programming sequence required for the EMAC3 based platforms This series makes the changes above as well as other housekeeping items such as converting dt-bindings to yaml, etc. As requested[1], it has been split up by compilation deps / maintainer tree. I will post a link to the associated devicetree changes that together with this series get the hardware functioning. Patches 1-3 are clean ups of the currently supported dt-bindings and IMO could be picked up as is independent of the rest of the series to improve the current codebase. They've all been reviewed in prior versions of the series. Patches 5-7 are also clean ups of the driver and are worth picking up independently as well. They don't all have explicit reviews but should be good to go (trivial changes on non-reviewed bits). The rest of the patches have new changes, lack review, or are specificly being made to support the new hardware, so they should wait until the series as a whole is deemed ready to go by the community. [0] https://git.codelinaro.org/clo/la/kernel/ark-5.14/-/commit/510235ad02d7f0df478146fb00d7a4ba74821b17 [1] https://lore.kernel.org/netdev/20230320202802.4e7dc54c@kernel.org/ v3: https://lore.kernel.org/netdev/20230331214549.756660-1-ahalaney@redhat.com/ v2: https://lore.kernel.org/netdev/20230320221617.236323-1-ahalaney@redhat.com/ v1: https://lore.kernel.org/netdev/20230313165620.128463-1-ahalaney@redhat.com/ Thanks, Andrew Andrew Halaney (9): dt-bindings: net: qcom,ethqos: Add Qualcomm sc8280xp compatibles net: stmmac: Remove unnecessary if statement brackets net: stmmac: Fix DMA typo net: stmmac: Remove some unnecessary void pointers net: stmmac: Pass stmmac_priv in some callbacks net: stmmac: dwmac4: Allow platforms to specify some DMA/MTL offsets net: stmmac: dwmac-qcom-ethqos: Respect phy-mode and TX delay net: stmmac: dwmac-qcom-ethqos: Use loopback_en for all speeds net: stmmac: dwmac-qcom-ethqos: Add EMAC3 support Bhupesh Sharma (3): dt-bindings: net: snps,dwmac: Update interrupt-names dt-bindings: net: snps,dwmac: Add Qualcomm Ethernet ETHQOS compatibles dt-bindings: net: qcom,ethqos: Convert bindings to yaml .../devicetree/bindings/net/qcom,ethqos.txt | 66 ------ .../devicetree/bindings/net/qcom,ethqos.yaml | 111 ++++++++++ .../devicetree/bindings/net/snps,dwmac.yaml | 9 +- MAINTAINERS | 2 +- .../net/ethernet/stmicro/stmmac/chain_mode.c | 10 +- drivers/net/ethernet/stmicro/stmmac/common.h | 2 +- .../stmicro/stmmac/dwmac-qcom-ethqos.c | 178 ++++++++++++---- .../net/ethernet/stmicro/stmmac/dwmac-sun8i.c | 36 ++-- .../ethernet/stmicro/stmmac/dwmac1000_core.c | 3 +- .../ethernet/stmicro/stmmac/dwmac1000_dma.c | 19 +- .../ethernet/stmicro/stmmac/dwmac100_dma.c | 14 +- drivers/net/ethernet/stmicro/stmmac/dwmac4.h | 101 +++++++-- .../net/ethernet/stmicro/stmmac/dwmac4_core.c | 50 +++-- .../ethernet/stmicro/stmmac/dwmac4_descs.c | 8 +- .../net/ethernet/stmicro/stmmac/dwmac4_dma.c | 201 +++++++++++------- .../net/ethernet/stmicro/stmmac/dwmac4_dma.h | 92 +++++--- .../net/ethernet/stmicro/stmmac/dwmac4_lib.c | 105 +++++---- .../net/ethernet/stmicro/stmmac/dwmac_dma.h | 22 +- .../net/ethernet/stmicro/stmmac/dwmac_lib.c | 18 +- .../ethernet/stmicro/stmmac/dwxgmac2_core.c | 9 +- .../ethernet/stmicro/stmmac/dwxgmac2_descs.c | 6 +- .../ethernet/stmicro/stmmac/dwxgmac2_dma.c | 71 ++++--- .../net/ethernet/stmicro/stmmac/enh_desc.c | 11 +- drivers/net/ethernet/stmicro/stmmac/hwif.h | 176 ++++++++------- .../net/ethernet/stmicro/stmmac/norm_desc.c | 8 +- .../net/ethernet/stmicro/stmmac/ring_mode.c | 10 +- .../net/ethernet/stmicro/stmmac/stmmac_mdio.c | 3 +- include/linux/stmmac.h | 19 ++ 28 files changed, 886 insertions(+), 474 deletions(-) delete mode 100644 Documentation/devicetree/bindings/net/qcom,ethqos.txt create mode 100644 Documentation/devicetree/bindings/net/qcom,ethqos.yaml
Comments
On Tue, Apr 11, 2023 at 03:03:57PM -0500, Andrew Halaney wrote: > This is a forward port / upstream refactor of code delivered > downstream by Qualcomm over at [0] to enable the DWMAC5 based > implementation called EMAC3 on the sa8540p-ride dev board. > > From what I can tell with the board schematic in hand, > as well as the code delivered, the main changes needed are: > > 1. A new address space layout for dwmac5/EMAC3 MTL/DMA regs > 2. A new programming sequence required for the EMAC3 based platforms > > This series makes the changes above as well as other housekeeping items > such as converting dt-bindings to yaml, etc. > > As requested[1], it has been split up by compilation deps / maintainer tree. > I will post a link to the associated devicetree changes that together > with this series get the hardware functioning. > Link to the devicetree bits: https://lore.kernel.org/netdev/20230411202009.460650-1-ahalaney@redhat.com/T/#t Thanks, Andrew
On Tue, Apr 11, 2023 at 03:03:57PM -0500, Andrew Halaney wrote: > This is a forward port / upstream refactor of code delivered > downstream by Qualcomm over at [0] to enable the DWMAC5 based > implementation called EMAC3 on the sa8540p-ride dev board. > > From what I can tell with the board schematic in hand, > as well as the code delivered, the main changes needed are: > > 1. A new address space layout for dwmac5/EMAC3 MTL/DMA regs > 2. A new programming sequence required for the EMAC3 based platforms > > This series makes the changes above as well as other housekeeping items > such as converting dt-bindings to yaml, etc. > > As requested[1], it has been split up by compilation deps / maintainer tree. > I will post a link to the associated devicetree changes that together > with this series get the hardware functioning. > > Patches 1-3 are clean ups of the currently supported dt-bindings and > IMO could be picked up as is independent of the rest of the series to > improve the current codebase. They've all been reviewed in prior > versions of the series. > > Patches 5-7 are also clean ups of the driver and are worth picking up > independently as well. They don't all have explicit reviews but should > be good to go (trivial changes on non-reviewed bits). > > The rest of the patches have new changes, lack review, or are specificly > being made to support the new hardware, so they should wait until the > series as a whole is deemed ready to go by the community. Looks good to me! Tested-by: Brian Masney <bmasney@redhat.com>
Hello: This series was applied to netdev/net-next.git (main) by Paolo Abeni <pabeni@redhat.com>: On Tue, 11 Apr 2023 15:03:57 -0500 you wrote: > This is a forward port / upstream refactor of code delivered > downstream by Qualcomm over at [0] to enable the DWMAC5 based > implementation called EMAC3 on the sa8540p-ride dev board. > > From what I can tell with the board schematic in hand, > as well as the code delivered, the main changes needed are: > > [...] Here is the summary with links: - [net-next,v4,01/12] dt-bindings: net: snps,dwmac: Update interrupt-names https://git.kernel.org/netdev/net-next/c/d554ba0ea03c - [net-next,v4,02/12] dt-bindings: net: snps,dwmac: Add Qualcomm Ethernet ETHQOS compatibles https://git.kernel.org/netdev/net-next/c/d70c215bdd17 - [net-next,v4,03/12] dt-bindings: net: qcom,ethqos: Convert bindings to yaml https://git.kernel.org/netdev/net-next/c/02e98ce3db14 - [net-next,v4,04/12] dt-bindings: net: qcom,ethqos: Add Qualcomm sc8280xp compatibles https://git.kernel.org/netdev/net-next/c/25926a703ec1 - [net-next,v4,05/12] net: stmmac: Remove unnecessary if statement brackets https://git.kernel.org/netdev/net-next/c/7c6b942b81ca - [net-next,v4,06/12] net: stmmac: Fix DMA typo https://git.kernel.org/netdev/net-next/c/d638dcb52b09 - [net-next,v4,07/12] net: stmmac: Remove some unnecessary void pointers https://git.kernel.org/netdev/net-next/c/0c3f3c4f4b15 - [net-next,v4,08/12] net: stmmac: Pass stmmac_priv in some callbacks https://git.kernel.org/netdev/net-next/c/1d84b487bc2d - [net-next,v4,09/12] net: stmmac: dwmac4: Allow platforms to specify some DMA/MTL offsets https://git.kernel.org/netdev/net-next/c/33719b57f52e - [net-next,v4,10/12] net: stmmac: dwmac-qcom-ethqos: Respect phy-mode and TX delay https://git.kernel.org/netdev/net-next/c/164a9ebe9742 - [net-next,v4,11/12] net: stmmac: dwmac-qcom-ethqos: Use loopback_en for all speeds https://git.kernel.org/netdev/net-next/c/030f1d5972aa - [net-next,v4,12/12] net: stmmac: dwmac-qcom-ethqos: Add EMAC3 support https://git.kernel.org/netdev/net-next/c/b68376191c69 You are awesome, thank you!