From: Niklas Söderlund Date: Fri, 5 Sep 2025 08:40:47 +0000 (+0200) Subject: arm64: dts: renesas: sparrow-hawk: Add overlay for IMX219 on J1 X-Git-Tag: v6.18-rc1~147^2~30^2~4 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=3ba261af4214996915970448fc308cde93cc3345;p=thirdparty%2Fkernel%2Flinux.git arm64: dts: renesas: sparrow-hawk: Add overlay for IMX219 on J1 Add an overlay to connect an IMX219 camera sensor to the J1 connector. The IMX219 utilizes 2 CSI-2 D-PHY lanes. This enables the video capture pipeline behind the CSI40 Rx to be enabled to process images from the sensor. Signed-off-by: Niklas Söderlund Reviewed-by: Laurent Pinchart Reviewed-by: Geert Uytterhoeven Link: https://patch.msgid.link/20250905084050.310651-2-niklas.soderlund+renesas@ragnatech.se Signed-off-by: Geert Uytterhoeven --- diff --git a/arch/arm64/boot/dts/renesas/Makefile b/arch/arm64/boot/dts/renesas/Makefile index d8c9237624664..82656bce02e9d 100644 --- a/arch/arm64/boot/dts/renesas/Makefile +++ b/arch/arm64/boot/dts/renesas/Makefile @@ -96,6 +96,9 @@ dtb-$(CONFIG_ARCH_R8A779G0) += r8a779g2-white-hawk-single-ard-audio-da7212.dtb DTC_FLAGS_r8a779g3-sparrow-hawk += -Wno-spi_bus_bridge dtb-$(CONFIG_ARCH_R8A779G0) += r8a779g3-sparrow-hawk.dtb +dtb-$(CONFIG_ARCH_R8A779G0) += r8a779g3-sparrow-hawk-camera-j1-imx219.dtbo +r8a779g3-sparrow-hawk-camera-j1-imx219-dtbs := r8a779g3-sparrow-hawk.dtb r8a779g3-sparrow-hawk-camera-j1-imx219.dtbo +dtb-$(CONFIG_ARCH_R8A779G0) += r8a779g3-sparrow-hawk-camera-j1-imx219.dtb dtb-$(CONFIG_ARCH_R8A779G0) += r8a779g3-sparrow-hawk-fan-pwm.dtbo r8a779g3-sparrow-hawk-fan-pwm-dtbs := r8a779g3-sparrow-hawk.dtb r8a779g3-sparrow-hawk-fan-pwm.dtbo dtb-$(CONFIG_ARCH_R8A779G0) += r8a779g3-sparrow-hawk-fan-pwm.dtb diff --git a/arch/arm64/boot/dts/renesas/r8a779g3-sparrow-hawk-camera-j1-imx219.dtso b/arch/arm64/boot/dts/renesas/r8a779g3-sparrow-hawk-camera-j1-imx219.dtso new file mode 100644 index 0000000000000..3acaf714cf248 --- /dev/null +++ b/arch/arm64/boot/dts/renesas/r8a779g3-sparrow-hawk-camera-j1-imx219.dtso @@ -0,0 +1,116 @@ +// SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +/* + * Device Tree Overlay for an IMX219 camera sensor on connector J1 on R-Car V4H + * ES3.0 Sparrow Hawk board. + * + * Copyright 2025 Renesas Electronics Corp. + * Copyright 2025 Niklas Söderlund + */ + +/dts-v1/; +/plugin/; + +#include +#include + +&{/} { + clk_cam_j1: clk-cam-j1 { + compatible = "fixed-clock"; + #clock-cells = <0>; + clock-frequency = <24000000>; + }; + + /* Page 29 / CSI_IF_CN / J1 */ + reg_cam_j1: reg-cam-j1 { + compatible = "regulator-fixed"; + regulator-name = "cam-J1"; + enable-active-high; + gpios = <&gpio0 1 GPIO_ACTIVE_HIGH>; + }; +}; + +&i2c1 { + #address-cells = <1>; + #size-cells = <0>; + status = "okay"; + + cam@10 { + compatible = "sony,imx219"; + reg = <0x10>; + + clocks = <&clk_cam_j1>; + + VANA-supply = <®_cam_j1>; + VDIG-supply = <®_cam_j1>; + VDDL-supply = <®_cam_j1>; + + orientation = <2>; + rotation = <0>; + + port { + imx219_j1_out: endpoint { + clock-noncontinuous; + link-frequencies = /bits/ 64 <456000000>; + data-lanes = <1 2>; + remote-endpoint = <&csi40_in>; + }; + }; + }; +}; + +/* Page 29 / CSI_IF_CN */ +&csi40 { + status = "okay"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + csi40_in: endpoint { + bus-type = ; + clock-lanes = <0>; + data-lanes = <1 2>; + remote-endpoint = <&imx219_j1_out>; + }; + }; + }; +}; + +&isp0 { + status = "okay"; +}; + +&vin00 { + status = "okay"; +}; + +&vin01 { + status = "okay"; +}; + +&vin02 { + status = "okay"; +}; + +&vin03 { + status = "okay"; +}; + +&vin04 { + status = "okay"; +}; + +&vin05 { + status = "okay"; +}; + +&vin06 { + status = "okay"; +}; + +&vin07 { + status = "okay"; +};