From patchwork Wed Nov 9 00:24:48 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Vasut X-Patchwork-Id: 13036989 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id CED96C4332F for ; Wed, 9 Nov 2022 00:26:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=Sb4UNNqBwFnGbc//yg7HDwQIZDcEUcJfO62nm6qMhs8=; b=t5EuLa4z2xm65o Cplc3ntzea7tYC9aZPv3jdkEsPj7v4+cz4MWn8JrIKocpzwvkaP8Uik11jv3nZjgE8SxSBOuDYAjm X4LWu/vuJQ8fOqaAXktyQK0esB/uNXdm1ZygmkKjrYt+UotuJWApbGI/VmBGjA/MTKyPrf0Kih3Hv x5Um1htUz8jComLKRr6NmkvfzchX0lc2cngsid6KMjnfRqUYudscxi9OGGceHEkATF3aZYdGJjKXA 8W0EG195LBOFKARXXhjVh9/GgqilytjHvR7Y2Uamq0ldHFBnHXzlvAVS68K4/e25AD3SPqfGZm4CJ UsUHH50ivHyKUoWra3cw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1osYu0-009OSz-9h; Wed, 09 Nov 2022 00:25:12 +0000 Received: from phobos.denx.de ([2a01:238:438b:c500:173d:9f52:ddab:ee01]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1osYtw-009ORt-Dr for linux-arm-kernel@lists.infradead.org; Wed, 09 Nov 2022 00:25:10 +0000 Received: from tr.lan (ip-86-49-120-218.bb.vodafone.cz [86.49.120.218]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: marex@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id AD7C983F5B; Wed, 9 Nov 2022 01:25:06 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1667953507; bh=4wMjYp7bVpBOoU+DcIkJJXPh5+Jl47yQYn92CLwQGV0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=phPORB+AU/3LslyAN/faXXZCyLlr8sV/cJoxtR25NxADuMx2MpKNj+jfpSi9U5wDJ 2XR290t6bbqq6DKisz0vtjFQTqGm/AmeTWXNGwX4EYZTIj6/gmLJh1D1hxJNhY7Nlr 6lUjMCmnIGJ7odw2uX0yQYZMly+3pBRQbWthF+LmB8aGt6HIQxD2jlkkRyiWtsurhv GNT5zxNOxBU7udCs04wUeo63zLfDMLsiVDYntZSbTrptQtizIdtAqIojjt5GhjmjGg Ak/fwlsT7DLS6mzvAio2o5GxcwHomSFeXZnNIpqHjjoLDTQY39UvpOB6g9o4EVWHXg 9zVlKPu/VTdJA== From: Marek Vasut To: devicetree@vger.kernel.org Cc: Marek Vasut , Krzysztof Kozlowski , Fabio Estevam , Krzysztof Kozlowski , Lucas Stach , Richard Zhu , Rob Herring , Shawn Guo , linux-arm-kernel@lists.infradead.org, NXP Linux Team Subject: [PATCH v5 2/3] dt-bindings: imx6q-pcie: Handle various PD configurations Date: Wed, 9 Nov 2022 01:24:48 +0100 Message-Id: <20221109002449.35936-2-marex@denx.de> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109002449.35936-1-marex@denx.de> References: <20221109002449.35936-1-marex@denx.de> MIME-Version: 1.0 X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221108_162508_805626_959AB6A4 X-CRM114-Status: GOOD ( 12.62 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The i.MX SoCs have various power domain configurations routed into the PCIe IP. MX6SX is the only one which contains 2 domains and also uses power-domain-names. MX6QDL do not use any domains. All the rest uses one domain and does not use power-domain-names anymore. Document all those configurations in the DT binding document. Reviewed-by: Krzysztof Kozlowski Signed-off-by: Marek Vasut --- Cc: Fabio Estevam Cc: Krzysztof Kozlowski Cc: Lucas Stach Cc: Richard Zhu Cc: Rob Herring Cc: Shawn Guo Cc: linux-arm-kernel@lists.infradead.org Cc: NXP Linux Team To: devicetree@vger.kernel.org --- V2: - Keep the power-domains description in the main section V3: - Move power-domains back where they were originally (fixes V2) - Do not use else: in allOf section V4: - Special-case MX6Q and MX6QP in allOf section since they dont use PDs - Drop minItems: from power-domains main section - Handle anything which is not MX6SX,MX6Q,MX6QP as having one PD V5: - Add RB from Krzysztof --- .../bindings/pci/fsl,imx6q-pcie.yaml | 43 +++++++++++++++++++ 1 file changed, 43 insertions(+) diff --git a/Documentation/devicetree/bindings/pci/fsl,imx6q-pcie.yaml b/Documentation/devicetree/bindings/pci/fsl,imx6q-pcie.yaml index 2df73be0ffbea..b14c12a47cc1c 100644 --- a/Documentation/devicetree/bindings/pci/fsl,imx6q-pcie.yaml +++ b/Documentation/devicetree/bindings/pci/fsl,imx6q-pcie.yaml @@ -69,6 +69,7 @@ properties: required properties for imx7d-pcie and imx8mq-pcie. power-domains: + minItems: 1 items: - description: The phandle pointing to the DISPLAY domain for imx6sx-pcie, to PCIE_PHY power domain for imx7d-pcie and @@ -77,6 +78,7 @@ properties: for imx6sx-pcie. power-domain-names: + minItems: 1 items: - const: pcie - const: pcie_phy @@ -240,6 +242,47 @@ allOf: - const: pcie_bus - const: pcie_aux + - if: + properties: + compatible: + contains: + const: fsl,imx6sx-pcie + then: + properties: + power-domains: + minItems: 2 + maxItems: 2 + power-domain-names: + minItems: 2 + maxItems: 2 + + - if: + properties: + compatible: + contains: + enum: + - fsl,imx6q-pcie + - fsl,imx6qp-pcie + then: + properties: + power-domains: false + power-domain-names: false + + - if: + not: + properties: + compatible: + contains: + enum: + - fsl,imx6sx-pcie + - fsl,imx6q-pcie + - fsl,imx6qp-pcie + then: + properties: + power-domains: + maxItems: 1 + power-domain-names: false + examples: - | #include