linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Joy Zou <joy.zou@nxp.com>
To: robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org,
	shawnguo@kernel.org, s.hauer@pengutronix.de,
	kernel@pengutronix.de, festevam@gmail.com, peng.fan@nxp.com,
	richardcochran@gmail.com, catalin.marinas@arm.com,
	will@kernel.org, ulf.hansson@linaro.org, andrew+netdev@lunn.ch,
	davem@davemloft.net, edumazet@google.com, kuba@kernel.org,
	pabeni@redhat.com, mcoquelin.stm32@gmail.com,
	alexandre.torgue@foss.st.com, frieder.schrempf@kontron.de,
	primoz.fiser@norik.com, othacehe@gnu.org,
	Markus.Niebel@ew.tq-group.com, alexander.stein@ew.tq-group.com
Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
	imx@lists.linux.dev, linux-arm-kernel@lists.infradead.org,
	linux@ew.tq-group.com, netdev@vger.kernel.org,
	linux-pm@vger.kernel.org,
	linux-stm32@st-md-mailman.stormreply.com, Frank.Li@nxp.com
Subject: [PATCH v7 02/11] dt-bindings: soc: imx-blk-ctrl: add i.MX91 blk-ctrl compatible
Date: Mon, 28 Jul 2025 15:14:29 +0800	[thread overview]
Message-ID: <20250728071438.2332382-3-joy.zou@nxp.com> (raw)
In-Reply-To: <20250728071438.2332382-1-joy.zou@nxp.com>

Add new compatible string "fsl,imx91-media-blk-ctrl" for i.MX91,
which has different input clocks compared to i.MX93. Update the
clock-names list and handle it in the if-else branch accordingly.

Keep the same restriction for the existed compatible strings.

Reviewed-by: Frank Li <Frank.Li@nxp.com>
Signed-off-by: Joy Zou <joy.zou@nxp.com>
---
Changes for v7:
1. add clocks constraints in the if-else branch.
2. reorder the imx93 and imx91 if-else branch.
   These changes come from review comments:
   https://lore.kernel.org/imx/urgfsmkl25woqy5emucfkqs52qu624po6rd532hpusg3fdnyg3@s5iwmhnfsi26/
4. add Reviewed-by tag.

Changes for v5:
1. The i.MX91 has different input clocks compared to i.MX93,
   so add new compatible string for i.MX91.
2. update clock-names list and handle it in the if-else branch.
---
 .../soc/imx/fsl,imx93-media-blk-ctrl.yaml     | 59 +++++++++++++++----
 1 file changed, 47 insertions(+), 12 deletions(-)

diff --git a/Documentation/devicetree/bindings/soc/imx/fsl,imx93-media-blk-ctrl.yaml b/Documentation/devicetree/bindings/soc/imx/fsl,imx93-media-blk-ctrl.yaml
index b3554e7f9e76..15e6f390b53b 100644
--- a/Documentation/devicetree/bindings/soc/imx/fsl,imx93-media-blk-ctrl.yaml
+++ b/Documentation/devicetree/bindings/soc/imx/fsl,imx93-media-blk-ctrl.yaml
@@ -18,7 +18,9 @@ description:
 properties:
   compatible:
     items:
-      - const: fsl,imx93-media-blk-ctrl
+      - enum:
+          - fsl,imx91-media-blk-ctrl
+          - fsl,imx93-media-blk-ctrl
       - const: syscon
 
   reg:
@@ -31,21 +33,54 @@ properties:
     maxItems: 1
 
   clocks:
+    minItems: 8
     maxItems: 10
 
   clock-names:
-    items:
-      - const: apb
-      - const: axi
-      - const: nic
-      - const: disp
-      - const: cam
-      - const: pxp
-      - const: lcdif
-      - const: isi
-      - const: csi
-      - const: dsi
+    minItems: 8
+    maxItems: 10
 
+allOf:
+  - if:
+      properties:
+        compatible:
+          contains:
+            const: fsl,imx91-media-blk-ctrl
+    then:
+      properties:
+        clocks:
+          maxItems: 8
+        clock-names:
+          items:
+            - const: apb
+            - const: axi
+            - const: nic
+            - const: disp
+            - const: cam
+            - const: lcdif
+            - const: isi
+            - const: csi
+  - if:
+      properties:
+        compatible:
+          contains:
+            const: fsl,imx93-media-blk-ctrl
+    then:
+      properties:
+        clocks:
+          minItems: 10
+        clock-names:
+          items:
+            - const: apb
+            - const: axi
+            - const: nic
+            - const: disp
+            - const: cam
+            - const: pxp
+            - const: lcdif
+            - const: isi
+            - const: csi
+            - const: dsi
 required:
   - compatible
   - reg
-- 
2.37.1



  parent reply	other threads:[~2025-07-28  7:38 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-28  7:14 [PATCH v7 00/11] Add i.MX91 platform support Joy Zou
2025-07-28  7:14 ` [PATCH v7 01/11] dt-bindings: arm: fsl: add i.MX91 11x11 evk board Joy Zou
2025-07-28  7:14 ` Joy Zou [this message]
2025-07-30 20:56   ` [PATCH v7 02/11] dt-bindings: soc: imx-blk-ctrl: add i.MX91 blk-ctrl compatible Rob Herring (Arm)
2025-07-28  7:14 ` [PATCH v7 03/11] arm64: dts: freescale: move aliases from imx93.dtsi to board dts Joy Zou
2025-07-28 14:27   ` Frank Li
2025-07-28  7:14 ` [PATCH v7 04/11] arm64: dts: freescale: rename imx93.dtsi to imx91_93_common.dtsi and modify them Joy Zou
2025-07-28 14:31   ` Frank Li
2025-07-28  7:14 ` [PATCH v7 05/11] arm64: dts: imx91: add i.MX91 dtsi support Joy Zou
2025-07-28 14:32   ` Frank Li
2025-07-28  7:14 ` [PATCH v7 06/11] arm64: dts: freescale: add i.MX91 11x11 EVK basic support Joy Zou
2025-07-28 14:34   ` Frank Li
2025-07-29  6:43   ` Alexander Stein
2025-07-28  7:14 ` [PATCH v7 07/11] arm64: dts: imx93-11x11-evk: remove fec property eee-broken-1000t Joy Zou
2025-07-28 14:35   ` Frank Li
2025-07-28  7:14 ` [PATCH v7 08/11] arm64: defconfig: enable i.MX91 pinctrl Joy Zou
2025-07-28 14:36   ` Frank Li
2025-07-28  7:14 ` [PATCH v7 09/11] pmdomain: imx93-blk-ctrl: use ARRAY_SIZE() instead of hardcode number Joy Zou
2025-07-28 14:36   ` Frank Li
2025-07-28  7:14 ` [PATCH v7 10/11] pmdomain: imx93-blk-ctrl: mask DSI and PXP PD domain register on i.MX91 Joy Zou
2025-07-28 14:41   ` Frank Li
2025-07-28  7:14 ` [PATCH v7 11/11] net: stmmac: imx: add i.MX91 support Joy Zou
2025-07-28 14:42   ` Frank Li

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250728071438.2332382-3-joy.zou@nxp.com \
    --to=joy.zou@nxp.com \
    --cc=Frank.Li@nxp.com \
    --cc=Markus.Niebel@ew.tq-group.com \
    --cc=alexander.stein@ew.tq-group.com \
    --cc=alexandre.torgue@foss.st.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=catalin.marinas@arm.com \
    --cc=conor+dt@kernel.org \
    --cc=davem@davemloft.net \
    --cc=devicetree@vger.kernel.org \
    --cc=edumazet@google.com \
    --cc=festevam@gmail.com \
    --cc=frieder.schrempf@kontron.de \
    --cc=imx@lists.linux.dev \
    --cc=kernel@pengutronix.de \
    --cc=krzk+dt@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=linux-stm32@st-md-mailman.stormreply.com \
    --cc=linux@ew.tq-group.com \
    --cc=mcoquelin.stm32@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=othacehe@gnu.org \
    --cc=pabeni@redhat.com \
    --cc=peng.fan@nxp.com \
    --cc=primoz.fiser@norik.com \
    --cc=richardcochran@gmail.com \
    --cc=robh@kernel.org \
    --cc=s.hauer@pengutronix.de \
    --cc=shawnguo@kernel.org \
    --cc=ulf.hansson@linaro.org \
    --cc=will@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).