Skip to contentSkip to conversation

arm64: dts: qcom: apq8016-sbc-d3: Add Qualcomm APQ8016 SBC + D3Camera mezzanine

PATCH In review Robert Foss 4 participants 6 messages May 18, 2020 – May 25, 2020

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH v3 1/1 arm64: dts: qcom: apq8016-sbc-d3: Add Qualcomm APQ8016 SBC + D3Camera mezzanine

Add device treee support for the Qualcomm APQ8016 SBC, otherwise known as the Dragonboard 410c with the D3Camera mezzanine expansion board.

The D3Camera mezzanine ships in a kit with a OmniVision 5640 sensor module, which is what this DT targets.

---

Changes since v2:
- Vinod: Change copyright assignment to Linaro

Changes since v1:
- Vinod: Changed license to GPL+BSD
- Vinod: Changed copyright year to 2020
- Nico: Changed name of mezzanine to d3camera

 arch/arm64/boot/dts/qcom/Makefile             |  1 +
 .../boot/dts/qcom/apq8016-sbc-d3camera.dts    | 45 +++++++++++++++++++
 2 files changed, 46 insertions(+)
 create mode 100644 arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts
arch/arm64/boot/dts/qcom/Makefile +1 -0
index cc103f7020fd..3f95b522694e 100644
@@ -1,5 +1,6 @@
 # SPDX-License-Identifier: GPL-2.0
 dtb-$(CONFIG_ARCH_QCOM)	+= apq8016-sbc.dtb
+dtb-$(CONFIG_ARCH_QCOM)	+= apq8016-sbc-d3camera.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= apq8096-db820c.dtb
 dtb-$(CONFIG_ARCH_QCOM) += apq8096-ifc6640.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= ipq6018-cp01-c1.dtb
arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts new file +45 -0

45 lines not on this page · raw message

Signature · 1 line
2.25.1
Reviewed-by on v3 1/1
#1 lore raw
Quoted 5 lines · Robert Foss

Add device treee support for the Qualcomm APQ8016 SBC, otherwise known as the Dragonboard 410c with the D3Camera mezzanine expansion board.

The D3Camera mezzanine ships in a kit with a OmniVision 5640 sensor module, which is what this DT targets.

Signature · 1 line
~Vinod
#2 lore raw
In reply to Robert Foss
Quoted 39 lines · Robert Foss

Add device treee support for the Qualcomm APQ8016 SBC, otherwise known as the Dragonboard 410c with the D3Camera mezzanine expansion board.

The D3Camera mezzanine ships in a kit with a OmniVision 5640 sensor module, which is what this DT targets.

---

Changes since v2:
- Vinod: Change copyright assignment to Linaro

Changes since v1:
- Vinod: Changed license to GPL+BSD
- Vinod: Changed copyright year to 2020
- Nico: Changed name of mezzanine to d3camera

 arch/arm64/boot/dts/qcom/Makefile             |  1 +
 .../boot/dts/qcom/apq8016-sbc-d3camera.dts    | 45 +++++++++++++++++++
 2 files changed, 46 insertions(+)
 create mode 100644 arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts
arch/arm64/boot/dts/qcom/Makefile +1 -0
index cc103f7020fd..3f95b522694e 100644
@@ -1,5 +1,6 @@
 # SPDX-License-Identifier: GPL-2.0
 dtb-$(CONFIG_ARCH_QCOM)	+= apq8016-sbc.dtb
+dtb-$(CONFIG_ARCH_QCOM)	+= apq8016-sbc-d3camera.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= apq8096-db820c.dtb
 dtb-$(CONFIG_ARCH_QCOM) += apq8096-ifc6640.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= ipq6018-cp01-c1.dtb
arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts new file +0 -0
new file mode 100644
index 000000000000..752e5ec47499

arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts line 3

Quoted 3 lines
arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts new file +3 -0
@@ -0,0 +1,45 @@
+// SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause
+/*
+ * Copyright (c) 2020, The Linux Foundation. All rights reserved.

That's not how you spell "Linaro Ltd" :)

arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts line 12

Quoted 9 lines
arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts new file +9 -0
+ */
+
+/dts-v1/;
+
+#include "apq8016-sbc.dtsi"
+
+/ {
+	model = "Qualcomm Technologies, Inc. APQ 8016 SBC w/ D3Camera Mezzanine";
+	compatible = "qcom,apq8016-sbc", "qcom,apq8016", "qcom,sbc";

Please add qcom,apq8016-sbc-d3camera" (or qcom,db410c-d3camera :)) and drop the vague "qcom,sbc".

arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts line 16

Quoted 4 lines
arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts new file +4 -0
+};
+
+&cci_i2c0 {
+	/delete-node/ camera_rear@3b;

camera_rear@3b is disabled already, so you shouldn't need this.

Should we really carry the node in apq8016-sbc.dtsi? (Unrelated/separate change).

Regards,
Bjorn

Quoted 32 lines
arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts new file +29 -0
+
+	camera_rear@76 {
+		compatible = "ovti,ov5640";
+		reg = <0x76>;
+
+		enable-gpios = <&msmgpio 34 GPIO_ACTIVE_HIGH>;
+		reset-gpios = <&msmgpio 35 GPIO_ACTIVE_LOW>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&camera_rear_default>;
+
+		clocks = <&gcc GCC_CAMSS_MCLK0_CLK>;
+		clock-names = "xclk";
+		clock-frequency = <23880000>;
+
+		vdddo-supply = <&camera_vdddo_1v8>;
+		vdda-supply = <&camera_vdda_2v8>;
+		vddd-supply = <&camera_vddd_1v5>;
+
+		status = "ok";
+
+		port {
+			ov5640_ep: endpoint {
+				clock-lanes = <1>;
+				data-lanes = <0 2>;
+				remote-endpoint = <&csiphy0_ep>;
+			};
+		};
+	};
+};
Signature · 1 line
2.25.1
#3 lore raw
In reply to Robert Foss

Hi Robert,

Quoted 6 lines · Robert Foss

Add device treee support for the Qualcomm APQ8016 SBC, otherwise known as the Dragonboard 410c with the D3Camera mezzanine expansion board.

The D3Camera mezzanine ships in a kit with a OmniVision 5640 sensor module, which is what this DT targets.

What is the motivation behind adding this new dts? We have been using the userspace tool [1] for applying this as an overlay for some time. But if we start adding dts for mezzanines then for sure we'll end up with some good numbers which will flood arch/{..}/qcom directory.

I could understand that one of the motivation is to provide nice user experience to users but that's also taken care by the dt-update tool IMO.

Thanks,
Mani

[1] https://github.com/96boards/dt-update

Quoted 81 lines

---

Changes since v2:
- Vinod: Change copyright assignment to Linaro

Changes since v1:
- Vinod: Changed license to GPL+BSD
- Vinod: Changed copyright year to 2020
- Nico: Changed name of mezzanine to d3camera

 arch/arm64/boot/dts/qcom/Makefile             |  1 +
 .../boot/dts/qcom/apq8016-sbc-d3camera.dts    | 45 +++++++++++++++++++
 2 files changed, 46 insertions(+)
 create mode 100644 arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts
arch/arm64/boot/dts/qcom/Makefile +1 -0
index cc103f7020fd..3f95b522694e 100644
@@ -1,5 +1,6 @@
 # SPDX-License-Identifier: GPL-2.0
 dtb-$(CONFIG_ARCH_QCOM)	+= apq8016-sbc.dtb
+dtb-$(CONFIG_ARCH_QCOM)	+= apq8016-sbc-d3camera.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= apq8096-db820c.dtb
 dtb-$(CONFIG_ARCH_QCOM) += apq8096-ifc6640.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= ipq6018-cp01-c1.dtb
arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts new file +45 -0
new file mode 100644
index 000000000000..752e5ec47499
@@ -0,0 +1,45 @@
+// SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause
+/*
+ * Copyright (c) 2020, The Linux Foundation. All rights reserved.
+ */
+
+/dts-v1/;
+
+#include "apq8016-sbc.dtsi"
+
+/ {
+	model = "Qualcomm Technologies, Inc. APQ 8016 SBC w/ D3Camera Mezzanine";
+	compatible = "qcom,apq8016-sbc", "qcom,apq8016", "qcom,sbc";
+};
+
+&cci_i2c0 {
+	/delete-node/ camera_rear@3b;
+
+	camera_rear@76 {
+		compatible = "ovti,ov5640";
+		reg = <0x76>;
+
+		enable-gpios = <&msmgpio 34 GPIO_ACTIVE_HIGH>;
+		reset-gpios = <&msmgpio 35 GPIO_ACTIVE_LOW>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&camera_rear_default>;
+
+		clocks = <&gcc GCC_CAMSS_MCLK0_CLK>;
+		clock-names = "xclk";
+		clock-frequency = <23880000>;
+
+		vdddo-supply = <&camera_vdddo_1v8>;
+		vdda-supply = <&camera_vdda_2v8>;
+		vddd-supply = <&camera_vddd_1v5>;
+
+		status = "ok";
+
+		port {
+			ov5640_ep: endpoint {
+				clock-lanes = <1>;
+				data-lanes = <0 2>;
+				remote-endpoint = <&csiphy0_ep>;
+			};
+		};
+	};
+};
Signature · 1 line
2.25.1
#4 lore raw
Quoted 10 lines · Manivannan Sadhasivam

Hi Robert,

Quoted 6 lines · Robert Foss

Add device treee support for the Qualcomm APQ8016 SBC, otherwise known as the Dragonboard 410c with the D3Camera mezzanine expansion board.

The D3Camera mezzanine ships in a kit with a OmniVision 5640 sensor module, which is what this DT targets.

Quoted 8 lines

What is the motivation behind adding this new dts? We have been using the userspace tool [1] for applying this as an overlay for some time. But if we start adding dts for mezzanines then for sure we'll end up with some good numbers which will flood arch/{..}/qcom directory.

I could understand that one of the motivation is to provide nice user experience to users but that's also taken care by the dt-update tool IMO.

The motivation for posting this was to provoke a response like yours.

I knew about [1], but not that it included the overlays. I'm okay with using overlays and the dt-update tool. But I would have preferred that the dts files didn't live out of tree, given that this approach breaks if I change the name of a node you depend on upstream.

Thanks,
Bjorn

Quoted 86 lines

Thanks,
Mani

[1] https://github.com/96boards/dt-update

Quoted 81 lines

---

Changes since v2:
- Vinod: Change copyright assignment to Linaro

Changes since v1:
- Vinod: Changed license to GPL+BSD
- Vinod: Changed copyright year to 2020
- Nico: Changed name of mezzanine to d3camera

 arch/arm64/boot/dts/qcom/Makefile             |  1 +
 .../boot/dts/qcom/apq8016-sbc-d3camera.dts    | 45 +++++++++++++++++++
 2 files changed, 46 insertions(+)
 create mode 100644 arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts
arch/arm64/boot/dts/qcom/Makefile +1 -0
index cc103f7020fd..3f95b522694e 100644
@@ -1,5 +1,6 @@
 # SPDX-License-Identifier: GPL-2.0
 dtb-$(CONFIG_ARCH_QCOM)	+= apq8016-sbc.dtb
+dtb-$(CONFIG_ARCH_QCOM)	+= apq8016-sbc-d3camera.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= apq8096-db820c.dtb
 dtb-$(CONFIG_ARCH_QCOM) += apq8096-ifc6640.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= ipq6018-cp01-c1.dtb
arch/arm64/boot/dts/qcom/apq8016-sbc-d3camera.dts new file +45 -0
new file mode 100644
index 000000000000..752e5ec47499
@@ -0,0 +1,45 @@
+// SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause
+/*
+ * Copyright (c) 2020, The Linux Foundation. All rights reserved.
+ */
+
+/dts-v1/;
+
+#include "apq8016-sbc.dtsi"
+
+/ {
+	model = "Qualcomm Technologies, Inc. APQ 8016 SBC w/ D3Camera Mezzanine";
+	compatible = "qcom,apq8016-sbc", "qcom,apq8016", "qcom,sbc";
+};
+
+&cci_i2c0 {
+	/delete-node/ camera_rear@3b;
+
+	camera_rear@76 {
+		compatible = "ovti,ov5640";
+		reg = <0x76>;
+
+		enable-gpios = <&msmgpio 34 GPIO_ACTIVE_HIGH>;
+		reset-gpios = <&msmgpio 35 GPIO_ACTIVE_LOW>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&camera_rear_default>;
+
+		clocks = <&gcc GCC_CAMSS_MCLK0_CLK>;
+		clock-names = "xclk";
+		clock-frequency = <23880000>;
+
+		vdddo-supply = <&camera_vdddo_1v8>;
+		vdda-supply = <&camera_vdda_2v8>;
+		vddd-supply = <&camera_vddd_1v5>;
+
+		status = "ok";
+
+		port {
+			ov5640_ep: endpoint {
+				clock-lanes = <1>;
+				data-lanes = <0 2>;
+				remote-endpoint = <&csiphy0_ep>;
+			};
+		};
+	};
+};
Signature · 1 line
2.25.1
#5 lore raw

Hi Bjorn,

Thanks for the review. I'll incorporate the changes if we decide to that this DT should live upstream.

Quoted 22 lines · Bjorn Andersson
Quoted 10 lines · Manivannan Sadhasivam

Hi Robert,

Quoted 6 lines · Robert Foss

Add device treee support for the Qualcomm APQ8016 SBC, otherwise known as the Dragonboard 410c with the D3Camera mezzanine expansion board.

The D3Camera mezzanine ships in a kit with a OmniVision 5640 sensor module, which is what this DT targets.

Quoted 8 lines

What is the motivation behind adding this new dts? We have been using the userspace tool [1] for applying this as an overlay for some time. But if we start adding dts for mezzanines then for sure we'll end up with some good numbers which will flood arch/{..}/qcom directory.

I could understand that one of the motivation is to provide nice user experience to users but that's also taken care by the dt-update tool IMO.

Quoted 6 lines

The motivation for posting this was to provoke a response like yours.

I knew about [1], but not that it included the overlays. I'm okay with using overlays and the dt-update tool. But I would have preferred that the dts files didn't live out of tree, given that this approach breaks if I change the name of a node you depend on upstream.

I wasn't aware of the dt-update tool, and it seems pretty neat. However, a thought I had is that using it to enable a dt-node or a board variant is not very different from applying a patch the the upstream tree. The work it takes to do it is about the same, and the maintenance burden of using a patch is about the same as using dt-tool.

Quoted 1 line
Quoted 1 line

[1] https://github.com/96boards/dt-update