lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20230905233118.183140-4-paul.elder@ideasonboard.com>
Date:   Wed,  6 Sep 2023 08:31:18 +0900
From:   Paul Elder <paul.elder@...asonboard.com>
To:     linux-media@...r.kernel.org
Cc:     Paul Elder <paul.elder@...asonboard.com>,
        Mauro Carvalho Chehab <mchehab@...nel.org>,
        Rob Herring <robh+dt@...nel.org>,
        Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
        Conor Dooley <conor+dt@...nel.org>,
        Laurent Pinchart <laurent.pinchart@...asonboard.com>,
        Hans Verkuil <hverkuil-cisco@...all.nl>,
        devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-arm-kernel@...ts.infradead.org,
        linux-mediatek@...ts.infradead.org
Subject: [PATCH 3/3] arm64: dts: mediatek: mt8365-pumpkin: Add overlays for thp7312 cameras

Add overlays for the Pumpkin i350 to support THP7312 cameras.

Signed-off-by: Paul Elder <paul.elder@...asonboard.com>
---
 arch/arm64/boot/dts/mediatek/Makefile         |  4 +
 .../mt8365-pumpkin-common-thp7312.dtsi        | 23 ++++++
 .../mt8365-pumpkin-csi0-thp7312-imx258.dtso   | 73 +++++++++++++++++++
 .../mt8365-pumpkin-csi1-thp7312-imx258.dtso   | 73 +++++++++++++++++++
 4 files changed, 173 insertions(+)
 create mode 100644 arch/arm64/boot/dts/mediatek/mt8365-pumpkin-common-thp7312.dtsi
 create mode 100644 arch/arm64/boot/dts/mediatek/mt8365-pumpkin-csi0-thp7312-imx258.dtso
 create mode 100644 arch/arm64/boot/dts/mediatek/mt8365-pumpkin-csi1-thp7312-imx258.dtso

diff --git a/arch/arm64/boot/dts/mediatek/Makefile b/arch/arm64/boot/dts/mediatek/Makefile
index 20570bc40de8..ceaf24105001 100644
--- a/arch/arm64/boot/dts/mediatek/Makefile
+++ b/arch/arm64/boot/dts/mediatek/Makefile
@@ -56,4 +56,8 @@ dtb-$(CONFIG_ARCH_MEDIATEK) += mt8365-evk.dtb
 dtb-$(CONFIG_ARCH_MEDIATEK) += mt8365-pumpkin.dtb
 dtb-$(CONFIG_ARCH_MEDIATEK) += mt8516-pumpkin.dtb
 
+mtk-mt8365-pumpkin-dtbs := mt8365-pumpkin.dtb mt8365-pumpkin-csi0-thp7312-imx258.dtbo
+mtk-mt8365-pumpkin-dtbs := mt8365-pumpkin.dtb mt8365-pumpkin-csi1-thp7312-imx258.dtbo
 mtk-mt8365-pumpkin-dtbs := mt8365-pumpkin.dtb mt8365-pumpkin-ethernet-usb.dtbo
+
+dtb-$(CONFIG_ARCH_MEDIATEK) += mtk-mt8365-pumpkin.dtb
diff --git a/arch/arm64/boot/dts/mediatek/mt8365-pumpkin-common-thp7312.dtsi b/arch/arm64/boot/dts/mediatek/mt8365-pumpkin-common-thp7312.dtsi
new file mode 100644
index 000000000000..478697552617
--- /dev/null
+++ b/arch/arm64/boot/dts/mediatek/mt8365-pumpkin-common-thp7312.dtsi
@@ -0,0 +1,23 @@
+// SPDX-License-Identifier: GPL-2.0
+/*
+ * Copyright (c) 2023 Ideas on Board
+ * Author: Paul Elder <paul.elder@...asonboard.com>
+ */
+
+/dts-v1/;
+/plugin/;
+
+&{/} {
+	vsys_v4p2: regulator@0 {
+		compatible = "regulator-fixed";
+		regulator-name = "vsys-v4p2";
+		regulator-min-microvolt = <4200000>;
+		regulator-max-microvolt = <4200000>;
+	};
+
+	camera61_clk: cam_clk24m {
+		compatible = "fixed-clock";
+		clock-frequency = <24000000>;
+		#clock-cells = <0>;
+	};
+};
diff --git a/arch/arm64/boot/dts/mediatek/mt8365-pumpkin-csi0-thp7312-imx258.dtso b/arch/arm64/boot/dts/mediatek/mt8365-pumpkin-csi0-thp7312-imx258.dtso
new file mode 100644
index 000000000000..740d14a19d75
--- /dev/null
+++ b/arch/arm64/boot/dts/mediatek/mt8365-pumpkin-csi0-thp7312-imx258.dtso
@@ -0,0 +1,73 @@
+// SPDX-License-Identifier: GPL-2.0
+/*
+ * Copyright (c) 2023 Ideas on Board
+ * Author: Paul Elder <paul.elder@...asonboard.com>
+ */
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/pinctrl/mt8365-pinfunc.h>
+#include "mt8365-pumpkin-common-thp7312.dtsi"
+
+&i2c3 {
+	camera@61 {
+		compatible = "thine,thp7312";
+		reg = <0x61>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&cam0_pins_default>;
+		reset-gpios = <&pio 118 GPIO_ACTIVE_LOW>;
+		clocks = <&camera61_clk>;
+
+		vddcore-supply = <&vsys_v4p2>;
+		vhtermrx-supply = <&vsys_v4p2>;
+		vddtx-supply = <&vsys_v4p2>;
+		vddhost-supply = <&vsys_v4p2>;
+		vddcmos-supply = <&vsys_v4p2>;
+		vddgpio_0-supply = <&vsys_v4p2>;
+		vddgpio_1-supply = <&vsys_v4p2>;
+		DOVDD-supply = <&vsys_v4p2>;
+		AVDD-supply = <&vsys_v4p2>;
+		DVDD-supply = <&vsys_v4p2>;
+
+		orientation = <0>;
+		rotation = <0>;
+
+		thine,rx,data-lanes = <4 1 3 2>;
+
+		port {
+			isp1_out: endpoint {
+				remote-endpoint = <&seninf_in1>;
+				data-lanes = <4 2 1 3>;
+			};
+		};
+	};
+};
+
+&pio {
+	cam0_pins_default: cam0_pins_default {
+		pins_rst {
+			pinmux = <MT8365_PIN_118_DMIC0_DAT0__FUNC_GPIO118>;
+		};
+	};
+};
+
+&seninf {
+	status = "okay";
+
+	ports {
+		port@0 {
+			seninf_in1: endpoint {
+				remote-endpoint = <&isp1_out>;
+				clock-lanes = <2>;
+				data-lanes = <1 3 0 4>;
+			};
+		};
+	};
+};
+
+&camsv1 {
+	status = "okay";
+};
+
+&mipi_csi0 {
+	status = "okay";
+};
diff --git a/arch/arm64/boot/dts/mediatek/mt8365-pumpkin-csi1-thp7312-imx258.dtso b/arch/arm64/boot/dts/mediatek/mt8365-pumpkin-csi1-thp7312-imx258.dtso
new file mode 100644
index 000000000000..2ebe4e9b56fa
--- /dev/null
+++ b/arch/arm64/boot/dts/mediatek/mt8365-pumpkin-csi1-thp7312-imx258.dtso
@@ -0,0 +1,73 @@
+// SPDX-License-Identifier: GPL-2.0
+/*
+ * Copyright (c) 2023 Ideas on Board
+ * Author: Paul Elder <paul.elder@...asonboard.com>
+ */
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/pinctrl/mt8365-pinfunc.h>
+#include "mt8365-pumpkin-common-thp7312.dtsi"
+
+&i2c2 {
+	camera@61 {
+		compatible = "thine,thp7312";
+		reg = <0x61>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&cam1_pins_default>;
+		reset-gpios = <&pio 119 GPIO_ACTIVE_LOW>;
+		clocks = <&camera61_clk>;
+
+		vddcore-supply = <&vsys_v4p2>;
+		vhtermrx-supply = <&vsys_v4p2>;
+		vddtx-supply = <&vsys_v4p2>;
+		vddhost-supply = <&vsys_v4p2>;
+		vddcmos-supply = <&vsys_v4p2>;
+		vddgpio_0-supply = <&vsys_v4p2>;
+		vddgpio_1-supply = <&vsys_v4p2>;
+		DOVDD-supply = <&vsys_v4p2>;
+		AVDD-supply = <&vsys_v4p2>;
+		DVDD-supply = <&vsys_v4p2>;
+
+		orientation = <0>;
+		rotation = <0>;
+
+		thine,rx,data-lanes = <4 1 3 2>;
+
+		port {
+			isp2_out: endpoint {
+				remote-endpoint = <&seninf_in2>;
+				data-lanes = <4 2 1 3>;
+			};
+		};
+	};
+};
+
+&pio {
+	cam1_pins_default: cam1_pins_default {
+		pins_rst {
+			pinmux = <MT8365_PIN_119_DMIC0_DAT1__FUNC_GPIO119>;
+		};
+	};
+};
+
+&seninf {
+	status = "okay";
+
+	ports {
+		port@1 {
+			seninf_in2: endpoint {
+				remote-endpoint = <&isp2_out>;
+				clock-lanes = <2>;
+				data-lanes = <1 3 0 4>;
+			};
+		};
+	};
+};
+
+&camsv2 {
+	status = "okay";
+};
+
+&mipi_csi1 {
+	status = "okay";
+};
-- 
2.39.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ