Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp727832rwl; Wed, 12 Apr 2023 03:18:59 -0700 (PDT) X-Google-Smtp-Source: AKy350bLYjLnj5P5xNZxofkVCH5E5Tygk/zfRLzRiGkyWwg4AIIHw1MEJPxTfLQZhdZs86bwDXIW X-Received: by 2002:a17:906:a987:b0:94e:2db:533e with SMTP id jr7-20020a170906a98700b0094e02db533emr5231233ejb.49.1681294739355; Wed, 12 Apr 2023 03:18:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681294739; cv=none; d=google.com; s=arc-20160816; b=XtvbzI9ho/3TpiLI8ZK0u4iIarDZYvTCWHUlw6G4PfhHhxUzwQQN4PhXadGW1EAhd2 LtvFOHL/fkzRo8vhj/5aSwLNrUGsgyRWLVpCI4Mz8Bs6E0PKUAy0VKGULvh/Sjs8MEvr qokdaVQYtksCZTTqAWQG4mB6YUTdSKkslkerxtm3ATLzg0Dj5GJ+It1qXIO3pZqs9LIC tXhrlj5RWuoVzANVm/vYCxPPm9F4JOnun4kohCnmn/w00Ou5Bc4MiaPXU3ADhoPXjiiO MMPXvZSpt3y+vu/mdc1r2jbBpqegT4BpQ7xEaAJRVb+GKgVNUWwzLdvVAHfZaD7VpV4A Qr5Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=PcDUlmxRY10X0YHmhy/Fi+Rk8z1h3TiNmSt5ErLw9W4=; b=1ByWoYGjZdjmAdMVe9PVSm+8pfxbASQTliQJ4Eti4625Hk5bkYylM0qhb9noiUnicd QHUi9u2EavcNtYZv3VOdO3qpt9g2EZryNS5ahGhZtGoDEuW/pp2WaDNPHRfAwaI2gcrP EqjIXteRhmuWLHU9IdmWjpCIzMZN9yXYjwThfY95pQHspv+hxgOtk9lyhNHlJl9dWik/ oHQsUX9HAMlbdwyQmYPUyXml4V46qTPl9sDqhGa99OqnLBbXQKlsx+0rt0lfK19EAoh/ lHKGrnJrnHWaOlScHBBIvP++fMUnFKgd9viJYrH2sFvRCSs+fAGPzipKbnoI+ScBuI2h zG1Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=DGfPyUoD; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id jx8-20020a170907760800b0094c1720afccsi3147888ejc.887.2023.04.12.03.18.34; Wed, 12 Apr 2023 03:18:59 -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=@gmail.com header.s=20221208 header.b=DGfPyUoD; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231234AbjDLKSD (ORCPT + 99 others); Wed, 12 Apr 2023 06:18:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33424 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230522AbjDLKSB (ORCPT ); Wed, 12 Apr 2023 06:18:01 -0400 Received: from mail-ej1-x629.google.com (mail-ej1-x629.google.com [IPv6:2a00:1450:4864:20::629]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7965730FF; Wed, 12 Apr 2023 03:17:59 -0700 (PDT) Received: by mail-ej1-x629.google.com with SMTP id qa44so27146136ejc.4; Wed, 12 Apr 2023 03:17:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1681294678; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=PcDUlmxRY10X0YHmhy/Fi+Rk8z1h3TiNmSt5ErLw9W4=; b=DGfPyUoDRTIQzp1lmPfZIF7Ok/pIl6tEBRG4Fz9fac09VFqNNEQFoztcxaUPunqdA0 iujWFxf9VBvUzff6T33wh6G7mrq3dZK54zcmaUMm5Oegj2OzfQSQpEinN2TLVu/3mOwY TFQzRTk5YZ7kGXA6lYAG3D19pmHk/AabQrtra3tb5zlEDq0X8LeQV1u3x27KzokkTwra XM0le3PAkgp7p8vbVMQmK/WhMDNCCAyd6rCQ20dso1NT0TPtmAucC43ilWNXMfyz+4I8 k6C48JpiFfJN9SG57JzH2O5iRRvx/HqqCcNFUnN2qjxgIuVjMZaOWYxbURmrBRjTQ8lw vczw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1681294678; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=PcDUlmxRY10X0YHmhy/Fi+Rk8z1h3TiNmSt5ErLw9W4=; b=jrm4Hf6BSGUku21QekAiYrrFpNkp8zgfi1gELUeW2zJkJBpy+EaDOrdUUblVSg2t8A Ey0/S9mSf3DPj5s4O25e+KYqBWdfhMY83+eKDX6LcfN4mZPJQK/lNkyqPLJM9xSLQP3G o/n9Ifcl4P8+7/VyI1iH+4cWchu92LtdniEVQZfxP9czedqz8HXnqagsaOFLCSrO/gBq yNpl/RbafsMMrGREmlU66fJRU3t8MJYPhQMe1YO06v+wT8DQp7cquJ6ifMvwuEIGUUVN BoQT5tQEtYttLZR6mfQeQt5MIjdkuoWob1kUK5Jew55rQbPyxesniPjGp7p5oLljaU3e 2JDg== X-Gm-Message-State: AAQBX9ete9IHQPTesDopQqbptlvV9/aOg71WbDtdbZbeCyWF+9PgeH1d xr1lbHGIvTD7qP9ndKYRnWtq8MHpI23oJ+bujFg= X-Received: by 2002:a17:906:9f0c:b0:949:87e1:5b32 with SMTP id fy12-20020a1709069f0c00b0094987e15b32mr2986699ejc.9.1681294677803; Wed, 12 Apr 2023 03:17:57 -0700 (PDT) MIME-Version: 1.0 References: <20230406111142.74410-1-minda.chen@starfivetech.com> <20230406111142.74410-2-minda.chen@starfivetech.com> In-Reply-To: <20230406111142.74410-2-minda.chen@starfivetech.com> From: Bin Meng Date: Wed, 12 Apr 2023 18:17:46 +0800 Message-ID: Subject: Re: [PATCH v1 1/3] dt-binding: pci: add JH7110 PCIe dt-binding documents. To: Minda Chen Cc: Emil Renner Berthing , Conor Dooley , Rob Herring , Bjorn Helgaas , Krzysztof Kozlowski , Lorenzo Pieralisi , =?UTF-8?Q?Krzysztof_Wilczy=C5=84ski?= , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org, linux-pci@vger.kernel.org, Paul Walmsley , Palmer Dabbelt , Albert Ou , Philipp Zabel , Mason Huo , Leyfoon Tan , Kevin Xie Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham 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 Thu, Apr 6, 2023 at 7:59=E2=80=AFPM Minda Chen wrote: > > Add PCIe controller driver dt-binding documents > for StarFive JH7110 SoC platform. > > 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.y= aml 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 Since this is a PLDA IP that is likely to be reused by other vendors, should this indicate the PLDA in the string? Or the file name should be renamed to something like the synopsis dw-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 regist= er for PCIe. > + - description: register1 offset of STG_SYSCONSAIF__SYSCFG regist= er for PCIe. > + - description: register2 offset of STG_SYSCONSAIF__SYSCFG regist= er for PCIe. > + - description: register3 offset of STG_SYSCONSAIF__SYSCFG regist= er for PCIe. > + description: > + The phandle to System Register Controller syscon node and the offs= et > + of STG_SYSCONSAIF__SYSCFG register for PCIe. Total 4 regsisters of= fset > + for PCIe. > + > + pwren-gpios: > + description: Should specify the GPIO for controlling the PCI bus dev= ice power on. > + 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" > + - interrupts > + - interrupt-map-mask > + - interrupt-map > + - clocks > + - clock-names > + - resets > + - msi-controller > + > +unevaluatedProperties: false > + > +examples: > + - | > + bus { > + #address-cells =3D <2>; > + #size-cells =3D <2>; > + > + pcie0: pcie@2B000000 { > + compatible =3D "starfive,jh7110-pcie"; > + #address-cells =3D <3>; > + #size-cells =3D <2>; > + #interrupt-cells =3D <1>; > + reg =3D <0x0 0x2B000000 0x0 0x1000000>, > + <0x9 0x40000000 0x0 0x10000000>; > + reg-names =3D "reg", "config"; > + device_type =3D "pci"; > + starfive,stg-syscon =3D <&stg_syscon 0xc0 0xc4 0x130 0x1b8>; > + bus-range =3D <0x0 0xff>; > + ranges =3D <0x82000000 0x0 0x30000000 0x0 0x30000000 0x0 0= x08000000>, > + <0xc3000000 0x9 0x00000000 0x9 0x00000000 0x0 0x4= 0000000>; > + interrupt-parent =3D <&plic>; > + interrupts =3D <56>; > + interrupt-map-mask =3D <0x0 0x0 0x0 0x7>; > + interrupt-map =3D <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>; > + msi-parent =3D <&pcie0>; > + msi-controller; > + clocks =3D <&syscrg 86>, > + <&stgcrg 10>, > + <&stgcrg 8>, > + <&stgcrg 9>; > + clock-names =3D "noc", "tl", "axi_mst0", "apb"; > + resets =3D <&stgcrg 11>, > + <&stgcrg 12>, > + <&stgcrg 13>, > + <&stgcrg 14>, > + <&stgcrg 15>, > + <&stgcrg 16>; > + > + pcie_intc0: interrupt-controller { > + #address-cells =3D <0>; > + #interrupt-cells =3D <1>; > + interrupt-controller; > + }; > + }; > + }; > -- Regards, Bin