From 64385aa1d6985f786465acd7757c14cbbdbbe43f Mon Sep 17 00:00:00 2001 From: Dave Stevenson Date: Mon, 14 Oct 2024 15:37:57 +0100 Subject: [PATCH] dtoverlays: Fix up imx500 overlays to have unique clock nodes The overlay was creating DT nodes /clocks/clk-aicam and /clocks/clk-aicam-gated for both cam0 and cam1, which resulted in one failing. The clock infrastructure creates the clock name from the node name without any @N reg extension, so we can't just use that. The nodes therefore have to be renamed. Signed-off-by: Dave Stevenson --- arch/arm/boot/dts/overlays/imx500-overlay.dts | 10 ++++++---- arch/arm/boot/dts/overlays/imx500-pi5-overlay.dts | 10 ++++++---- 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/arch/arm/boot/dts/overlays/imx500-overlay.dts b/arch/arm/boot/dts/overlays/imx500-overlay.dts index 80918f13756cbe..b8d76feb259aab 100644 --- a/arch/arm/boot/dts/overlays/imx500-overlay.dts +++ b/arch/arm/boot/dts/overlays/imx500-overlay.dts @@ -72,16 +72,16 @@ }; }; - clocks_frag: fragment@104 { + fragment@104 { target-path = "/clocks"; __overlay__ { - clk_aicam: clk-aicam { + clk_aicam: clk-aicam1 { compatible = "fixed-clock"; #clock-cells = <0>; clock-frequency = <24000000>; }; - clk_aicam_gated: clk-aicam-gated { + clk_aicam_gated: clk-aicam-gated1 { compatible = "gpio-gate-clock"; clocks = <&clk_aicam>; #clock-cells = <0>; @@ -98,7 +98,9 @@ <&csi_frag>, "target:0=",<&csi0>, <&spi_bridge>, "power-supply:0=",<&cam0_reg>, <®_frag>, "target:0=",<&cam0_reg>, - <&cam_node>, "VANA-supply:0=",<&cam0_reg>; + <&cam_node>, "VANA-supply:0=",<&cam0_reg>, + <&clk_aicam>,"name=clk-aicam0", + <&clk_aicam_gated>,"name=clk-aicam-gated0"; bypass-cache = <&spi_bridge>,"bypass-cache?"; }; }; diff --git a/arch/arm/boot/dts/overlays/imx500-pi5-overlay.dts b/arch/arm/boot/dts/overlays/imx500-pi5-overlay.dts index 13175f1f302959..8ad4f0cd1c7b50 100644 --- a/arch/arm/boot/dts/overlays/imx500-pi5-overlay.dts +++ b/arch/arm/boot/dts/overlays/imx500-pi5-overlay.dts @@ -75,16 +75,16 @@ }; }; - clocks_frag: fragment@104 { + fragment@104 { target-path = "/clocks"; __overlay__ { - clk_aicam: clk-aicam { + clk_aicam: clk-aicam1 { compatible = "fixed-clock"; #clock-cells = <0>; clock-frequency = <24000000>; }; - clk_aicam_gated: clk-aicam-gated { + clk_aicam_gated: clk-aicam-gated1 { compatible = "gpio-gate-clock"; clocks = <&clk_aicam>; #clock-cells = <0>; @@ -103,7 +103,9 @@ <&spi_frag_overlay>, "fast_xfer-gpios:16=35", // CD0_IO1_MICDAT0 (clock) <&spi_bridge>, "power-supply:0=",<&cam0_reg>, <®_frag>, "target:0=",<&cam0_reg>, - <&cam_node>, "VANA-supply:0=",<&cam0_reg>; + <&cam_node>, "VANA-supply:0=",<&cam0_reg>, + <&clk_aicam>,"name=clk-aicam0", + <&clk_aicam_gated>,"name=clk-aicam-gated0"; bypass-cache = <&spi_bridge>,"bypass-cache?"; }; };