linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/7] apq8016: camss: Update dts with various fixes
@ 2023-08-11 23:47 Bryan O'Donoghue
  2023-08-11 23:47 ` [PATCH v3 1/7] arm64: dts: qcom: msm8916: Define CAMSS ports in core dtsi Bryan O'Donoghue
                   ` (7 more replies)
  0 siblings, 8 replies; 10+ messages in thread
From: Bryan O'Donoghue @ 2023-08-11 23:47 UTC (permalink / raw)
  To: agross, andersson, konrad.dybcio, robh+dt,
	krzysztof.kozlowski+dt, conor+dt
  Cc: linux-arm-msm, devicetree, linux-kernel, bryan.odonoghue

V3:
- Fixes licensing boilerplate error in d3 mezzanine - Stephan
- Moves regulators into d3 mezzanine - Stephan
- Drops redundant enable of camss in d3 mezzanine - Stephan
- Declares ports in core dtsi - Konrad
- Adds R/B for assigned-clocks - Konrad

Link: https://git.codelinaro.org/bryan.odonoghue/kernel/-/tree/linux-next-23-08-07-db410c-rb3-camss-dts-v3

V2:
- Adds R/B - Konrad
- Adds newline as flagged - Konrad
- Squashes patch#6 into patch#5 ammends commit log
- Following up on TPG comentary:
  The CAMSS would not have populated device nodes prior to this series
  save for the case a user had a D3 Engineering board.
  Splitting out the sensor from the core board is correct w/r/t the
  hardware/dts since few db410c have the mezzanine.
  Once split we can enable the basic camss node by default and thus get the
  TPG going for both the mezzanine and non-mezzanine cases.

Link: https://git.codelinaro.org/bryan.odonoghue/kernel/-/tree/linux-next-23-08-07-db410c-rb3-camss-dts-v2

V1:
This is a series which updates the apq8016-sbc to fixup CAMSS support.

The first four patches fixup the current state of the ov5640 bindings for
the apq8016.

Following on from that we move the ov5640 sensor from the main apq8016-sbc
into a standalone mezzanine dts with an accompanying patch to enable the
sensor by default in the mezzaine. This makes sense since the D3
Engineering camera mezzanine is but one of a slew of camera mezzanines we
can attach here.

The final patch switches on CAMSS in the core apq8016-sbc allowing us to use
the test-pattern-generator TPG on apq8016-sbc with or without a camera mezzaine
attached. This to me is a good idea since it means we can test out and
verify the CAMSS on this board absent a camera mezzaine on the main apq8016
board.

Link: https://git.codelinaro.org/bryan.odonoghue/kernel/-/tree/linux-next-23-08-07-db410c-rb3-camss-dts

Bryan O'Donoghue (7):
  arm64: dts: qcom: msm8916: Define CAMSS ports in core dtsi
  arm64: dts: qcom: apq8016-sbc: Fix ov5640 regulator supply names
  arm64: dts: qcom: apq8016-sbc: Fix ov5640 data-lanes declaration
  arm64: dts: qcom: apq8016-sbc: Set ov5640 assigned-clock
  arm64: dts: qcom: apq8016-sbc: Rename ov5640 enable-gpios to
    powerdown-gpios
  arm64: dts: qcom: apq8016-sbc-d3-camera-mezzanine: Move default ov5640
    to a standalone dts
  arm64: dts: qcom: apq8016-sbc: Enable camss for non-mezzanine cases

 arch/arm64/boot/dts/qcom/Makefile             |  1 +
 .../qcom/apq8016-sbc-d3-camera-mezzanine.dts  | 81 +++++++++++++++++++
 arch/arm64/boot/dts/qcom/apq8016-sbc.dts      | 68 ----------------
 arch/arm64/boot/dts/qcom/msm8916.dtsi         |  8 ++
 4 files changed, 90 insertions(+), 68 deletions(-)
 create mode 100644 arch/arm64/boot/dts/qcom/apq8016-sbc-d3-camera-mezzanine.dts

-- 
2.41.0


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [PATCH v3 1/7] arm64: dts: qcom: msm8916: Define CAMSS ports in core dtsi
  2023-08-11 23:47 [PATCH v3 0/7] apq8016: camss: Update dts with various fixes Bryan O'Donoghue
@ 2023-08-11 23:47 ` Bryan O'Donoghue
  2023-08-12 11:13   ` Konrad Dybcio
  2023-08-11 23:47 ` [PATCH v3 2/7] arm64: dts: qcom: apq8016-sbc: Fix ov5640 regulator supply names Bryan O'Donoghue
                   ` (6 subsequent siblings)
  7 siblings, 1 reply; 10+ messages in thread
From: Bryan O'Donoghue @ 2023-08-11 23:47 UTC (permalink / raw)
  To: agross, andersson, konrad.dybcio, robh+dt,
	krzysztof.kozlowski+dt, conor+dt
  Cc: linux-arm-msm, devicetree, linux-kernel, bryan.odonoghue

Each CSIPHY in CAMMS maps to a port here in the dtsi, since the number of
CSIPHYs is fixed per SoC define the 8916 ports for both available PHYs.

Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
---
 arch/arm64/boot/dts/qcom/msm8916.dtsi | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/msm8916.dtsi b/arch/arm64/boot/dts/qcom/msm8916.dtsi
index c4d6739046989..33fb65d731046 100644
--- a/arch/arm64/boot/dts/qcom/msm8916.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8916.dtsi
@@ -1712,6 +1712,14 @@ camss: camss@1b0ac00 {
 			ports {
 				#address-cells = <1>;
 				#size-cells = <0>;
+
+				port@0 {
+					reg = <0>;
+				};
+
+				port@1 {
+					reg = <1>;
+				};
 			};
 		};
 
-- 
2.41.0


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH v3 2/7] arm64: dts: qcom: apq8016-sbc: Fix ov5640 regulator supply names
  2023-08-11 23:47 [PATCH v3 0/7] apq8016: camss: Update dts with various fixes Bryan O'Donoghue
  2023-08-11 23:47 ` [PATCH v3 1/7] arm64: dts: qcom: msm8916: Define CAMSS ports in core dtsi Bryan O'Donoghue
@ 2023-08-11 23:47 ` Bryan O'Donoghue
  2023-08-11 23:47 ` [PATCH v3 3/7] arm64: dts: qcom: apq8016-sbc: Fix ov5640 data-lanes declaration Bryan O'Donoghue
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 10+ messages in thread
From: Bryan O'Donoghue @ 2023-08-11 23:47 UTC (permalink / raw)
  To: agross, andersson, konrad.dybcio, robh+dt,
	krzysztof.kozlowski+dt, conor+dt
  Cc: linux-arm-msm, devicetree, linux-kernel, bryan.odonoghue

The ov5640 driver expects DOVDD, AVDD and DVDD as regulator supply names.

The ov5640 has depended on these names since the driver was committed
upstream in 2017. Similarly apq8016-sbc.dtsi has had completely different
regulator names since its own initial commit in 2020.

Perhaps the regulators were left on in previous 410c bootloaders. In any
case today on 6.5 we won't switch on the ov5640 without correctly naming
the regulators.

Fixes: 39e0ce6cd1bf ("arm64: dts: qcom: apq8016-sbc: Add CCI/Sensor nodes")
Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
---
 arch/arm64/boot/dts/qcom/apq8016-sbc.dts | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/arch/arm64/boot/dts/qcom/apq8016-sbc.dts b/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
index f6eeb25988465..75b4e5ff7c95c 100644
--- a/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
+++ b/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
@@ -282,9 +282,9 @@ camera_rear@3b {
 		clock-names = "xclk";
 		clock-frequency = <23880000>;
 
-		vdddo-supply = <&camera_vdddo_1v8>;
-		vdda-supply = <&camera_vdda_2v8>;
-		vddd-supply = <&camera_vddd_1v5>;
+		DOVDD-supply = <&camera_vdddo_1v8>;
+		AVDD-supply = <&camera_vdda_2v8>;
+		DVDD-supply = <&camera_vddd_1v5>;
 
 		/* No camera mezzanine by default */
 		status = "disabled";
-- 
2.41.0


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH v3 3/7] arm64: dts: qcom: apq8016-sbc: Fix ov5640 data-lanes declaration
  2023-08-11 23:47 [PATCH v3 0/7] apq8016: camss: Update dts with various fixes Bryan O'Donoghue
  2023-08-11 23:47 ` [PATCH v3 1/7] arm64: dts: qcom: msm8916: Define CAMSS ports in core dtsi Bryan O'Donoghue
  2023-08-11 23:47 ` [PATCH v3 2/7] arm64: dts: qcom: apq8016-sbc: Fix ov5640 regulator supply names Bryan O'Donoghue
@ 2023-08-11 23:47 ` Bryan O'Donoghue
  2023-08-11 23:47 ` [PATCH v3 4/7] arm64: dts: qcom: apq8016-sbc: Set ov5640 assigned-clock Bryan O'Donoghue
                   ` (4 subsequent siblings)
  7 siblings, 0 replies; 10+ messages in thread
From: Bryan O'Donoghue @ 2023-08-11 23:47 UTC (permalink / raw)
  To: agross, andersson, konrad.dybcio, robh+dt,
	krzysztof.kozlowski+dt, conor+dt
  Cc: linux-arm-msm, devicetree, linux-kernel, bryan.odonoghue

The yaml constraint for data-lanes is [1, 2] not [0, 2]. The driver itself
doesn't do anything with the data-lanes declaration save count the number
of specified data-lanes and calculate the link rate so, this change doesn't
have any functional side-effects.

Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
---
 arch/arm64/boot/dts/qcom/apq8016-sbc.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/qcom/apq8016-sbc.dts b/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
index 75b4e5ff7c95c..0481a4a82090a 100644
--- a/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
+++ b/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
@@ -291,7 +291,7 @@ camera_rear@3b {
 
 		port {
 			ov5640_ep: endpoint {
-				data-lanes = <0 2>;
+				data-lanes = <1 2>;
 				remote-endpoint = <&csiphy0_ep>;
 			};
 		};
-- 
2.41.0


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH v3 4/7] arm64: dts: qcom: apq8016-sbc: Set ov5640 assigned-clock
  2023-08-11 23:47 [PATCH v3 0/7] apq8016: camss: Update dts with various fixes Bryan O'Donoghue
                   ` (2 preceding siblings ...)
  2023-08-11 23:47 ` [PATCH v3 3/7] arm64: dts: qcom: apq8016-sbc: Fix ov5640 data-lanes declaration Bryan O'Donoghue
@ 2023-08-11 23:47 ` Bryan O'Donoghue
  2023-08-11 23:47 ` [PATCH v3 5/7] arm64: dts: qcom: apq8016-sbc: Rename ov5640 enable-gpios to powerdown-gpios Bryan O'Donoghue
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 10+ messages in thread
From: Bryan O'Donoghue @ 2023-08-11 23:47 UTC (permalink / raw)
  To: agross, andersson, konrad.dybcio, robh+dt,
	krzysztof.kozlowski+dt, conor+dt
  Cc: linux-arm-msm, devicetree, linux-kernel, bryan.odonoghue

The driver for the ov5640 doesn't do a set-rate, instead it expects the
clock to already be set at an appropriate rate.

Similarly the yaml for ov5640 doesn't understand clock-frequency. Convert
from clock-rate to assigned-clock and assigned-clock-rate to remediate.

Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
---
 arch/arm64/boot/dts/qcom/apq8016-sbc.dts | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/qcom/apq8016-sbc.dts b/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
index 0481a4a82090a..ada0777567623 100644
--- a/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
+++ b/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
@@ -280,7 +280,8 @@ camera_rear@3b {
 
 		clocks = <&gcc GCC_CAMSS_MCLK0_CLK>;
 		clock-names = "xclk";
-		clock-frequency = <23880000>;
+		assigned-clocks = <&gcc GCC_CAMSS_MCLK0_CLK>;
+		assigned-clock-rates = <23880000>;
 
 		DOVDD-supply = <&camera_vdddo_1v8>;
 		AVDD-supply = <&camera_vdda_2v8>;
-- 
2.41.0


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH v3 5/7] arm64: dts: qcom: apq8016-sbc: Rename ov5640 enable-gpios to powerdown-gpios
  2023-08-11 23:47 [PATCH v3 0/7] apq8016: camss: Update dts with various fixes Bryan O'Donoghue
                   ` (3 preceding siblings ...)
  2023-08-11 23:47 ` [PATCH v3 4/7] arm64: dts: qcom: apq8016-sbc: Set ov5640 assigned-clock Bryan O'Donoghue
@ 2023-08-11 23:47 ` Bryan O'Donoghue
  2023-08-11 23:47 ` [PATCH v3 6/7] arm64: dts: qcom: apq8016-sbc-d3-camera-mezzanine: Move default ov5640 to a standalone dts Bryan O'Donoghue
                   ` (2 subsequent siblings)
  7 siblings, 0 replies; 10+ messages in thread
From: Bryan O'Donoghue @ 2023-08-11 23:47 UTC (permalink / raw)
  To: agross, andersson, konrad.dybcio, robh+dt,
	krzysztof.kozlowski+dt, conor+dt
  Cc: linux-arm-msm, devicetree, linux-kernel, bryan.odonoghue

There are two control lines controlled by GPIO going into ov5640

- Reset
- Powerdown

The driver and yaml expect "reset-gpios" and "powerdown-gpios" there has
never been an "enable-gpios".

Fixes: 39e0ce6cd1bf ("arm64: dts: qcom: apq8016-sbc: Add CCI/Sensor nodes")
Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
---
 arch/arm64/boot/dts/qcom/apq8016-sbc.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/qcom/apq8016-sbc.dts b/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
index ada0777567623..ddb19709a9eee 100644
--- a/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
+++ b/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
@@ -273,7 +273,7 @@ camera_rear@3b {
 		compatible = "ovti,ov5640";
 		reg = <0x3b>;
 
-		enable-gpios = <&tlmm 34 GPIO_ACTIVE_HIGH>;
+		powerdown-gpios = <&tlmm 34 GPIO_ACTIVE_HIGH>;
 		reset-gpios = <&tlmm 35 GPIO_ACTIVE_LOW>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&camera_rear_default>;
-- 
2.41.0


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH v3 6/7] arm64: dts: qcom: apq8016-sbc-d3-camera-mezzanine: Move default ov5640 to a standalone dts
  2023-08-11 23:47 [PATCH v3 0/7] apq8016: camss: Update dts with various fixes Bryan O'Donoghue
                   ` (4 preceding siblings ...)
  2023-08-11 23:47 ` [PATCH v3 5/7] arm64: dts: qcom: apq8016-sbc: Rename ov5640 enable-gpios to powerdown-gpios Bryan O'Donoghue
@ 2023-08-11 23:47 ` Bryan O'Donoghue
  2023-08-11 23:47 ` [PATCH v3 7/7] arm64: dts: qcom: apq8016-sbc: Enable camss for non-mezzanine cases Bryan O'Donoghue
  2023-08-14  3:27 ` [PATCH v3 0/7] apq8016: camss: Update dts with various fixes Bjorn Andersson
  7 siblings, 0 replies; 10+ messages in thread
From: Bryan O'Donoghue @ 2023-08-11 23:47 UTC (permalink / raw)
  To: agross, andersson, konrad.dybcio, robh+dt,
	krzysztof.kozlowski+dt, conor+dt
  Cc: linux-arm-msm, devicetree, linux-kernel, bryan.odonoghue

At the moment we define a single ov5640 sensor in the apq8016-sbc and
disable that sensor.

The sensor mezzanine for this is a D3 Engineering Dual ov5640 mezzanine
card. Move the definition from the apq8016-sbc where it shouldn't be to a
standalone dts.

Enables the sensor by default, as we are adding a standalone mezzanine
structure.

Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
---
 arch/arm64/boot/dts/qcom/Makefile             |  1 +
 .../qcom/apq8016-sbc-d3-camera-mezzanine.dts  | 81 +++++++++++++++++++
 arch/arm64/boot/dts/qcom/apq8016-sbc.dts      | 73 -----------------
 3 files changed, 82 insertions(+), 73 deletions(-)
 create mode 100644 arch/arm64/boot/dts/qcom/apq8016-sbc-d3-camera-mezzanine.dts

diff --git a/arch/arm64/boot/dts/qcom/Makefile b/arch/arm64/boot/dts/qcom/Makefile
index f15548dbfa56e..19016765ba4c6 100644
--- a/arch/arm64/boot/dts/qcom/Makefile
+++ b/arch/arm64/boot/dts/qcom/Makefile
@@ -1,5 +1,6 @@
 # SPDX-License-Identifier: GPL-2.0
 dtb-$(CONFIG_ARCH_QCOM)	+= apq8016-sbc.dtb
+dtb-$(CONFIG_ARCH_QCOM)	+= apq8016-sbc-d3-camera-mezzanine.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= apq8039-t2.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= apq8094-sony-xperia-kitakami-karin_windy.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= apq8096-db820c.dtb
diff --git a/arch/arm64/boot/dts/qcom/apq8016-sbc-d3-camera-mezzanine.dts b/arch/arm64/boot/dts/qcom/apq8016-sbc-d3-camera-mezzanine.dts
new file mode 100644
index 0000000000000..c08b4be5cc7ee
--- /dev/null
+++ b/arch/arm64/boot/dts/qcom/apq8016-sbc-d3-camera-mezzanine.dts
@@ -0,0 +1,81 @@
+// SPDX-License-Identifier: GPL-2.0-only
+/*
+ * Copyright (c) 2015, The Linux Foundation. All rights reserved.
+ * Copyright (c) 2023, Linaro Ltd.
+ */
+
+/dts-v1/;
+
+#include "apq8016-sbc.dts"
+
+/ {
+	camera_vdddo_1v8: camera-vdddo-1v8 {
+		compatible = "regulator-fixed";
+		regulator-name = "camera_vdddo";
+		regulator-min-microvolt = <1800000>;
+		regulator-max-microvolt = <1800000>;
+		regulator-always-on;
+	};
+
+	camera_vdda_2v8: camera-vdda-2v8 {
+		compatible = "regulator-fixed";
+		regulator-name = "camera_vdda";
+		regulator-min-microvolt = <2800000>;
+		regulator-max-microvolt = <2800000>;
+		regulator-always-on;
+	};
+
+	camera_vddd_1v5: camera-vddd-1v5 {
+		compatible = "regulator-fixed";
+		regulator-name = "camera_vddd";
+		regulator-min-microvolt = <1500000>;
+		regulator-max-microvolt = <1500000>;
+		regulator-always-on;
+	};
+};
+
+&camss {
+	status = "okay";
+
+	ports {
+		port@0 {
+			reg = <0>;
+			csiphy0_ep: endpoint {
+				data-lanes = <0 2>;
+				remote-endpoint = <&ov5640_ep>;
+			};
+		};
+	};
+};
+
+&cci {
+	status = "okay";
+};
+
+&cci_i2c0 {
+	camera_rear@3b {
+		compatible = "ovti,ov5640";
+		reg = <0x3b>;
+
+		powerdown-gpios = <&tlmm 34 GPIO_ACTIVE_HIGH>;
+		reset-gpios = <&tlmm 35 GPIO_ACTIVE_LOW>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&camera_rear_default>;
+
+		clocks = <&gcc GCC_CAMSS_MCLK0_CLK>;
+		clock-names = "xclk";
+		assigned-clocks = <&gcc GCC_CAMSS_MCLK0_CLK>;
+		assigned-clock-rates = <23880000>;
+
+		DOVDD-supply = <&camera_vdddo_1v8>;
+		AVDD-supply = <&camera_vdda_2v8>;
+		DVDD-supply = <&camera_vddd_1v5>;
+
+		port {
+			ov5640_ep: endpoint {
+				data-lanes = <1 2>;
+				remote-endpoint = <&csiphy0_ep>;
+			};
+		};
+	};
+};
diff --git a/arch/arm64/boot/dts/qcom/apq8016-sbc.dts b/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
index ddb19709a9eee..c3cd08aa5c85b 100644
--- a/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
+++ b/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
@@ -34,30 +34,6 @@ chosen {
 		stdout-path = "serial0";
 	};
 
-	camera_vdddo_1v8: camera-vdddo-1v8 {
-		compatible = "regulator-fixed";
-		regulator-name = "camera_vdddo";
-		regulator-min-microvolt = <1800000>;
-		regulator-max-microvolt = <1800000>;
-		regulator-always-on;
-	};
-
-	camera_vdda_2v8: camera-vdda-2v8 {
-		compatible = "regulator-fixed";
-		regulator-name = "camera_vdda";
-		regulator-min-microvolt = <2800000>;
-		regulator-max-microvolt = <2800000>;
-		regulator-always-on;
-	};
-
-	camera_vddd_1v5: camera-vddd-1v5 {
-		compatible = "regulator-fixed";
-		regulator-name = "camera_vddd";
-		regulator-min-microvolt = <1500000>;
-		regulator-max-microvolt = <1500000>;
-		regulator-always-on;
-	};
-
 	reserved-memory {
 		ramoops@bff00000 {
 			compatible = "ramoops";
@@ -250,55 +226,6 @@ &blsp_uart2 {
 	label = "LS-UART1";
 };
 
-&camss {
-	status = "okay";
-	ports {
-		port@0 {
-			reg = <0>;
-			csiphy0_ep: endpoint {
-				data-lanes = <0 2>;
-				remote-endpoint = <&ov5640_ep>;
-				status = "okay";
-			};
-		};
-	};
-};
-
-&cci {
-	status = "okay";
-};
-
-&cci_i2c0 {
-	camera_rear@3b {
-		compatible = "ovti,ov5640";
-		reg = <0x3b>;
-
-		powerdown-gpios = <&tlmm 34 GPIO_ACTIVE_HIGH>;
-		reset-gpios = <&tlmm 35 GPIO_ACTIVE_LOW>;
-		pinctrl-names = "default";
-		pinctrl-0 = <&camera_rear_default>;
-
-		clocks = <&gcc GCC_CAMSS_MCLK0_CLK>;
-		clock-names = "xclk";
-		assigned-clocks = <&gcc GCC_CAMSS_MCLK0_CLK>;
-		assigned-clock-rates = <23880000>;
-
-		DOVDD-supply = <&camera_vdddo_1v8>;
-		AVDD-supply = <&camera_vdda_2v8>;
-		DVDD-supply = <&camera_vddd_1v5>;
-
-		/* No camera mezzanine by default */
-		status = "disabled";
-
-		port {
-			ov5640_ep: endpoint {
-				data-lanes = <1 2>;
-				remote-endpoint = <&csiphy0_ep>;
-			};
-		};
-	};
-};
-
 &lpass {
 	status = "okay";
 };
-- 
2.41.0


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH v3 7/7] arm64: dts: qcom: apq8016-sbc: Enable camss for non-mezzanine cases
  2023-08-11 23:47 [PATCH v3 0/7] apq8016: camss: Update dts with various fixes Bryan O'Donoghue
                   ` (5 preceding siblings ...)
  2023-08-11 23:47 ` [PATCH v3 6/7] arm64: dts: qcom: apq8016-sbc-d3-camera-mezzanine: Move default ov5640 to a standalone dts Bryan O'Donoghue
@ 2023-08-11 23:47 ` Bryan O'Donoghue
  2023-08-14  3:27 ` [PATCH v3 0/7] apq8016: camss: Update dts with various fixes Bjorn Andersson
  7 siblings, 0 replies; 10+ messages in thread
From: Bryan O'Donoghue @ 2023-08-11 23:47 UTC (permalink / raw)
  To: agross, andersson, konrad.dybcio, robh+dt,
	krzysztof.kozlowski+dt, conor+dt
  Cc: linux-arm-msm, devicetree, linux-kernel, bryan.odonoghue

When we have no camera mezzanine attached it is still possible to run the
test-pattern generator of the CSID block.

As an example:

media-ctl --reset

yavta --no-query -w '0x009f0903 1' /dev/v4l-subdev2
yavta --list /dev/v4l-subdev2

media-ctl -d /dev/media0 -V '"msm_csid0":0[fmt:UYVY8_1X16/1920x1080 field:none]'
media-ctl -l '"msm_csid0":1->"msm_ispif0":0[1]'
media-ctl -d /dev/media0 -V '"msm_ispif0":0[fmt:UYVY8_1X16/1920x1080 field:none]'
media-ctl -l '"msm_ispif0":1->"msm_vfe0_rdi0":0[1]'
media-ctl -d /dev/media0 -V '"msm_vfe0_rdi0":0[fmt:UYVY8_1X16/1920x1080]'
media-ctl -d /dev/media0 -p

yavta -B capture-mplane --capture=5 -n 5 -I -f UYVY -s 1920x1080 --file=TPG-UYVU-1920x1080-000-#.bin /dev/video0

Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
---
 arch/arm64/boot/dts/qcom/apq8016-sbc.dts | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/apq8016-sbc.dts b/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
index c3cd08aa5c85b..4f5541e9be0e9 100644
--- a/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
+++ b/arch/arm64/boot/dts/qcom/apq8016-sbc.dts
@@ -226,6 +226,10 @@ &blsp_uart2 {
 	label = "LS-UART1";
 };
 
+&camss {
+	status = "okay";
+};
+
 &lpass {
 	status = "okay";
 };
-- 
2.41.0


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* Re: [PATCH v3 1/7] arm64: dts: qcom: msm8916: Define CAMSS ports in core dtsi
  2023-08-11 23:47 ` [PATCH v3 1/7] arm64: dts: qcom: msm8916: Define CAMSS ports in core dtsi Bryan O'Donoghue
@ 2023-08-12 11:13   ` Konrad Dybcio
  0 siblings, 0 replies; 10+ messages in thread
From: Konrad Dybcio @ 2023-08-12 11:13 UTC (permalink / raw)
  To: Bryan O'Donoghue, agross, andersson, robh+dt,
	krzysztof.kozlowski+dt, conor+dt
  Cc: linux-arm-msm, devicetree, linux-kernel

On 12.08.2023 01:47, Bryan O'Donoghue wrote:
> Each CSIPHY in CAMMS maps to a port here in the dtsi, since the number of
> CSIPHYs is fixed per SoC define the 8916 ports for both available PHYs.
> 
> Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
> ---
Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>

Konrad

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH v3 0/7] apq8016: camss: Update dts with various fixes
  2023-08-11 23:47 [PATCH v3 0/7] apq8016: camss: Update dts with various fixes Bryan O'Donoghue
                   ` (6 preceding siblings ...)
  2023-08-11 23:47 ` [PATCH v3 7/7] arm64: dts: qcom: apq8016-sbc: Enable camss for non-mezzanine cases Bryan O'Donoghue
@ 2023-08-14  3:27 ` Bjorn Andersson
  7 siblings, 0 replies; 10+ messages in thread
From: Bjorn Andersson @ 2023-08-14  3:27 UTC (permalink / raw)
  To: agross, konrad.dybcio, robh+dt, krzysztof.kozlowski+dt, conor+dt,
	Bryan O'Donoghue
  Cc: linux-arm-msm, devicetree, linux-kernel


On Sat, 12 Aug 2023 00:47:31 +0100, Bryan O'Donoghue wrote:
> V3:
> - Fixes licensing boilerplate error in d3 mezzanine - Stephan
> - Moves regulators into d3 mezzanine - Stephan
> - Drops redundant enable of camss in d3 mezzanine - Stephan
> - Declares ports in core dtsi - Konrad
> - Adds R/B for assigned-clocks - Konrad
> 
> [...]

Applied, thanks!

[1/7] arm64: dts: qcom: msm8916: Define CAMSS ports in core dtsi
      commit: 349a13a1e735ef84ff1af8e56a1309171f86f989
[2/7] arm64: dts: qcom: apq8016-sbc: Fix ov5640 regulator supply names
      commit: 43a684580819e7f35b6cb38236be63c4cba26ef4
[3/7] arm64: dts: qcom: apq8016-sbc: Fix ov5640 data-lanes declaration
      commit: 3652866ff493db60e2f767bd751fe15c1b4bd37a
[4/7] arm64: dts: qcom: apq8016-sbc: Set ov5640 assigned-clock
      commit: 775d2f3f76b1de6d440d6071c61023ea71d88f69
[5/7] arm64: dts: qcom: apq8016-sbc: Rename ov5640 enable-gpios to powerdown-gpios
      commit: 4facccb44a82129195878750eed8f9890091c1b8
[6/7] arm64: dts: qcom: apq8016-sbc-d3-camera-mezzanine: Move default ov5640 to a standalone dts
      commit: 6823df31587707f5534663f04f80e40df3e709c4
[7/7] arm64: dts: qcom: apq8016-sbc: Enable camss for non-mezzanine cases
      commit: c27c73bb560bae279deae8cd94554832cee88116

Best regards,
-- 
Bjorn Andersson <andersson@kernel.org>

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2023-08-14  3:25 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-08-11 23:47 [PATCH v3 0/7] apq8016: camss: Update dts with various fixes Bryan O'Donoghue
2023-08-11 23:47 ` [PATCH v3 1/7] arm64: dts: qcom: msm8916: Define CAMSS ports in core dtsi Bryan O'Donoghue
2023-08-12 11:13   ` Konrad Dybcio
2023-08-11 23:47 ` [PATCH v3 2/7] arm64: dts: qcom: apq8016-sbc: Fix ov5640 regulator supply names Bryan O'Donoghue
2023-08-11 23:47 ` [PATCH v3 3/7] arm64: dts: qcom: apq8016-sbc: Fix ov5640 data-lanes declaration Bryan O'Donoghue
2023-08-11 23:47 ` [PATCH v3 4/7] arm64: dts: qcom: apq8016-sbc: Set ov5640 assigned-clock Bryan O'Donoghue
2023-08-11 23:47 ` [PATCH v3 5/7] arm64: dts: qcom: apq8016-sbc: Rename ov5640 enable-gpios to powerdown-gpios Bryan O'Donoghue
2023-08-11 23:47 ` [PATCH v3 6/7] arm64: dts: qcom: apq8016-sbc-d3-camera-mezzanine: Move default ov5640 to a standalone dts Bryan O'Donoghue
2023-08-11 23:47 ` [PATCH v3 7/7] arm64: dts: qcom: apq8016-sbc: Enable camss for non-mezzanine cases Bryan O'Donoghue
2023-08-14  3:27 ` [PATCH v3 0/7] apq8016: camss: Update dts with various fixes Bjorn Andersson

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).