Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp3861199rwl; Mon, 10 Apr 2023 02:10:18 -0700 (PDT) X-Google-Smtp-Source: AKy350Zl6gjC6mfhIJdbyZGu+UA3JSZ5cq/zXKtOVE/mOo5g4mkn1BR4YpAGEAZmvTMMPkXUWkuv X-Received: by 2002:a17:90b:33c4:b0:237:161d:f5ac with SMTP id lk4-20020a17090b33c400b00237161df5acmr12639895pjb.36.1681117818257; Mon, 10 Apr 2023 02:10:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681117818; cv=none; d=google.com; s=arc-20160816; b=K2sLQC7ArpYSOmI72rpVa3F99mYBUienq0gODctUtotRfMssGraYMgbZIssFkJvzS0 rKE5fKQZHdEsOTl+kxF77Dlpi9rBj0AtDR5Ir2CHjuICNfKwN1MoGixvGEnwyZPz7U6D rZC4GBxabPsh2EITf0bs/4Hqn9p8FFGXuwSojprS8/XSQJC6vCbETENEIFFS14hUYVY9 eMz3ditenhyoC9uCfXmliut7M+ONx4GjzR6Rr2+quTdkVeCYLXUNbpdtsVDiH4Z1f2e+ +J7tlnjm8tt+eL7FrD3m9/Vqat3rrMoU5MqVdWx54JYEhgJF1w9yfgQaZulsYjnuDV9P 52Xw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id; bh=0SNN+hhMnFfAAtR0Q9Lb4IuVh0AvAZi6yBpr4dOh1YM=; b=tqFV8R/MX0zAm3Pq28IjEeM72pkE7YDe7I/5woc8Teskdqx5Ab+xX0p1/ciKyqlxRX cCzuFaJgAn/bmRdywUMBqOXD8I2lG/jP1M0BJHN344Ll5C6dfXSJvTEVHzS2/guN4bmo Z46wC/MxIKrdWfhvRVlRO1oyaYwVjC0X6Gslb8GHHizvIXs3klrOCD02jByI7C/O5UHf rEVxZgbI2pssQCbk+p8KK0rYmpMraqi/tT5OVCEfXanfOCvgA4XpDC4EPc9xsXRqqGvv TEYeVFlJ9L9KlTPCX2oNG8HdQh2/z/gIkY5tTCZNdHb34daVlGfEfkJrrzHpZGDI/Qb9 v4kQ== 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 w2-20020a17090aad4200b002449fd20726si9472427pjv.64.2023.04.10.02.10.05; Mon, 10 Apr 2023 02:10:18 -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 S229690AbjDJJFX (ORCPT + 99 others); Mon, 10 Apr 2023 05:05:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59508 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229608AbjDJJFW (ORCPT ); Mon, 10 Apr 2023 05:05:22 -0400 Received: from ex01.ufhost.com (ex01.ufhost.com [61.152.239.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6D2C730C3; Mon, 10 Apr 2023 02:05:20 -0700 (PDT) Received: from EXMBX166.cuchost.com (unknown [175.102.18.54]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "EXMBX166", Issuer "EXMBX166" (not verified)) by ex01.ufhost.com (Postfix) with ESMTP id 04B7C24E2A1; Mon, 10 Apr 2023 17:05:19 +0800 (CST) Received: from EXMBX171.cuchost.com (172.16.6.91) by EXMBX166.cuchost.com (172.16.6.76) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Mon, 10 Apr 2023 17:05:18 +0800 Received: from [192.168.125.108] (113.72.145.176) by EXMBX171.cuchost.com (172.16.6.91) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Mon, 10 Apr 2023 17:05:17 +0800 Message-ID: <430f1eb0-e348-8a4e-b501-16b8c3b2494f@starfivetech.com> Date: Mon, 10 Apr 2023 17:05:17 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.9.1 Subject: Re: [PATCH v1 1/3] dt-binding: pci: add JH7110 PCIe dt-binding documents. Content-Language: en-US To: Krzysztof Kozlowski , Emil Renner Berthing , Conor Dooley , "Rob Herring" , Bjorn Helgaas , "Krzysztof Kozlowski" , Lorenzo Pieralisi , =?UTF-8?Q?Krzysztof_Wilczy=c5=84ski?= CC: , , , , Paul Walmsley , Palmer Dabbelt , Albert Ou , Philipp Zabel , Mason Huo , Leyfoon Tan , Kevin Xie References: <20230406111142.74410-1-minda.chen@starfivetech.com> <20230406111142.74410-2-minda.chen@starfivetech.com> <38bc48bf-7d8c-8ddd-861f-3b7f3d2edce6@linaro.org> From: Minda Chen In-Reply-To: <38bc48bf-7d8c-8ddd-861f-3b7f3d2edce6@linaro.org> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Originating-IP: [113.72.145.176] X-ClientProxiedBy: EXCAS064.cuchost.com (172.16.6.24) To EXMBX171.cuchost.com (172.16.6.91) X-YovoleRuleAgent: yovoleflag X-Spam-Status: No, score=-3.2 required=5.0 tests=NICE_REPLY_A,SPF_HELO_NONE, SPF_PASS 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 On 2023/4/7 2:24, Krzysztof Kozlowski wrote: > On 06/04/2023 13:11, Minda Chen wrote: >> Add PCIe controller driver dt-binding documents >> for StarFive JH7110 SoC platform. > > Use subject prefixes matching the subsystem (which you can get for > example with `git log --oneline -- DIRECTORY_OR_FILE` on the directory > your patch is touching). Missing: 's' > > Subject: drop second/last, redundant "dt-binding documents". The > "dt-bindings" prefix is already stating that these are bindings and > documentation. > > Drop also full stop. > ok, thanks >> >> Signed-off-by: Minda Chen >> --- >> .../bindings/pci/starfive,jh7110-pcie.yaml | 163 ++++++++++++++++++ >> 1 file changed, 163 insertions(+) >> create mode 100644 Documentation/devicetree/bindings/pci/starfive,jh7110-pcie.yaml >> >> diff --git a/Documentation/devicetree/bindings/pci/starfive,jh7110-pcie.yaml b/Documentation/devicetree/bindings/pci/starfive,jh7110-pcie.yaml >> new file mode 100644 >> index 000000000000..fa4829766195 >> --- /dev/null >> +++ b/Documentation/devicetree/bindings/pci/starfive,jh7110-pcie.yaml >> @@ -0,0 +1,163 @@ >> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) >> +%YAML 1.2 >> +--- >> +$id: http://devicetree.org/schemas/pci/starfive,jh7110-pcie.yaml# >> +$schema: http://devicetree.org/meta-schemas/core.yaml# >> + >> +title: StarFive JH7110 PCIe 2.0 host controller >> + >> +maintainers: >> + - Minda Chen >> + >> +allOf: >> + - $ref: /schemas/pci/pci-bus.yaml# >> + - $ref: /schemas/interrupt-controller/msi-controller.yaml# >> + >> +properties: >> + compatible: >> + const: starfive,jh7110-pcie >> + >> + reg: >> + maxItems: 2 >> + >> + reg-names: >> + items: >> + - const: reg >> + - const: config >> + >> + msi-parent: true >> + >> + interrupts: >> + maxItems: 1 >> + >> + clocks: >> + maxItems: 4 >> + >> + clock-names: >> + items: >> + - const: noc >> + - const: tl >> + - const: axi_mst0 >> + - const: apb >> + >> + resets: >> + items: >> + - description: AXI MST0 reset >> + - description: AXI SLAVE reset >> + - description: AXI SLAVE0 reset >> + - description: PCIE BRIDGE reset >> + - description: PCIE CORE reset >> + - description: PCIE APB reset >> + >> + reset-names: >> + items: >> + - const: mst0 >> + - const: slv0 >> + - const: slv >> + - const: brg >> + - const: core >> + - const: apb >> + >> + starfive,stg-syscon: >> + $ref: /schemas/types.yaml#/definitions/phandle-array >> + items: >> + items: >> + - description: phandle to System Register Controller stg_syscon node. >> + - description: register0 offset of STG_SYSCONSAIF__SYSCFG register for PCIe. >> + - description: register1 offset of STG_SYSCONSAIF__SYSCFG register for PCIe. >> + - description: register2 offset of STG_SYSCONSAIF__SYSCFG register for PCIe. >> + - description: register3 offset of STG_SYSCONSAIF__SYSCFG register for PCIe. >> + description: >> + The phandle to System Register Controller syscon node and the offset >> + of STG_SYSCONSAIF__SYSCFG register for PCIe. Total 4 regsisters offset >> + for PCIe. >> + >> + pwren-gpios: >> + description: Should specify the GPIO for controlling the PCI bus device power on. > > What are these? Different than defined in gpio-consumer-common? > power gpio board level configuration. It it not a requried property >> + maxItems: 1 >> + >> + reset-gpios: >> + maxItems: 1 >> + >> + phys: >> + maxItems: 1 >> + >> + interrupt-controller: >> + type: object >> + properties: >> + '#address-cells': >> + const: 0 >> + >> + '#interrupt-cells': >> + const: 1 >> + >> + interrupt-controller: true >> + >> + required: >> + - '#address-cells' >> + - '#interrupt-cells' >> + - interrupt-controller >> + >> + additionalProperties: false >> + >> +required: >> + - reg >> + - reg-names >> + - "#interrupt-cells" > > Keep consistent quotes - either ' or " > > Are you sure this is correct? You have interrupt controller as child node. > > >> + - interrupts >> + - interrupt-map-mask >> + - interrupt-map >> + - clocks >> + - clock-names >> + - resets >> + - msi-controller >> + >> +unevaluatedProperties: false >> + >> +examples: >> + - | >> + bus { >> + #address-cells = <2>; >> + #size-cells = <2>; >> + >> + pcie0: pcie@2B000000 { > > Lowercase hex. Everywhere. > ok >> + compatible = "starfive,jh7110-pcie"; >> + #address-cells = <3>; >> + #size-cells = <2>; >> + #interrupt-cells = <1>; >> + reg = <0x0 0x2B000000 0x0 0x1000000>, >> + <0x9 0x40000000 0x0 0x10000000>; > > reg (and reg-names and ranges) is always second property. > ok >> + reg-names = "reg", "config"; >> + device_type = "pci"; >> + starfive,stg-syscon = <&stg_syscon 0xc0 0xc4 0x130 0x1b8>; >> + bus-range = <0x0 0xff>; >> + ranges = <0x82000000 0x0 0x30000000 0x0 0x30000000 0x0 0x08000000>, >> + <0xc3000000 0x9 0x00000000 0x9 0x00000000 0x0 0x40000000>; >> + interrupt-parent = <&plic>; >> + interrupts = <56>; >> + interrupt-map-mask = <0x0 0x0 0x0 0x7>; >> + interrupt-map = <0x0 0x0 0x0 0x1 &pcie_intc0 0x1>, >> + <0x0 0x0 0x0 0x2 &pcie_intc0 0x2>, >> + <0x0 0x0 0x0 0x3 &pcie_intc0 0x3>, >> + <0x0 0x0 0x0 0x4 &pcie_intc0 0x4>; > > > Best regards, > Krzysztof >