From patchwork Mon Mar 13 16:56:12 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Halaney X-Patchwork-Id: 68971 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp1309079wrd; Mon, 13 Mar 2023 10:21:40 -0700 (PDT) X-Google-Smtp-Source: AK7set/6EKfIsTErZIOFLVrygRrxRTq2yATTLT9utfa4kSJWNGbHVkxu1T/bqaI12nCk5eYYD8Yb X-Received: by 2002:a17:902:e5d0:b0:19e:68b1:65b9 with SMTP id u16-20020a170902e5d000b0019e68b165b9mr45184548plf.12.1678728100615; Mon, 13 Mar 2023 10:21:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1678728100; cv=none; d=google.com; s=arc-20160816; b=bnVmxfTLJlL9PyCbbCKYSUkMk961reA42CV8y+u8wM+R5xOokvv0XVkUXgpxNvWLRc /9ycVgMNC9R3MTxjKfW3AAHbhcxlSo22NAYtsl4XpaNvxa13GVdJbWnizYi26MQsvT5P Zq2B+qSUBvYxOd8SqLbZEphi6FFcHtsVOLAh5TDtCQ9THh6EOtqr/wl3XuDjTunNm6qL 5nbUlreaW5szLWZ+WtvMCHWAFRoS7eL6WbxJOnml5C2SpT0Hme9Z9InAbCrf3Hz1fke/ Qzl+b5xYmukzJAqtn/WNBLYk/C1MeepopA0drzru2q8qlIjHxtdEC59OUcrnwMTaiSmt og0w== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=TPEAjXqtLe7sEldj4DCKu8ktiAl8IL0ME/tYH+iy+MU=; b=naG8z0ZriykyKTBo7JOlYHLKwhL3yt1qX/Cz5eAcIR6j4tvbLfwPNBhtX3RoptmsSp htXMZdKBbiNGs1YoQT0KWKqootHN9uKk2RNnlbWrzyhLZhHwgghcj93/N7hIVR5PGHV5 92O3h47iVPkNYcw9N1OUQdRQFScshzc1cUSKbVef59GPgOgmTCgFgvzF96fD2Pr2wHfI aulwWhmk9SbweC3O/Wc2bQIQXO8coeJYALoS5CeFUPtucZFKqnyRFHd2a/mp19P7286e fjWFjVwE43qhbjPP4ylLW9st2gk3xh4Z3lUKPGOygqT79bU4I1fzC3kX4ke3BTDIeP7p Q6AQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=SO3rfhyc; 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 g15-20020a63520f000000b004fb37497be2si6854341pgb.642.2023.03.13.10.21.25; Mon, 13 Mar 2023 10:21:40 -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=SO3rfhyc; 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 S231248AbjCMRAP (ORCPT + 99 others); Mon, 13 Mar 2023 13:00:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57270 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231297AbjCMQ7j (ORCPT ); Mon, 13 Mar 2023 12:59:39 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6C76829144 for ; Mon, 13 Mar 2023 09:58:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1678726656; 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: in-reply-to:in-reply-to:references:references; bh=TPEAjXqtLe7sEldj4DCKu8ktiAl8IL0ME/tYH+iy+MU=; b=SO3rfhyctLuyM9NTiuvyfwwisulnW33M+AWEVq/p65oiG7yaN5oDMDogT2HqMaZVNY6jpR SE0onTjY2DtZdOCt0ERUM//gWQMTCeGORWW7zuXOrEBQ5ql0Bh387V/PFfX/Wb3yq3cBYI DHPOSh+ug5Klrxu0xKkD65V+Vwak8Mc= Received: from mail-oi1-f200.google.com (mail-oi1-f200.google.com [209.85.167.200]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-553-Mp-i2ra4NFqJfcV-G5N1oA-1; Mon, 13 Mar 2023 12:57:35 -0400 X-MC-Unique: Mp-i2ra4NFqJfcV-G5N1oA-1 Received: by mail-oi1-f200.google.com with SMTP id u42-20020a056808152a00b003845d35bfb6so5657430oiw.22 for ; Mon, 13 Mar 2023 09:57:35 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678726654; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=TPEAjXqtLe7sEldj4DCKu8ktiAl8IL0ME/tYH+iy+MU=; b=cQcJZTggogI0+4pLtVfoYC/BG2FjN43xWD6pYmfgqvtEL0FEAv1QkHXOTuJ5d3MmlT w9rdSpFXacPw14bxEPawoQaZoOZtIK2WrmFQMb95/GAWSRYEE47iopV5lyU3mHnezQw7 xWRlq4jeHHTyujVFwN+axr57/smqwnwzDWUWudOP49V28EQwpfOfH3aqi8zcPE+spvpT JShmE4MfMqS4HSvvfg8vMspZjyxnS3cs3hwl+FaIPIEbGNnG6O3/ly2Gw8tBcrUjpy5O BhMqHENtrseRD2OCiRGl71liyqYh80yBZlbkcNJjZaKjaOouGjU8MbfK+hgLl3kQO2HZ EzYA== X-Gm-Message-State: AO0yUKV2F1EyMq64XIOWK/AZVJSggdUsHDv7VGvvB1UlN0dIE78LvBXy LMXfqCo3t25kKdLiAuonH2Al149su5uLA7frmXLoDDmNcGHV1tYfEMaR9MEZPww8ydmaFtWf4R3 eRKm5lOVD1Q9f1v4VFovKOXNUXcq/hq33NZ4ZsWA9Z2gowMvZXmkb1Oh4VyZWBkLbFryFmq2czd lWbsZbPQbWF5w= X-Received: by 2002:a05:6870:d24d:b0:177:81bb:1b1b with SMTP id h13-20020a056870d24d00b0017781bb1b1bmr5506902oac.40.1678726654349; Mon, 13 Mar 2023 09:57:34 -0700 (PDT) X-Received: by 2002:a05:6870:d24d:b0:177:81bb:1b1b with SMTP id h13-20020a056870d24d00b0017781bb1b1bmr5506853oac.40.1678726654035; Mon, 13 Mar 2023 09:57:34 -0700 (PDT) Received: from halaney-x13s.attlocal.net ([2600:1700:1ff0:d0e0::21]) by smtp.gmail.com with ESMTPSA id o2-20020acad702000000b00384d3003fa3sm3365273oig.26.2023.03.13.09.57.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Mar 2023 09:57:33 -0700 (PDT) From: Andrew Halaney 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, mturquette@baylibre.com, sboyd@kernel.org, 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-clk@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, Andrew Halaney Subject: [PATCH net-next 03/11] dt-bindings: net: qcom,ethqos: Convert bindings to yaml Date: Mon, 13 Mar 2023 11:56:12 -0500 Message-Id: <20230313165620.128463-4-ahalaney@redhat.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230313165620.128463-1-ahalaney@redhat.com> References: <20230313165620.128463-1-ahalaney@redhat.com> MIME-Version: 1.0 Content-type: text/plain 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1760273996573878110?= X-GMAIL-MSGID: =?utf-8?q?1760273996573878110?= From: Bhupesh Sharma Convert Qualcomm ETHQOS Ethernet devicetree binding to YAML. While at it, also update the MAINTAINERS file to point to the yaml version of the bindings. Signed-off-by: Bhupesh Sharma [halaney: Remove duplicated snps,dwmac.yaml properties, add MAINTAINERS] Signed-off-by: Andrew Halaney --- I picked this up from: https://lore.kernel.org/netdev/20220929060405.2445745-4-bhupesh.sharma@linaro.org/ Changes since then include: * Change MAINTAINERS atomically with the filename change * Remove duplicated snps,dwmac.yaml properties As listed on that thread, the issues Bhupesh saw were due to a bug in dtschema that has since been fixed. .../devicetree/bindings/net/qcom,ethqos.txt | 66 ----------- .../devicetree/bindings/net/qcom,ethqos.yaml | 112 ++++++++++++++++++ MAINTAINERS | 2 +- 3 files changed, 113 insertions(+), 67 deletions(-) delete mode 100644 Documentation/devicetree/bindings/net/qcom,ethqos.txt create mode 100644 Documentation/devicetree/bindings/net/qcom,ethqos.yaml diff --git a/Documentation/devicetree/bindings/net/qcom,ethqos.txt b/Documentation/devicetree/bindings/net/qcom,ethqos.txt deleted file mode 100644 index 1f5746849a71..000000000000 --- a/Documentation/devicetree/bindings/net/qcom,ethqos.txt +++ /dev/null @@ -1,66 +0,0 @@ -Qualcomm Ethernet ETHQOS device - -This documents dwmmac based ethernet device which supports Gigabit -ethernet for version v2.3.0 onwards. - -This device has following properties: - -Required properties: - -- compatible: Should be one of: - "qcom,qcs404-ethqos" - "qcom,sm8150-ethqos" - -- reg: Address and length of the register set for the device - -- reg-names: Should contain register names "stmmaceth", "rgmii" - -- clocks: Should contain phandle to clocks - -- clock-names: Should contain clock names "stmmaceth", "pclk", - "ptp_ref", "rgmii" - -- interrupts: Should contain phandle to interrupts - -- interrupt-names: Should contain interrupt names "macirq", "eth_lpi" - -Rest of the properties are defined in stmmac.txt file in same directory - - -Example: - -ethernet: ethernet@7a80000 { - compatible = "qcom,qcs404-ethqos"; - reg = <0x07a80000 0x10000>, - <0x07a96000 0x100>; - reg-names = "stmmaceth", "rgmii"; - clock-names = "stmmaceth", "pclk", "ptp_ref", "rgmii"; - clocks = <&gcc GCC_ETH_AXI_CLK>, - <&gcc GCC_ETH_SLAVE_AHB_CLK>, - <&gcc GCC_ETH_PTP_CLK>, - <&gcc GCC_ETH_RGMII_CLK>; - interrupts = , - ; - interrupt-names = "macirq", "eth_lpi"; - snps,reset-gpio = <&tlmm 60 GPIO_ACTIVE_LOW>; - snps,reset-active-low; - - snps,txpbl = <8>; - snps,rxpbl = <2>; - snps,aal; - snps,tso; - - phy-handle = <&phy1>; - phy-mode = "rgmii"; - - mdio { - #address-cells = <0x1>; - #size-cells = <0x0>; - compatible = "snps,dwmac-mdio"; - phy1: phy@4 { - device_type = "ethernet-phy"; - reg = <0x4>; - }; - }; - -}; diff --git a/Documentation/devicetree/bindings/net/qcom,ethqos.yaml b/Documentation/devicetree/bindings/net/qcom,ethqos.yaml new file mode 100644 index 000000000000..68ef43fb283d --- /dev/null +++ b/Documentation/devicetree/bindings/net/qcom,ethqos.yaml @@ -0,0 +1,112 @@ +# SPDX-License-Identifier: GPL-2.0 OR BSD-2-Clause +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/net/qcom,ethqos.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Qualcomm Ethernet ETHQOS device + +maintainers: + - Bhupesh Sharma + +description: + This binding describes the dwmmac based Qualcomm ethernet devices which + support Gigabit ethernet (version v2.3.0 onwards). + + So, this file documents platform glue layer for dwmmac stmmac based Qualcomm + ethernet devices. + +allOf: + - $ref: snps,dwmac.yaml# + +properties: + compatible: + enum: + - qcom,qcs404-ethqos + - qcom,sm8150-ethqos + + reg: + maxItems: 2 + + reg-names: + items: + - const: stmmaceth + - const: rgmii + + interrupts: + items: + - description: Combined signal for various interrupt events + - description: The interrupt that occurs when Rx exits the LPI state + + interrupt-names: + items: + - const: macirq + - const: eth_lpi + + clocks: + maxItems: 4 + + clock-names: + items: + - const: stmmaceth + - const: pclk + - const: ptp_ref + - const: rgmii + + iommus: + maxItems: 1 + +required: + - compatible + - clocks + - clock-names + +unevaluatedProperties: false + +examples: + - | + #include + #include + #include + + ethernet: ethernet@7a80000 { + compatible = "qcom,qcs404-ethqos"; + reg = <0x07a80000 0x10000>, + <0x07a96000 0x100>; + reg-names = "stmmaceth", "rgmii"; + clock-names = "stmmaceth", "pclk", "ptp_ref", "rgmii"; + clocks = <&gcc GCC_ETH_AXI_CLK>, + <&gcc GCC_ETH_SLAVE_AHB_CLK>, + <&gcc GCC_ETH_PTP_CLK>, + <&gcc GCC_ETH_RGMII_CLK>; + interrupts = , + ; + interrupt-names = "macirq", "eth_lpi"; + + rx-fifo-depth = <4096>; + tx-fifo-depth = <4096>; + + snps,tso; + snps,reset-gpio = <&tlmm 60 GPIO_ACTIVE_LOW>; + snps,reset-active-low; + snps,reset-delays-us = <0 10000 10000>; + + pinctrl-names = "default"; + pinctrl-0 = <ðernet_defaults>; + + phy-handle = <&phy1>; + phy-mode = "rgmii"; + mdio { + #address-cells = <0x1>; + #size-cells = <0x0>; + + compatible = "snps,dwmac-mdio"; + phy1: phy@4 { + compatible = "ethernet-phy-ieee802.3-c22"; + device_type = "ethernet-phy"; + reg = <0x4>; + + #phy-cells = <0>; + }; + }; + }; diff --git a/MAINTAINERS b/MAINTAINERS index 8d5bc223f305..720ae2f1bf95 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -17282,7 +17282,7 @@ M: Vinod Koul R: Bhupesh Sharma L: netdev@vger.kernel.org S: Maintained -F: Documentation/devicetree/bindings/net/qcom,ethqos.txt +F: Documentation/devicetree/bindings/net/qcom,ethqos.yaml F: drivers/net/ethernet/stmicro/stmmac/dwmac-qcom-ethqos.c QUALCOMM FASTRPC DRIVER