linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier
@ 2022-05-16 11:58 Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 01/17] dt-bindings: arm: fsl: Add carrier for toradex,apalis-imx6q Max Krummenacher
                   ` (16 more replies)
  0 siblings, 17 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Alexander Stein, Arnd Bergmann, Christoph Niedermaier,
	Fabio Estevam, Krzysztof Kozlowski, Li Yang, Lucas Stach,
	Marcel Ziswiler, Matthias Schiffer, NXP Linux Team,
	Oleksij Rempel, Olof Johansson, Pengutronix Kernel Team,
	Rob Herring, Sascha Hauer, Sebastian Reichel, Shawn Guo,
	Tim Harvey, devicetree, linux-arm-kernel, linux-kernel, soc

From: Max Krummenacher <max.krummenacher@toradex.com>


Shawn, this patchset reworks a lot of the imx6qdl-apalis. Commit
fa51e1dc4b91 ("ARM: dts: imx6qdl-apalis: Fix sgtl5000 detection issue")
which is in imx/fixes also touches the file.
To keep the rebasing work minimal I based the series on top of imx/dt,
but did additionally cherry-pick commit fa51e1dc4b91.
Is this the way to go in such circumstances?

This is a general update of the Apalis iMX6 device tree files.

The Toradex Apalis family is composed of a SoM that can be plugged on
various carrier boards, with carrier boards allowing multiple optional
accessories (e.g. display, camera, ...).

The device tree sources are structured into a SoM dtsi and a carrier dts
which then includes the SoM dtsi. The SoM dtsi defines and enables the
functionality self contained on the SoM and prepares for functionality
provided by the carrier HW or accessories, so that the carrier dts then
can enable or amend nodes provided. Accessories are enabled in overlays
depending on HW configuration.

The series improves the existing Apalis carrier board device trees and
adds a new device trees for the Ixora V1.2 carrier board.

Improvements:
- Specifies GPIO line names for use with libgpiod.
- Disables optional accessories. They would be enabled in overlays
  depending on HW configuration.
- Lower power consumption after poweroff.
- Move more functionality into the SoM dtsi file to reduce code
  duplication.
- General cleanup to adhere to dtbs bindings and missed alphabetically
  ordering.
- PWM backlight for backlights with inverted logic on its PWM input.

Fixes:
- STMPE ADC not functional due to wrong node name in dts.

Adds:
- imx6q-apalis-ixora-v1.2.dtb: used for a Apalis iMX6 mated in an Ixora
  V1.2 carrier board.
- Adds disable support for a OV5640 MIPI-CSI2 Camera and a ADV7280
  Video ADC on a parallel video input.



Denys Drozdov (1):
  ARM: dts: imx6q-apalis: Clean-up sd card support

Max Krummenacher (10):
  dt-bindings: arm: fsl: Add carrier for toradex,apalis-imx6q
  Revert "ARM: dts: imx6qdl-apalis: Avoid underscore in node name"
  ARM: dts: imx6q-apalis: Add gpio-line-names
  ARM: dts: imx6q-apalis: Command pmic to standby for poweroff
  ARM: dts: imx6q-apalis: Move Atmel MXT touch ctrl to SoM dtsi
  ARM: dts: imx6q-apalis: Disable HDMI
  ARM: dts: imx6q-apalis: Add support for Toradex Ixora V1.2 carrier
    boards
  ARM: dts: imx6q-apalis: backlight pwm: Simplify inverted backlight
  ARM: dts: imx6q-apalis: backlight pwm: Adapt brightness steps
  ARM: dts: imx6q-apalis: Cleanup

Oleksandr Suvorov (6):
  ARM: dts: imx6q-apalis: Move parallel rgb interface to SoM dtsi
  ARM: dts: imx6q-apalis: Move pinmux groups to SoM dtsi
  ARM: dts: imx6q-apalis: Add LVDS panel support
  ARM: dts: imx6q-apalis: Disable stmpe touchscreen
  ARM: dts: imx6q-apalis: Add ov5640 mipi csi camera
  ARM: dts: imx6q-apalis: Add adv7280 video input

 .../devicetree/bindings/arm/fsl.yaml          |   1 +
 arch/arm/boot/dts/Makefile                    |   1 +
 arch/arm/boot/dts/imx6q-apalis-eval.dts       | 117 +---
 arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts | 263 +-------
 arch/arm/boot/dts/imx6q-apalis-ixora-v1.2.dts | 290 ++++++++
 arch/arm/boot/dts/imx6q-apalis-ixora.dts      | 103 +--
 arch/arm/boot/dts/imx6qdl-apalis.dtsi         | 623 ++++++++++++++----
 7 files changed, 840 insertions(+), 558 deletions(-)
 create mode 100644 arch/arm/boot/dts/imx6q-apalis-ixora-v1.2.dts

-- 
2.20.1


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

* [PATCH v1 01/17] dt-bindings: arm: fsl: Add carrier for toradex,apalis-imx6q
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-18  0:57   ` Rob Herring
  2022-05-16 11:58 ` [PATCH v1 02/17] Revert "ARM: dts: imx6qdl-apalis: Avoid underscore in node name" Max Krummenacher
                   ` (15 subsequent siblings)
  16 siblings, 1 reply; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Alexander Stein, Christoph Niedermaier, Krzysztof Kozlowski,
	Li Yang, Lucas Stach, Marcel Ziswiler, Matthias Schiffer,
	Oleksij Rempel, Rob Herring, Sebastian Reichel, Shawn Guo,
	Tim Harvey, devicetree, linux-kernel

From: Max Krummenacher <max.krummenacher@toradex.com>

Add binding for the Ixora V1.2 carrier board our Apalis iMX6D/Q
may be mated with.

Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 Documentation/devicetree/bindings/arm/fsl.yaml | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Documentation/devicetree/bindings/arm/fsl.yaml b/Documentation/devicetree/bindings/arm/fsl.yaml
index 08bdd30e511c..eb090372dd23 100644
--- a/Documentation/devicetree/bindings/arm/fsl.yaml
+++ b/Documentation/devicetree/bindings/arm/fsl.yaml
@@ -320,6 +320,7 @@ properties:
           - enum:
               - toradex,apalis_imx6q-ixora      # Apalis iMX6Q/D Module on Ixora Carrier Board
               - toradex,apalis_imx6q-ixora-v1.1 # Apalis iMX6Q/D Module on Ixora V1.1 Carrier Board
+              - toradex,apalis_imx6q-ixora-v1.2 # Apalis iMX6Q/D Module on Ixora V1.2 Carrier Board
               - toradex,apalis_imx6q-eval       # Apalis iMX6Q/D Module on Apalis Evaluation Board
           - const: toradex,apalis_imx6q
           - const: fsl,imx6q
-- 
2.20.1


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

* [PATCH v1 02/17] Revert "ARM: dts: imx6qdl-apalis: Avoid underscore in node name"
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 01/17] dt-bindings: arm: fsl: Add carrier for toradex,apalis-imx6q Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 12:49   ` Ahmad Fatoum
  2022-05-18 19:01   ` Rob Herring
  2022-05-16 11:58 ` [PATCH v1 03/17] ARM: dts: imx6q-apalis: Add gpio-line-names Max Krummenacher
                   ` (14 subsequent siblings)
  16 siblings, 2 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Fabio Estevam, Krzysztof Kozlowski, NXP Linux Team,
	Pengutronix Kernel Team, Rob Herring, Sascha Hauer, Shawn Guo,
	devicetree, linux-arm-kernel, linux-kernel

From: Max Krummenacher <max.krummenacher@toradex.com>

The STMPE MFD device binding requires the child node to have a fixed
name, i.e. with '_', not '-'. Otherwise the stmpe_adc, stmpe_touchscreen
drivers will not be probed.

Fixes: 56086b5e804f ("ARM: dts: imx6qdl-apalis: Avoid underscore in node name")
Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/imx6qdl-apalis.dtsi | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
index bd763bae596b..da919d0544a8 100644
--- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
@@ -315,7 +315,7 @@
 		/* ADC conversion time: 80 clocks */
 		st,sample-time = <4>;
 
-		stmpe_touchscreen: stmpe-touchscreen {
+		stmpe_touchscreen: stmpe_touchscreen {
 			compatible = "st,stmpe-ts";
 			/* 8 sample average control */
 			st,ave-ctrl = <3>;
@@ -332,7 +332,7 @@
 			st,touch-det-delay = <5>;
 		};
 
-		stmpe_adc: stmpe-adc {
+		stmpe_adc: stmpe_adc {
 			compatible = "st,stmpe-adc";
 			/* forbid to use ADC channels 3-0 (touch) */
 			st,norequest-mask = <0x0F>;
-- 
2.20.1


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

* [PATCH v1 03/17] ARM: dts: imx6q-apalis: Add gpio-line-names
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 01/17] dt-bindings: arm: fsl: Add carrier for toradex,apalis-imx6q Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 02/17] Revert "ARM: dts: imx6qdl-apalis: Avoid underscore in node name" Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 04/17] ARM: dts: imx6q-apalis: Command pmic to standby for poweroff Max Krummenacher
                   ` (13 subsequent siblings)
  16 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Fabio Estevam, Krzysztof Kozlowski, NXP Linux Team,
	Pengutronix Kernel Team, Rob Herring, Sascha Hauer, Shawn Guo,
	devicetree, linux-arm-kernel, linux-kernel

From: Max Krummenacher <max.krummenacher@toradex.com>

Add GPIO line names on module level. Those are all GPIOs which a user
might use on his custom carrier board. If more meaningful names are
available on the carrier board, the user can overwrite the line names
in the carrier board level device tree.

Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/imx6qdl-apalis.dtsi | 193 ++++++++++++++++++++++++++
 1 file changed, 193 insertions(+)

diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
index da919d0544a8..e56451651a6d 100644
--- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
@@ -141,6 +141,199 @@
 	status = "disabled";
 };
 
+&gpio1 {
+	gpio-line-names = "MXM3_84",
+			  "MXM3_4",
+			  "MXM3_15/GPIO7",
+			  "MXM3_96",
+			  "MXM3_37",
+			  "",
+			  "MXM3_17/GPIO8",
+			  "MXM3_14",
+			  "MXM3_12",
+			  "MXM3_2",
+			  "MXM3_184",
+			  "MXM3_180",
+			  "MXM3_178",
+			  "MXM3_176",
+			  "MXM3_188",
+			  "MXM3_186",
+			  "MXM3_160",
+			  "MXM3_162",
+			  "MXM3_150",
+			  "MXM3_144",
+			  "MXM3_154",
+			  "MXM3_146",
+			  "",
+			  "",
+			  "MXM3_72";
+};
+
+&gpio2 {
+	gpio-line-names = "MXM3_148",
+			  "MXM3_152",
+			  "MXM3_156",
+			  "MXM3_158",
+			  "MXM3_1/GPIO1",
+			  "MXM3_3/GPIO2",
+			  "MXM3_5/GPIO3",
+			  "MXM3_7/GPIO4",
+			  "MXM3_95",
+			  "MXM3_6",
+			  "MXM3_8",
+			  "MXM3_123",
+			  "MXM3_126",
+			  "MXM3_128",
+			  "MXM3_130",
+			  "MXM3_132",
+			  "MXM3_253",
+			  "MXM3_251",
+			  "MXM3_283",
+			  "MXM3_281",
+			  "MXM3_279",
+			  "MXM3_277",
+			  "MXM3_243",
+			  "MXM3_235",
+			  "MXM3_231",
+			  "MXM3_229",
+			  "MXM3_233",
+			  "MXM3_198",
+			  "MXM3_275",
+			  "MXM3_273",
+			  "MXM3_207",
+			  "MXM3_122";
+};
+
+&gpio3 {
+	gpio-line-names = "MXM3_271",
+			  "MXM3_269",
+			  "MXM3_301",
+			  "MXM3_299",
+			  "MXM3_297",
+			  "MXM3_295",
+			  "MXM3_293",
+			  "MXM3_291",
+			  "MXM3_289",
+			  "MXM3_287",
+			  "MXM3_249",
+			  "MXM3_247",
+			  "MXM3_245",
+			  "MXM3_286",
+			  "MXM3_239",
+			  "MXM3_35",
+			  "MXM3_205",
+			  "MXM3_203",
+			  "MXM3_201",
+			  "MXM3_116",
+			  "MXM3_114",
+			  "MXM3_262",
+			  "MXM3_274",
+			  "MXM3_124",
+			  "MXM3_110",
+			  "MXM3_120",
+			  "MXM3_263",
+			  "MXM3_265",
+			  "",
+			  "MXM3_135",
+			  "MXM3_261",
+			  "MXM3_259";
+};
+
+&gpio4 {
+	gpio-line-names = "",
+			  "",
+			  "",
+			  "",
+			  "",
+			  "MXM3_194",
+			  "MXM3_136",
+			  "MXM3_134",
+			  "MXM3_140",
+			  "MXM3_138",
+			  "",
+			  "MXM3_220",
+			  "",
+			  "",
+			  "MXM3_18",
+			  "MXM3_16",
+			  "",
+			  "",
+			  "MXM3_214",
+			  "MXM3_216",
+			  "MXM3_164";
+};
+
+&gpio5 {
+	gpio-line-names = "MXM3_159",
+			  "",
+			  "",
+			  "",
+			  "MXM3_257",
+			  "",
+			  "",
+			  "",
+			  "",
+			  "",
+			  "MXM3_200",
+			  "MXM3_196",
+			  "MXM3_204",
+			  "MXM3_202",
+			  "",
+			  "",
+			  "",
+			  "",
+			  "MXM3_191",
+			  "MXM3_197",
+			  "MXM3_77",
+			  "MXM3_195",
+			  "MXM3_221",
+			  "MXM3_225",
+			  "MXM3_223",
+			  "MXM3_227",
+			  "MXM3_209",
+			  "MXM3_211",
+			  "MXM3_118",
+			  "MXM3_112",
+			  "MXM3_187",
+			  "MXM3_185";
+};
+
+&gpio6 {
+	gpio-line-names = "MXM3_183",
+			  "MXM3_181",
+			  "MXM3_179",
+			  "MXM3_177",
+			  "MXM3_175",
+			  "MXM3_173",
+			  "MXM3_255",
+			  "MXM3_83",
+			  "MXM3_91",
+			  "MXM3_13/GPIO6",
+			  "MXM3_11/GPIO5",
+			  "MXM3_79",
+			  "",
+			  "",
+			  "MXM3_190",
+			  "MXM3_193",
+			  "MXM3_89";
+};
+
+&gpio7 {
+	gpio-line-names = "",
+			  "",
+			  "",
+			  "",
+			  "",
+			  "",
+			  "",
+			  "",
+			  "",
+			  "MXM3_99",
+			  "MXM3_85",
+			  "MXM3_217",
+			  "MXM3_215";
+};
+
 &fec {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet>;
-- 
2.20.1


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

* [PATCH v1 04/17] ARM: dts: imx6q-apalis: Command pmic to standby for poweroff
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
                   ` (2 preceding siblings ...)
  2022-05-16 11:58 ` [PATCH v1 03/17] ARM: dts: imx6q-apalis: Add gpio-line-names Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 05/17] ARM: dts: imx6q-apalis: Move parallel rgb interface to SoM dtsi Max Krummenacher
                   ` (12 subsequent siblings)
  16 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Fabio Estevam, Krzysztof Kozlowski, NXP Linux Team,
	Pengutronix Kernel Team, Rob Herring, Sascha Hauer, Shawn Guo,
	devicetree, linux-arm-kernel, linux-kernel

From: Max Krummenacher <max.krummenacher@toradex.com>

The Apalis iMX6 HW doesn't allow to use the PWR_ON_REQ signal for
poweroff. Use the fsl,pmic-stby-poweroff property to command the PMIC
into a low power mode in poweroff.

Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/imx6qdl-apalis.dtsi | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
index e56451651a6d..668793356b46 100644
--- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
@@ -125,6 +125,10 @@
 	status = "disabled";
 };
 
+&clks {
+	fsl,pmic-stby-poweroff;
+};
+
 /* Apalis SPI1 */
 &ecspi1 {
 	cs-gpios = <&gpio5 25 GPIO_ACTIVE_LOW>;
@@ -387,6 +391,7 @@
 
 	pmic: pfuze100@8 {
 		compatible = "fsl,pfuze100";
+		fsl,pmic-stby-poweroff;
 		reg = <0x08>;
 
 		regulators {
-- 
2.20.1


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

* [PATCH v1 05/17] ARM: dts: imx6q-apalis: Move parallel rgb interface to SoM dtsi
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
                   ` (3 preceding siblings ...)
  2022-05-16 11:58 ` [PATCH v1 04/17] ARM: dts: imx6q-apalis: Command pmic to standby for poweroff Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 06/17] ARM: dts: imx6q-apalis: Move pinmux groups " Max Krummenacher
                   ` (11 subsequent siblings)
  16 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Oleksandr Suvorov, Fabio Estevam, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo, devicetree, linux-arm-kernel,
	linux-kernel

From: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>

Move all Parallel RGB-related nodes to the module level and disable it by
default. This allows to enable it in an overlay per the current system
configuration.

Update SPDX-License spelling to latest convention.
Update Copyright year.

Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/imx6q-apalis-eval.dts       | 57 +------------------
 arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts | 55 +-----------------
 arch/arm/boot/dts/imx6q-apalis-ixora.dts      | 55 +-----------------
 arch/arm/boot/dts/imx6qdl-apalis.dtsi         | 52 ++++++++++++++++-
 4 files changed, 55 insertions(+), 164 deletions(-)

diff --git a/arch/arm/boot/dts/imx6q-apalis-eval.dts b/arch/arm/boot/dts/imx6q-apalis-eval.dts
index a0683b4aeca1..1e6b5482a777 100644
--- a/arch/arm/boot/dts/imx6q-apalis-eval.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-eval.dts
@@ -1,6 +1,6 @@
-// SPDX-License-Identifier: GPL-2.0+ OR MIT
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
 /*
- * Copyright 2014-2020 Toradex
+ * Copyright 2014-2022 Toradex
  * Copyright 2012 Freescale Semiconductor, Inc.
  * Copyright 2011 Linaro Ltd.
  */
@@ -44,48 +44,6 @@
 		};
 	};
 
-	lcd_display: disp0 {
-		compatible = "fsl,imx-parallel-display";
-		#address-cells = <1>;
-		#size-cells = <0>;
-		interface-pix-fmt = "rgb24";
-		pinctrl-names = "default";
-		pinctrl-0 = <&pinctrl_ipu1_lcdif>;
-		status = "okay";
-
-		port@0 {
-			reg = <0>;
-
-			lcd_display_in: endpoint {
-				remote-endpoint = <&ipu1_di1_disp1>;
-			};
-		};
-
-		port@1 {
-			reg = <1>;
-
-			lcd_display_out: endpoint {
-				remote-endpoint = <&lcd_panel_in>;
-			};
-		};
-	};
-
-	panel: panel {
-		/*
-		 * edt,et057090dhu: EDT 5.7" LCD TFT
-		 * edt,et070080dh6: EDT 7.0" LCD TFT
-		 */
-		compatible = "edt,et057090dhu";
-		backlight = <&backlight>;
-		power-supply = <&reg_3v3_sw>;
-
-		port {
-			lcd_panel_in: endpoint {
-				remote-endpoint = <&lcd_display_out>;
-			};
-		};
-	};
-
 	reg_pcie_switch: regulator-pcie-switch {
 		compatible = "regulator-fixed";
 		regulator-name = "pcie_switch";
@@ -106,13 +64,6 @@
 	};
 };
 
-&backlight {
-	brightness-levels = <0 127 191 223 239 247 251 255>;
-	default-brightness-level = <1>;
-	power-supply = <&reg_3v3_sw>;
-	status = "okay";
-};
-
 &can1 {
 	xceiver-supply = <&reg_3v3_sw>;
 	status = "okay";
@@ -164,10 +115,6 @@
 	status = "okay";
 };
 
-&ipu1_di1_disp1 {
-	remote-endpoint = <&lcd_display_in>;
-};
-
 &ldb {
 	status = "okay";
 };
diff --git a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
index 86e84781cf5d..527585d26e51 100644
--- a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
@@ -1,6 +1,6 @@
-// SPDX-License-Identifier: GPL-2.0+ OR MIT
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
 /*
- * Copyright 2014-2020 Toradex
+ * Copyright 2014-2022 Toradex
  * Copyright 2012 Freescale Semiconductor, Inc.
  * Copyright 2011 Linaro Ltd.
  */
@@ -45,47 +45,6 @@
 		};
 	};
 
-	lcd_display: disp0 {
-		compatible = "fsl,imx-parallel-display";
-		#address-cells = <1>;
-		#size-cells = <0>;
-		interface-pix-fmt = "rgb24";
-		pinctrl-names = "default";
-		pinctrl-0 = <&pinctrl_ipu1_lcdif>;
-		status = "okay";
-
-		port@0 {
-			reg = <0>;
-
-			lcd_display_in: endpoint {
-				remote-endpoint = <&ipu1_di1_disp1>;
-			};
-		};
-
-		port@1 {
-			reg = <1>;
-
-			lcd_display_out: endpoint {
-				remote-endpoint = <&lcd_panel_in>;
-			};
-		};
-	};
-
-	panel: panel {
-		/*
-		 * edt,et057090dhu: EDT 5.7" LCD TFT
-		 * edt,et070080dh6: EDT 7.0" LCD TFT
-		 */
-		compatible = "edt,et057090dhu";
-		backlight = <&backlight>;
-
-		port {
-			lcd_panel_in: endpoint {
-				remote-endpoint = <&lcd_display_out>;
-			};
-		};
-	};
-
 	leds {
 		compatible = "gpio-leds";
 
@@ -114,12 +73,6 @@
 	};
 };
 
-&backlight {
-	brightness-levels = <0 127 191 223 239 247 251 255>;
-	default-brightness-level = <1>;
-	status = "okay";
-};
-
 &can1 {
 	status = "okay";
 };
@@ -164,10 +117,6 @@
 	status = "okay";
 };
 
-&ipu1_di1_disp1 {
-	remote-endpoint = <&lcd_display_in>;
-};
-
 &ldb {
 	status = "okay";
 };
diff --git a/arch/arm/boot/dts/imx6q-apalis-ixora.dts b/arch/arm/boot/dts/imx6q-apalis-ixora.dts
index 62e72773e53b..9900ab04fb28 100644
--- a/arch/arm/boot/dts/imx6q-apalis-ixora.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-ixora.dts
@@ -1,6 +1,6 @@
-// SPDX-License-Identifier: GPL-2.0+ OR MIT
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
 /*
- * Copyright 2014-2020 Toradex
+ * Copyright 2014-2022 Toradex
  * Copyright 2012 Freescale Semiconductor, Inc.
  * Copyright 2011 Linaro Ltd.
  */
@@ -44,47 +44,6 @@
 		};
 	};
 
-	lcd_display: disp0 {
-		compatible = "fsl,imx-parallel-display";
-		#address-cells = <1>;
-		#size-cells = <0>;
-		interface-pix-fmt = "rgb24";
-		pinctrl-names = "default";
-		pinctrl-0 = <&pinctrl_ipu1_lcdif>;
-		status = "okay";
-
-		port@0 {
-			reg = <0>;
-
-			lcd_display_in: endpoint {
-				remote-endpoint = <&ipu1_di1_disp1>;
-			};
-		};
-
-		port@1 {
-			reg = <1>;
-
-			lcd_display_out: endpoint {
-				remote-endpoint = <&lcd_panel_in>;
-			};
-		};
-	};
-
-	panel: panel {
-		/*
-		 * edt,et057090dhu: EDT 5.7" LCD TFT
-		 * edt,et070080dh6: EDT 7.0" LCD TFT
-		 */
-		compatible = "edt,et057090dhu";
-		backlight = <&backlight>;
-
-		port {
-			lcd_panel_in: endpoint {
-				remote-endpoint = <&lcd_display_out>;
-			};
-		};
-	};
-
 	leds {
 		compatible = "gpio-leds";
 
@@ -113,12 +72,6 @@
 	};
 };
 
-&backlight {
-	brightness-levels = <0 127 191 223 239 247 251 255>;
-	default-brightness-level = <1>;
-	status = "okay";
-};
-
 &can1 {
 	status = "okay";
 };
@@ -168,10 +121,6 @@
 	status = "okay";
 };
 
-&ipu1_di1_disp1 {
-	remote-endpoint = <&lcd_display_in>;
-};
-
 &ldb {
 	status = "okay";
 };
diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
index 668793356b46..c0ae08780d86 100644
--- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
@@ -1,6 +1,6 @@
-// SPDX-License-Identifier: GPL-2.0+ OR MIT
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
 /*
- * Copyright 2014-2020 Toradex
+ * Copyright 2014-2022 Toradex
  * Copyright 2012 Freescale Semiconductor, Inc.
  * Copyright 2011 Linaro Ltd.
  */
@@ -21,11 +21,53 @@
 		compatible = "pwm-backlight";
 		pinctrl-names = "default";
 		pinctrl-0 = <&pinctrl_gpio_bl_on>;
-		pwms = <&pwm4 0 5000000>;
+		brightness-levels = <0 127 191 223 239 247 251 255>;
+		default-brightness-level = <1>;
 		enable-gpios = <&gpio3 13 GPIO_ACTIVE_HIGH>;
+		power-supply = <&reg_module_3v3>;
+		pwms = <&pwm4 0 5000000>;
 		status = "disabled";
 	};
 
+	lcd_display: disp0 {
+		compatible = "fsl,imx-parallel-display";
+		#address-cells = <1>;
+		#size-cells = <0>;
+		interface-pix-fmt = "rgb24";
+		pinctrl-names = "default";
+		pinctrl-0 = <&pinctrl_ipu1_lcdif>;
+		status = "disabled";
+
+		port@0 {
+			reg = <0>;
+
+			lcd_display_in: endpoint {
+				remote-endpoint = <&ipu1_di1_disp1>;
+			};
+		};
+
+		port@1 {
+			reg = <1>;
+
+			lcd_display_out: endpoint {
+				remote-endpoint = <&lcd_panel_in>;
+			};
+		};
+	};
+
+	panel_dpi: panel-dpi {
+		compatible = "edt,et057090dhu";
+		backlight = <&backlight>;
+
+		status = "disabled";
+
+		port {
+			lcd_panel_in: endpoint {
+				remote-endpoint = <&lcd_display_out>;
+			};
+		};
+	};
+
 	reg_module_3v3: regulator-module-3v3 {
 		compatible = "regulator-fixed";
 		regulator-name = "+V3.3";
@@ -553,6 +595,10 @@
 	status = "disabled";
 };
 
+&ipu1_di1_disp1 {
+	remote-endpoint = <&lcd_display_in>;
+};
+
 &pwm1 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pwm1>;
-- 
2.20.1


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

* [PATCH v1 06/17] ARM: dts: imx6q-apalis: Move pinmux groups to SoM dtsi
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
                   ` (4 preceding siblings ...)
  2022-05-16 11:58 ` [PATCH v1 05/17] ARM: dts: imx6q-apalis: Move parallel rgb interface to SoM dtsi Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 07/17] ARM: dts: imx6q-apalis: Move Atmel MXT touch ctrl " Max Krummenacher
                   ` (10 subsequent siblings)
  16 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Oleksandr Suvorov, Fabio Estevam, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo, devicetree, linux-arm-kernel,
	linux-kernel

From: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>

GPIO pinmux groups are declared on the module level. Move muxing
them to the same level. It also reduces code duplication.

Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/imx6q-apalis-eval.dts       | 12 ------------
 arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts | 10 ----------
 arch/arm/boot/dts/imx6q-apalis-ixora.dts      |  8 --------
 arch/arm/boot/dts/imx6qdl-apalis.dtsi         |  8 ++++++++
 4 files changed, 8 insertions(+), 30 deletions(-)

diff --git a/arch/arm/boot/dts/imx6q-apalis-eval.dts b/arch/arm/boot/dts/imx6q-apalis-eval.dts
index 1e6b5482a777..fe5d491e1399 100644
--- a/arch/arm/boot/dts/imx6q-apalis-eval.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-eval.dts
@@ -206,15 +206,3 @@
 	cd-gpios = <&gpio6 14 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
-
-&iomuxc {
-	/*
-	 * Mux the Apalis GPIOs
-	 */
-	pinctrl-names = "default";
-	pinctrl-0 = <&pinctrl_apalis_gpio1 &pinctrl_apalis_gpio2
-		     &pinctrl_apalis_gpio3 &pinctrl_apalis_gpio4
-		     &pinctrl_apalis_gpio5 &pinctrl_apalis_gpio6
-		     &pinctrl_apalis_gpio7 &pinctrl_apalis_gpio8
-		    >;
-};
diff --git a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
index 527585d26e51..8febfc0aea93 100644
--- a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
@@ -202,16 +202,6 @@
 };
 
 &iomuxc {
-	/*
-	 * Mux the Apalis GPIOs
-	 */
-	pinctrl-names = "default";
-	pinctrl-0 = <&pinctrl_apalis_gpio1 &pinctrl_apalis_gpio2
-		     &pinctrl_apalis_gpio3 &pinctrl_apalis_gpio4
-		     &pinctrl_apalis_gpio5 &pinctrl_apalis_gpio6
-		     &pinctrl_apalis_gpio7 &pinctrl_apalis_gpio8
-		    >;
-
 	pinctrl_leds_ixora: ledsixoragrp {
 		fsl,pins = <
 			MX6QDL_PAD_SD2_DAT1__GPIO1_IO14 0x1b0b0
diff --git a/arch/arm/boot/dts/imx6q-apalis-ixora.dts b/arch/arm/boot/dts/imx6q-apalis-ixora.dts
index 9900ab04fb28..78cf1d9583c1 100644
--- a/arch/arm/boot/dts/imx6q-apalis-ixora.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-ixora.dts
@@ -205,14 +205,6 @@
 };
 
 &iomuxc {
-	/* Mux the Apalis GPIOs */
-	pinctrl-names = "default";
-	pinctrl-0 = <&pinctrl_apalis_gpio1 &pinctrl_apalis_gpio2
-		     &pinctrl_apalis_gpio3 &pinctrl_apalis_gpio4
-		     &pinctrl_apalis_gpio5 &pinctrl_apalis_gpio6
-		     &pinctrl_apalis_gpio7 &pinctrl_apalis_gpio8
-		    >;
-
 	pinctrl_leds_ixora: ledsixoragrp {
 		fsl,pins = <
 			MX6QDL_PAD_SD1_DAT1__GPIO1_IO17 0x1b0b0
diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
index c0ae08780d86..9413c14ce5f6 100644
--- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
@@ -709,6 +709,14 @@
 };
 
 &iomuxc {
+	/* Mux the Apalis GPIOs */
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_apalis_gpio1 &pinctrl_apalis_gpio2
+		     &pinctrl_apalis_gpio3 &pinctrl_apalis_gpio4
+		     &pinctrl_apalis_gpio5 &pinctrl_apalis_gpio6
+		     &pinctrl_apalis_gpio7 &pinctrl_apalis_gpio8
+		    >;
+
 	pinctrl_apalis_gpio1: gpio2io04grp {
 		fsl,pins = <
 			MX6QDL_PAD_NANDF_D4__GPIO2_IO04 0x130b0
-- 
2.20.1


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

* [PATCH v1 07/17] ARM: dts: imx6q-apalis: Move Atmel MXT touch ctrl to SoM dtsi
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
                   ` (5 preceding siblings ...)
  2022-05-16 11:58 ` [PATCH v1 06/17] ARM: dts: imx6q-apalis: Move pinmux groups " Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 08/17] ARM: dts: imx6q-apalis: Add LVDS panel support Max Krummenacher
                   ` (9 subsequent siblings)
  16 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Fabio Estevam, Krzysztof Kozlowski, NXP Linux Team,
	Pengutronix Kernel Team, Rob Herring, Sascha Hauer, Shawn Guo,
	devicetree, linux-arm-kernel, linux-kernel

From: Max Krummenacher <max.krummenacher@toradex.com>

Reduces code duplication. While at it drop the comments which do not
apply on Apalis iMX6 but add the correct SoM pin names.

Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/imx6q-apalis-eval.dts       | 13 -------------
 arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts | 13 -------------
 arch/arm/boot/dts/imx6q-apalis-ixora.dts      | 13 -------------
 arch/arm/boot/dts/imx6qdl-apalis.dtsi         | 11 +++++++++++
 4 files changed, 11 insertions(+), 39 deletions(-)

diff --git a/arch/arm/boot/dts/imx6q-apalis-eval.dts b/arch/arm/boot/dts/imx6q-apalis-eval.dts
index fe5d491e1399..5985d1169be1 100644
--- a/arch/arm/boot/dts/imx6q-apalis-eval.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-eval.dts
@@ -82,19 +82,6 @@
 &i2c1 {
 	status = "okay";
 
-	/*
-	 * Touchscreen is using SODIMM 28/30, also used for PWM<B>, PWM<C>,
-	 * aka pwm2, pwm3. so if you enable touchscreen, disable the pwms
-	 */
-	touchscreen@4a {
-		compatible = "atmel,maxtouch";
-		reg = <0x4a>;
-		interrupt-parent = <&gpio6>;
-		interrupts = <10 IRQ_TYPE_EDGE_FALLING>;
-		reset-gpios = <&gpio6 9 GPIO_ACTIVE_LOW>; /* SODIMM 13 */
-		status = "disabled";
-	};
-
 	pcie-switch@58 {
 		compatible = "plx,pex8605";
 		reg = <0x58>;
diff --git a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
index 8febfc0aea93..21f88e19e87d 100644
--- a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
@@ -89,19 +89,6 @@
 &i2c1 {
 	status = "okay";
 
-	/*
-	 * Touchscreen is using SODIMM 28/30, also used for PWM<B>, PWM<C>,
-	 * aka pwm2, pwm3. so if you enable touchscreen, disable the pwms
-	 */
-	touchscreen@4a {
-		compatible = "atmel,maxtouch";
-		reg = <0x4a>;
-		interrupt-parent = <&gpio6>;
-		interrupts = <10 IRQ_TYPE_EDGE_FALLING>;
-		reset-gpios = <&gpio6 9 GPIO_ACTIVE_LOW>; /* SODIMM 13 */
-		status = "disabled";
-	};
-
 	/* M41T0M6 real time clock on carrier board */
 	rtc_i2c: rtc@68 {
 		compatible = "st,m41t0";
diff --git a/arch/arm/boot/dts/imx6q-apalis-ixora.dts b/arch/arm/boot/dts/imx6q-apalis-ixora.dts
index 78cf1d9583c1..6743617ad1c1 100644
--- a/arch/arm/boot/dts/imx6q-apalis-ixora.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-ixora.dts
@@ -88,19 +88,6 @@
 &i2c1 {
 	status = "okay";
 
-	/*
-	 * Touchscreen is using SODIMM 28/30, also used for PWM<B>, PWM<C>,
-	 * aka pwm2, pwm3. so if you enable touchscreen, disable the pwms
-	 */
-	touchscreen@4a {
-		compatible = "atmel,maxtouch";
-		reg = <0x4a>;
-		interrupt-parent = <&gpio6>;
-		interrupts = <10 IRQ_TYPE_EDGE_FALLING>;
-		reset-gpios = <&gpio6 9 GPIO_ACTIVE_LOW>; /* SODIMM 13 */
-		status = "disabled";
-	};
-
 	eeprom@50 {
 		compatible = "atmel,24c02";
 		reg = <0x50>;
diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
index 9413c14ce5f6..3aa66b6d0c88 100644
--- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
@@ -416,6 +416,17 @@
 	scl-gpios = <&gpio5 27 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
 	sda-gpios = <&gpio5 26 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
 	status = "disabled";
+
+	atmel_mxt_ts: touchscreen@4a {
+		compatible = "atmel,maxtouch";
+		/* These GPIOs are muxed with the iomuxc node */
+		interrupt-parent = <&gpio6>;
+		interrupts = <10 IRQ_TYPE_EDGE_FALLING>;	/* MXM3_11 */
+		reg = <0x4a>;
+		reset-gpios = <&gpio6 9 GPIO_ACTIVE_LOW>;	/* MXM3_13 */
+		status = "disabled";
+	};
+
 };
 
 /*
-- 
2.20.1


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

* [PATCH v1 08/17] ARM: dts: imx6q-apalis: Add LVDS panel support
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
                   ` (6 preceding siblings ...)
  2022-05-16 11:58 ` [PATCH v1 07/17] ARM: dts: imx6q-apalis: Move Atmel MXT touch ctrl " Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 09/17] ARM: dts: imx6q-apalis: Disable HDMI Max Krummenacher
                   ` (8 subsequent siblings)
  16 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Oleksandr Suvorov, Fabio Estevam, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo, devicetree, linux-arm-kernel,
	linux-kernel

From: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>

Add LVDS panel and endpoint linkage support but keep the inherited
disabled state. This allows to enable it in an overlay per the current
system configuration.

Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/imx6q-apalis-eval.dts       |  4 ---
 arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts |  4 ---
 arch/arm/boot/dts/imx6q-apalis-ixora.dts      |  4 ---
 arch/arm/boot/dts/imx6qdl-apalis.dtsi         | 36 +++++++++++++++++++
 4 files changed, 36 insertions(+), 12 deletions(-)

diff --git a/arch/arm/boot/dts/imx6q-apalis-eval.dts b/arch/arm/boot/dts/imx6q-apalis-eval.dts
index 5985d1169be1..948bbece3ab5 100644
--- a/arch/arm/boot/dts/imx6q-apalis-eval.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-eval.dts
@@ -102,10 +102,6 @@
 	status = "okay";
 };
 
-&ldb {
-	status = "okay";
-};
-
 &pcie {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_reset_moci>;
diff --git a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
index 21f88e19e87d..beb1981fc775 100644
--- a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
@@ -104,10 +104,6 @@
 	status = "okay";
 };
 
-&ldb {
-	status = "okay";
-};
-
 &pcie {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_reset_moci>;
diff --git a/arch/arm/boot/dts/imx6q-apalis-ixora.dts b/arch/arm/boot/dts/imx6q-apalis-ixora.dts
index 6743617ad1c1..28e5d6b68530 100644
--- a/arch/arm/boot/dts/imx6q-apalis-ixora.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-ixora.dts
@@ -108,10 +108,6 @@
 	status = "okay";
 };
 
-&ldb {
-	status = "okay";
-};
-
 &pcie {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_reset_moci>;
diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
index 3aa66b6d0c88..428841cdaac2 100644
--- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
@@ -68,6 +68,18 @@
 		};
 	};
 
+	panel_lvds: panel-lvds {
+		compatible = "panel-lvds";
+		backlight = <&backlight>;
+		status = "disabled";
+
+		port {
+			lvds_panel_in: endpoint {
+				remote-endpoint = <&lvds0_out>;
+			};
+		};
+	};
+
 	reg_module_3v3: regulator-module-3v3 {
 		compatible = "regulator-fixed";
 		regulator-name = "+V3.3";
@@ -610,6 +622,30 @@
 	remote-endpoint = <&lcd_display_in>;
 };
 
+&ldb {
+	lvds-channel@0 {
+		port@4 {
+			reg = <4>;
+
+			lvds0_out: endpoint {
+				remote-endpoint = <&lvds_panel_in>;
+			};
+		};
+	};
+
+	lvds-channel@1 {
+		fsl,data-mapping = "spwg";
+		fsl,data-width = <18>;
+
+		port@4 {
+			reg = <4>;
+
+			lvds1_out: endpoint {
+			};
+		};
+	};
+};
+
 &pwm1 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pwm1>;
-- 
2.20.1


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

* [PATCH v1 09/17] ARM: dts: imx6q-apalis: Disable HDMI
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
                   ` (7 preceding siblings ...)
  2022-05-16 11:58 ` [PATCH v1 08/17] ARM: dts: imx6q-apalis: Add LVDS panel support Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 10/17] ARM: dts: imx6q-apalis: Disable stmpe touchscreen Max Krummenacher
                   ` (7 subsequent siblings)
  16 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Fabio Estevam, Krzysztof Kozlowski, NXP Linux Team,
	Pengutronix Kernel Team, Rob Herring, Sascha Hauer, Shawn Guo,
	devicetree, linux-arm-kernel, linux-kernel

From: Max Krummenacher <max.krummenacher@toradex.com>

This allows to enable it in an overlay per the current system
configuration.

Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/imx6q-apalis-eval.dts       | 4 ----
 arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts | 4 ----
 arch/arm/boot/dts/imx6q-apalis-ixora.dts      | 4 ----
 3 files changed, 12 deletions(-)

diff --git a/arch/arm/boot/dts/imx6q-apalis-eval.dts b/arch/arm/boot/dts/imx6q-apalis-eval.dts
index 948bbece3ab5..2436f9a1e18c 100644
--- a/arch/arm/boot/dts/imx6q-apalis-eval.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-eval.dts
@@ -74,10 +74,6 @@
 	status = "okay";
 };
 
-&hdmi {
-	status = "okay";
-};
-
 /* I2C1_SDA/SCL on MXM3 209/211 (e.g. RTC on carrier board) */
 &i2c1 {
 	status = "okay";
diff --git a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
index beb1981fc775..b254e96d194a 100644
--- a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
@@ -81,10 +81,6 @@
 	status = "okay";
 };
 
-&hdmi {
-	status = "okay";
-};
-
 /* I2C1_SDA/SCL on MXM3 209/211 (e.g. RTC on carrier board) */
 &i2c1 {
 	status = "okay";
diff --git a/arch/arm/boot/dts/imx6q-apalis-ixora.dts b/arch/arm/boot/dts/imx6q-apalis-ixora.dts
index 28e5d6b68530..97ddf4621bdf 100644
--- a/arch/arm/boot/dts/imx6q-apalis-ixora.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-ixora.dts
@@ -80,10 +80,6 @@
 	status = "okay";
 };
 
-&hdmi {
-	status = "okay";
-};
-
 /* I2C1_SDA/SCL on MXM3 209/211 (e.g. RTC on carrier board) */
 &i2c1 {
 	status = "okay";
-- 
2.20.1


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

* [PATCH v1 10/17] ARM: dts: imx6q-apalis: Disable stmpe touchscreen
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
                   ` (8 preceding siblings ...)
  2022-05-16 11:58 ` [PATCH v1 09/17] ARM: dts: imx6q-apalis: Disable HDMI Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 11/17] ARM: dts: imx6q-apalis: Add ov5640 mipi csi camera Max Krummenacher
                   ` (6 subsequent siblings)
  16 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Oleksandr Suvorov, Fabio Estevam, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo, devicetree, linux-arm-kernel,
	linux-kernel

From: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>

Unify its label with other toradex SoM dtbs.
This allows to enable it in an overlay per the current
system configuration.

Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/imx6qdl-apalis.dtsi | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
index 428841cdaac2..506d040ea37a 100644
--- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
@@ -578,7 +578,7 @@
 		/* ADC conversion time: 80 clocks */
 		st,sample-time = <4>;
 
-		stmpe_touchscreen: stmpe_touchscreen {
+		stmpe_ts: stmpe_touchscreen {
 			compatible = "st,stmpe-ts";
 			/* 8 sample average control */
 			st,ave-ctrl = <3>;
@@ -593,6 +593,7 @@
 			st,settling = <3>;
 			/* 5 ms touch detect interrupt delay */
 			st,touch-det-delay = <5>;
+			status = "disabled";
 		};
 
 		stmpe_adc: stmpe_adc {
-- 
2.20.1


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

* [PATCH v1 11/17] ARM: dts: imx6q-apalis: Add ov5640 mipi csi camera
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
                   ` (9 preceding siblings ...)
  2022-05-16 11:58 ` [PATCH v1 10/17] ARM: dts: imx6q-apalis: Disable stmpe touchscreen Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 12:08   ` Fabio Estevam
  2022-05-17 18:28   ` Fabio Estevam
  2022-05-16 11:58 ` [PATCH v1 12/17] ARM: dts: imx6q-apalis: Add adv7280 video input Max Krummenacher
                   ` (5 subsequent siblings)
  16 siblings, 2 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Oleksandr Suvorov, Fabio Estevam, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo, devicetree, linux-arm-kernel,
	linux-kernel

From: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>

The Apalis iMX6 modules allow connecting a mipi-csi video input.
Add support for our OV5640 camera module but have it disabled.
This allows to enable it in an overlay per the current system
configuration.

Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/imx6qdl-apalis.dtsi | 67 ++++++++++++++++++++++++++-
 1 file changed, 66 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
index 506d040ea37a..0d1004eede62 100644
--- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
@@ -29,6 +29,12 @@
 		status = "disabled";
 	};
 
+	clk_ov5640_osc: clk_ov5640_osc_int {
+		compatible = "fixed-clock";
+		#clock-cells = <0>;
+		clock-frequency = <24000000>;
+	};
+
 	lcd_display: disp0 {
 		compatible = "fsl,imx-parallel-display";
 		#address-cells = <1>;
@@ -96,6 +102,26 @@
 		regulator-always-on;
 	};
 
+	reg_ov5640_1v8_d_o_vdd: regulator-ov5640-1v8-d-o-vdd {
+		compatible = "regulator-fixed";
+		regulator-always-on;
+		regulator-max-microvolt = <1800000>;
+		regulator-min-microvolt = <1800000>;
+		regulator-name = "DOVDD/DVDD_1.8V";
+		/* Note: The CSI module uses on-board 3.3V_SW supply */
+		vin-supply = <&reg_module_3v3>;
+	};
+
+	reg_ov5640_2v8_a_vdd: regulator-ov5640-2v8-a-vdd {
+		compatible = "regulator-fixed";
+		regulator-always-on;
+		regulator-max-microvolt = <2800000>;
+		regulator-min-microvolt = <2800000>;
+		regulator-name = "AVDD/AFVDD_2.8V";
+		/* Note: The CSI module uses on-board 3.3V_SW supply */
+		vin-supply = <&reg_module_3v3>;
+	};
+
 	reg_usb_otg_vbus: regulator-usb-otg-vbus {
 		compatible = "regulator-fixed";
 		pinctrl-names = "default";
@@ -438,7 +464,6 @@
 		reset-gpios = <&gpio6 9 GPIO_ACTIVE_LOW>;	/* MXM3_13 */
 		status = "disabled";
 	};
-
 };
 
 /*
@@ -617,6 +642,30 @@
 	scl-gpios = <&gpio3 17 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
 	sda-gpios = <&gpio3 18 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
 	status = "disabled";
+
+	ov5640_csi_cam: ov5640_mipi@3c {
+		compatible = "ovti,ov5640";
+		AVDD-supply = <&reg_ov5640_2v8_a_vdd>;
+		DOVDD-supply = <&reg_ov5640_1v8_d_o_vdd>;
+		DVDD-supply = <&reg_ov5640_1v8_d_o_vdd>;
+		clocks = <&clks IMX6QDL_CLK_CKO2>;
+		clock-names = "xclk";
+		pinctrl-names = "default";
+		pinctrl-0 = <&pinctrl_cam_mclk>;
+		/* These GPIOs are muxed with the iomuxc node */
+		powerdown-gpios = <&gpio2 5 GPIO_ACTIVE_HIGH>;
+		reg = <0x3c>;
+		reset-gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
+		status = "disabled";
+
+		port {
+			ov5640_to_mipi_csi2: endpoint {
+				clock-lanes = <0>;
+				data-lanes = <1 2>;
+				remote-endpoint = <&mipi_csi_from_ov5640>;
+			};
+		};
+	};
 };
 
 &ipu1_di1_disp1 {
@@ -647,6 +696,22 @@
 	};
 };
 
+&mipi_csi {
+	#address-cells = <1>;
+	#size-cells = <0>;
+	status = "disabled";
+
+	port@0 {
+		reg = <0>;
+
+		mipi_csi_from_ov5640: endpoint {
+			clock-lanes = <0>;
+			data-lanes = <1 2>;
+			remote-endpoint = <&ov5640_to_mipi_csi2>;
+		};
+	};
+};
+
 &pwm1 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pwm1>;
-- 
2.20.1


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

* [PATCH v1 12/17] ARM: dts: imx6q-apalis: Add adv7280 video input
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
                   ` (10 preceding siblings ...)
  2022-05-16 11:58 ` [PATCH v1 11/17] ARM: dts: imx6q-apalis: Add ov5640 mipi csi camera Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 12:10   ` Fabio Estevam
  2022-05-16 11:58 ` [PATCH v1 13/17] ARM: dts: imx6q-apalis: Clean-up sd card support Max Krummenacher
                   ` (4 subsequent siblings)
  16 siblings, 1 reply; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Oleksandr Suvorov, Fabio Estevam, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo, devicetree, linux-arm-kernel,
	linux-kernel

From: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>

The Apalis iMX6 modules allow connecting a parallel video input.
Add support for our ADV7280 video input module but have it disabled.
This allows to enable it in an overlay per the current system
configuration.

Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/imx6qdl-apalis.dtsi | 30 +++++++++++++++++++++++++++
 1 file changed, 30 insertions(+)

diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
index 0d1004eede62..f33dfaa907d7 100644
--- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
@@ -418,6 +418,21 @@
 			  "MXM3_215";
 };
 
+&gpr {
+	ipu1_csi0_mux {
+		#address-cells = <1>;
+		#size-cells = <0>;
+		status = "disabled";
+
+		port@1 {
+			reg = <1>;
+			ipu1_csi0_mux_from_parallel_sensor: endpoint {
+				remote-endpoint = <&adv7280_to_ipu1_csi0_mux>;
+			};
+		};
+	};
+};
+
 &fec {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet>;
@@ -643,6 +658,21 @@
 	sda-gpios = <&gpio3 18 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
 	status = "disabled";
 
+	adv_7280: adv7280@21 {
+		compatible = "adi,adv7280";
+		reg = <0x21>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&pinctrl_ipu1_csi0>;
+		status = "disabled";
+
+		port {
+			adv7280_to_ipu1_csi0_mux: endpoint {
+				bus-width = <8>;
+				remote-endpoint = <&ipu1_csi0_mux_from_parallel_sensor>;
+			};
+		};
+	};
+
 	ov5640_csi_cam: ov5640_mipi@3c {
 		compatible = "ovti,ov5640";
 		AVDD-supply = <&reg_ov5640_2v8_a_vdd>;
-- 
2.20.1


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

* [PATCH v1 13/17] ARM: dts: imx6q-apalis: Clean-up sd card support
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
                   ` (11 preceding siblings ...)
  2022-05-16 11:58 ` [PATCH v1 12/17] ARM: dts: imx6q-apalis: Add adv7280 video input Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 14/17] ARM: dts: imx6q-apalis: Add support for Toradex Ixora V1.2 carrier boards Max Krummenacher
                   ` (3 subsequent siblings)
  16 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Denys Drozdov, Fabio Estevam, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo, devicetree, linux-arm-kernel,
	linux-kernel

From: Denys Drozdov <denys.drozdov@toradex.com>

Configure SOM DTSI to 8-bit, card detect in the SoM dtsi as this is
the Apalis family default functionality.
Limit the interface to 4-bit only on the Ixora V1.1 carrier boards.

Signed-off-by: Denys Drozdov <denys.drozdov@toradex.com>
Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/imx6q-apalis-eval.dts       | 3 ---
 arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts | 1 -
 arch/arm/boot/dts/imx6qdl-apalis.dtsi         | 3 ++-
 3 files changed, 2 insertions(+), 5 deletions(-)

diff --git a/arch/arm/boot/dts/imx6q-apalis-eval.dts b/arch/arm/boot/dts/imx6q-apalis-eval.dts
index 2436f9a1e18c..5c4d9a4ec586 100644
--- a/arch/arm/boot/dts/imx6q-apalis-eval.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-eval.dts
@@ -172,9 +172,6 @@
 
 /* MMC1 */
 &usdhc1 {
-	pinctrl-names = "default";
-	pinctrl-0 = <&pinctrl_usdhc1_4bit &pinctrl_usdhc1_8bit &pinctrl_mmc_cd>;
-	cd-gpios = <&gpio4 20 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
index b254e96d194a..2d0324103804 100644
--- a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
@@ -175,7 +175,6 @@
 &usdhc1 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_usdhc1_4bit &pinctrl_mmc_cd>;
-	cd-gpios = <&gpio4 20 GPIO_ACTIVE_LOW>;
 	bus-width = <4>;
 	status = "okay";
 };
diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
index f33dfaa907d7..57642aefe349 100644
--- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
@@ -817,7 +817,8 @@
 /* MMC1 */
 &usdhc1 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&pinctrl_usdhc1_4bit &pinctrl_usdhc1_8bit>;
+	pinctrl-0 = <&pinctrl_usdhc1_4bit &pinctrl_usdhc1_8bit &pinctrl_mmc_cd>;
+	cd-gpios = <&gpio4 20 GPIO_ACTIVE_LOW>;
 	vqmmc-supply = <&reg_module_3v3>;
 	bus-width = <8>;
 	disable-wp;
-- 
2.20.1


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

* [PATCH v1 14/17] ARM: dts: imx6q-apalis: Add support for Toradex Ixora V1.2 carrier boards
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
                   ` (12 preceding siblings ...)
  2022-05-16 11:58 ` [PATCH v1 13/17] ARM: dts: imx6q-apalis: Clean-up sd card support Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 15/17] ARM: dts: imx6q-apalis: backlight pwm: Simplify inverted backlight Max Krummenacher
                   ` (2 subsequent siblings)
  16 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Arnd Bergmann, Fabio Estevam, Krzysztof Kozlowski,
	NXP Linux Team, Olof Johansson, Pengutronix Kernel Team,
	Rob Herring, Sascha Hauer, Shawn Guo, devicetree,
	linux-arm-kernel, linux-kernel, soc

From: Max Krummenacher <max.krummenacher@toradex.com>

The Ixora V1.2 carrier board adds SW relevant new features compared to
the V1.1 version.

- An I2C EEPROM is added.
- The SD card slot got a switchable 3.3V supply.
- Pull ups on the SD card signals are not assembled to faciliate 1.8V
  speed modes.
- The CAN transceivers got a switchable 3.3V supply.

Add a new device tree and, as the differences are so small rework the
device tree for V1.1 to include the V1.2 device tree and adjust as
needed.
Drop adding the toradex,apalis_imx6q-ixora to the dtb compatible to
adhere to the binding yaml document.

Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/Makefile                    |   1 +
 arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts | 178 +----------
 arch/arm/boot/dts/imx6q-apalis-ixora-v1.2.dts | 290 ++++++++++++++++++
 3 files changed, 303 insertions(+), 166 deletions(-)
 create mode 100644 arch/arm/boot/dts/imx6q-apalis-ixora-v1.2.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index 0ad8339e07d8..55fbe4f8c598 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -544,6 +544,7 @@ dtb-$(CONFIG_SOC_IMX6Q) += \
 	imx6q-apalis-eval.dtb \
 	imx6q-apalis-ixora.dtb \
 	imx6q-apalis-ixora-v1.1.dtb \
+	imx6q-apalis-ixora-v1.2.dtb \
 	imx6q-apf6dev.dtb \
 	imx6q-arm2.dtb \
 	imx6q-b450v3.dtb \
diff --git a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
index 2d0324103804..44637d606e61 100644
--- a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.1.dts
@@ -5,187 +5,33 @@
  * Copyright 2011 Linaro Ltd.
  */
 
-/dts-v1/;
-
-#include <dt-bindings/gpio/gpio.h>
-#include <dt-bindings/input/input.h>
-#include <dt-bindings/interrupt-controller/irq.h>
-#include "imx6q.dtsi"
-#include "imx6qdl-apalis.dtsi"
+#include "imx6q-apalis-ixora-v1.2.dts"
 
 / {
 	model = "Toradex Apalis iMX6Q/D Module on Ixora Carrier Board V1.1";
-	compatible = "toradex,apalis_imx6q-ixora-v1.1",
-		     "toradex,apalis_imx6q-ixora", "toradex,apalis_imx6q",
+	compatible = "toradex,apalis_imx6q-ixora-v1.1", "toradex,apalis_imx6q",
 		     "fsl,imx6q";
 
-	aliases {
-		i2c0 = &i2c1;
-		i2c1 = &i2c3;
-		i2c2 = &i2c2;
-		rtc0 = &rtc_i2c;
-		rtc1 = &snvs_rtc;
-	};
-
-	chosen {
-		stdout-path = "serial0:115200n8";
-	};
-
-	gpio-keys {
-		compatible = "gpio-keys";
-		pinctrl-names = "default";
-		pinctrl-0 = <&pinctrl_gpio_keys>;
-
-		wakeup {
-			label = "Wake-Up";
-			gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
-			linux,code = <KEY_WAKEUP>;
-			debounce-interval = <10>;
-			wakeup-source;
-		};
-	};
-
-	leds {
-		compatible = "gpio-leds";
-
-		pinctrl-names = "default";
-		pinctrl-0 = <&pinctrl_leds_ixora>;
-
-		led4-green {
-			label = "LED_4_GREEN";
-			gpios = <&gpio1 14 GPIO_ACTIVE_HIGH>;
-		};
 
-		led4-red {
-			label = "LED_4_RED";
-			gpios = <&gpio1 12 GPIO_ACTIVE_HIGH>;
-		};
-
-		led5-green {
-			label = "LED_5_GREEN";
-			gpios = <&gpio2 1 GPIO_ACTIVE_HIGH>;
-		};
-
-		led5-red {
-			label = "LED_5_RED";
-			gpios = <&gpio2 2 GPIO_ACTIVE_HIGH>;
-		};
-	};
 };
 
+/delete-node/ &eeprom;
+/delete-node/ &reg_3v3_vmmc;
+/delete-node/ &reg_can1_supply;
+/delete-node/ &reg_can2_supply;
+
 &can1 {
-	status = "okay";
+	/delete-property/ xceiver-supply;
 };
 
 &can2 {
-	status = "okay";
-};
-
-/* I2C1_SDA/SCL on MXM3 209/211 (e.g. RTC on carrier board) */
-&i2c1 {
-	status = "okay";
-
-	/* M41T0M6 real time clock on carrier board */
-	rtc_i2c: rtc@68 {
-		compatible = "st,m41t0";
-		reg = <0x68>;
-	};
-};
-
-/*
- * I2C3_SDA/SCL (CAM) on MXM3 pin 201/203 (e.g. camera sensor on carrier
- * board)
- */
-&i2c3 {
-	status = "okay";
-};
-
-&pcie {
-	pinctrl-names = "default";
-	pinctrl-0 = <&pinctrl_reset_moci>;
-	/* active-high meaning opposite of regular PERST# active-low polarity */
-	reset-gpio = <&gpio1 28 GPIO_ACTIVE_HIGH>;
-	reset-gpio-active-high;
-	status = "okay";
-};
-
-&pwm1 {
-	status = "okay";
-};
-
-&pwm2 {
-	status = "okay";
-};
-
-&pwm3 {
-	status = "okay";
-};
-
-&pwm4 {
-	status = "okay";
-};
-
-&reg_usb_otg_vbus {
-	status = "okay";
-};
-
-&reg_usb_host_vbus {
-	status = "okay";
-};
-
-&sata {
-	status = "okay";
-};
-
-&sound_spdif {
-	status = "okay";
-};
-
-&spdif {
-	status = "okay";
-};
-
-&uart1 {
-	status = "okay";
-};
-
-&uart2 {
-	status = "okay";
-};
-
-&uart4 {
-	status = "okay";
-};
-
-&uart5 {
-	status = "okay";
-};
-
-&usbh1 {
-	vbus-supply = <&reg_usb_host_vbus>;
-	status = "okay";
-};
-
-&usbotg {
-	vbus-supply = <&reg_usb_otg_vbus>;
-	status = "okay";
+	/delete-property/ xceiver-supply;
 };
 
 /* MMC1 */
 &usdhc1 {
+	/delete-property/ cap-power-off-card;
+	/delete-property/ pinctrl-1;
+	/delete-property/ vmmc-supply;
 	pinctrl-names = "default";
-	pinctrl-0 = <&pinctrl_usdhc1_4bit &pinctrl_mmc_cd>;
-	bus-width = <4>;
-	status = "okay";
-};
-
-&iomuxc {
-	pinctrl_leds_ixora: ledsixoragrp {
-		fsl,pins = <
-			MX6QDL_PAD_SD2_DAT1__GPIO1_IO14 0x1b0b0
-			MX6QDL_PAD_SD2_DAT3__GPIO1_IO12 0x1b0b0
-			MX6QDL_PAD_NANDF_D1__GPIO2_IO01 0x1b0b0
-			MX6QDL_PAD_NANDF_D2__GPIO2_IO02 0x1b0b0
-		>;
-	};
 };
diff --git a/arch/arm/boot/dts/imx6q-apalis-ixora-v1.2.dts b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.2.dts
new file mode 100644
index 000000000000..7770697fde5e
--- /dev/null
+++ b/arch/arm/boot/dts/imx6q-apalis-ixora-v1.2.dts
@@ -0,0 +1,290 @@
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
+/*
+ * Copyright 2014-2022 Toradex
+ * Copyright 2012 Freescale Semiconductor, Inc.
+ * Copyright 2011 Linaro Ltd.
+ */
+
+/dts-v1/;
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/interrupt-controller/irq.h>
+#include "imx6q.dtsi"
+#include "imx6qdl-apalis.dtsi"
+
+/ {
+	model = "Toradex Apalis iMX6Q/D Module on Ixora Carrier Board V1.2";
+	compatible = "toradex,apalis_imx6q-ixora-v1.2", "toradex,apalis_imx6q",
+		     "fsl,imx6q";
+
+	aliases {
+		i2c0 = &i2c1;
+		i2c1 = &i2c3;
+		i2c2 = &i2c2;
+		rtc0 = &rtc_i2c;
+		rtc1 = &snvs_rtc;
+	};
+
+	chosen {
+		stdout-path = "serial0:115200n8";
+	};
+
+	gpio-keys {
+		compatible = "gpio-keys";
+		pinctrl-names = "default";
+		pinctrl-0 = <&pinctrl_gpio_keys>;
+
+		wakeup {
+			debounce-interval = <10>;
+			gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
+			label = "Wake-Up";
+			linux,code = <KEY_WAKEUP>;
+			wakeup-source;
+		};
+	};
+
+	leds {
+		compatible = "gpio-leds";
+
+		pinctrl-names = "default";
+		pinctrl-0 = <&pinctrl_leds_ixora>;
+
+		led4-green {
+			gpios = <&gpio1 14 GPIO_ACTIVE_HIGH>;
+			label = "LED_4_GREEN";
+		};
+
+		led4-red {
+			gpios = <&gpio1 12 GPIO_ACTIVE_HIGH>;
+			label = "LED_4_RED";
+		};
+
+		led5-green {
+			gpios = <&gpio2 1 GPIO_ACTIVE_HIGH>;
+			label = "LED_5_GREEN";
+		};
+
+		led5-red {
+			gpios = <&gpio2 2 GPIO_ACTIVE_HIGH>;
+			label = "LED_5_RED";
+		};
+	};
+
+	reg_3v3_vmmc: regulator-3v3-vmmc {
+		compatible = "regulator-fixed";
+		enable-active-high;
+		gpio = <&gpio2 0 GPIO_ACTIVE_HIGH>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&pinctrl_enable_3v3_vmmc>;
+		regulator-max-microvolt = <3300000>;
+		regulator-min-microvolt = <3300000>;
+		regulator-name = "3v3_vmmc";
+		startup-delay-us = <100>;
+	};
+
+	reg_can1_supply: regulator-can1-supply {
+		compatible = "regulator-fixed";
+		enable-active-high;
+		gpio = <&gpio2 3 GPIO_ACTIVE_HIGH>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&pinctrl_enable_can1_power>;
+		regulator-name = "can1_supply";
+	};
+
+	reg_can2_supply: regulator-can2-supply {
+		compatible = "regulator-fixed";
+		enable-active-high;
+		gpio = <&gpio3 15 GPIO_ACTIVE_HIGH>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&pinctrl_enable_can2_power>;
+		regulator-name = "can2_supply";
+	};
+};
+
+&can1 {
+	xceiver-supply = <&reg_can1_supply>;
+	status = "okay";
+};
+
+&can2 {
+	xceiver-supply = <&reg_can2_supply>;
+	status = "okay";
+};
+
+&gpio1 {
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_uart24_forceoff>;
+
+	/*
+	 * uart-2-4-on-x21-enable-hog enables the UART transceiver for Apalis
+	 * UART2 and UART3. If one wants to disable the transceiver force
+	 * the GPIO to output-low, if one wants to control the transceiver
+	 * from user space delete the hog node.
+	 */
+	uart-2-4-on-x21-enable-hog {
+		gpio-hog;
+		gpios = <11 GPIO_ACTIVE_HIGH>; /* MXM3 180 */
+		output-high;
+	};
+};
+
+/* I2C1_SDA/SCL on MXM3 209/211 (e.g. RTC on carrier board) */
+&i2c1 {
+	status = "okay";
+
+	/* M41T0M6 real time clock on carrier board */
+	rtc_i2c: rtc@68 {
+		compatible = "st,m41t0";
+		reg = <0x68>;
+	};
+
+	eeprom: eeprom@50 {
+		compatible = "atmel,24c02";
+		reg = <0x50>;
+		pagesize = <16>;
+	};
+};
+
+/*
+ * I2C3_SDA/SCL (CAM) on MXM3 pin 201/203 (e.g. camera sensor on carrier
+ * board)
+ */
+&i2c3 {
+	status = "okay";
+};
+
+&pcie {
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_reset_moci>;
+	/* active-high meaning opposite of regular PERST# active-low polarity */
+	reset-gpio = <&gpio1 28 GPIO_ACTIVE_HIGH>;
+	reset-gpio-active-high;
+	status = "okay";
+};
+
+&pwm1 {
+	status = "okay";
+};
+
+&pwm2 {
+	status = "okay";
+};
+
+&pwm3 {
+	status = "okay";
+};
+
+&pwm4 {
+	status = "okay";
+};
+
+&reg_usb_host_vbus {
+	status = "okay";
+};
+
+&reg_usb_otg_vbus {
+	status = "okay";
+};
+
+&sata {
+	status = "okay";
+};
+
+&sound_spdif {
+	status = "okay";
+};
+
+&spdif {
+	status = "okay";
+};
+
+&uart1 {
+	status = "okay";
+};
+
+&uart2 {
+	status = "okay";
+};
+
+&uart4 {
+	status = "okay";
+};
+
+&uart5 {
+	status = "okay";
+};
+
+&usbh1 {
+	vbus-supply = <&reg_usb_host_vbus>;
+	status = "okay";
+};
+
+&usbotg {
+	vbus-supply = <&reg_usb_otg_vbus>;
+	status = "okay";
+};
+
+/* MMC1 */
+&usdhc1 {
+	pinctrl-names = "default", "sleep";
+	pinctrl-0 = <&pinctrl_usdhc1_4bit &pinctrl_mmc_cd>;
+	pinctrl-1 = <&pinctrl_usdhc1_4bit_sleep &pinctrl_mmc_cd_sleep>;
+	bus-width = <4>;
+	cap-power-off-card;
+	vmmc-supply = <&reg_3v3_vmmc>;
+	status = "okay";
+};
+
+&iomuxc {
+	pinctrl_enable_3v3_vmmc: enable3v3vmmcgrp {
+		fsl,pins = <
+			MX6QDL_PAD_NANDF_D0__GPIO2_IO00 0x1b0b0
+		>;
+	};
+
+	pinctrl_enable_can1_power: enablecan1powergrp {
+		fsl,pins = <
+			MX6QDL_PAD_NANDF_D3__GPIO2_IO03 0x1b0b0
+		>;
+	};
+
+	pinctrl_enable_can2_power: enablecan2powergrp {
+		fsl,pins = <
+			MX6QDL_PAD_EIM_DA15__GPIO3_IO15 0x1b0b0
+		>;
+	};
+
+	pinctrl_uart24_forceoff: uart24forceoffgrp {
+		fsl,pins = <
+			MX6QDL_PAD_SD2_CMD__GPIO1_IO11 0x1b0b0
+		>;
+	};
+
+	pinctrl_leds_ixora: ledsixoragrp {
+		fsl,pins = <
+			MX6QDL_PAD_SD2_DAT1__GPIO1_IO14 0x1b0b0
+			MX6QDL_PAD_SD2_DAT3__GPIO1_IO12 0x1b0b0
+			MX6QDL_PAD_NANDF_D1__GPIO2_IO01 0x1b0b0
+			MX6QDL_PAD_NANDF_D2__GPIO2_IO02 0x1b0b0
+		>;
+	};
+
+	pinctrl_mmc_cd_sleep: mmccdslpgrp {
+		fsl,pins = <
+			 /* MMC1 CD */
+			MX6QDL_PAD_DI0_PIN4__GPIO4_IO20 0x0
+		>;
+	};
+
+	pinctrl_usdhc1_4bit_sleep: usdhc1-4bitslpgrp {
+		fsl,pins = <
+			MX6QDL_PAD_SD1_CMD__SD1_CMD     0x3000
+			MX6QDL_PAD_SD1_CLK__SD1_CLK     0x3000
+			MX6QDL_PAD_SD1_DAT0__SD1_DATA0  0x3000
+			MX6QDL_PAD_SD1_DAT1__SD1_DATA1  0x3000
+			MX6QDL_PAD_SD1_DAT2__SD1_DATA2  0x3000
+			MX6QDL_PAD_SD1_DAT3__SD1_DATA3  0x3000
+		>;
+	};
+};
-- 
2.20.1


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

* [PATCH v1 15/17] ARM: dts: imx6q-apalis: backlight pwm: Simplify inverted backlight
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
                   ` (13 preceding siblings ...)
  2022-05-16 11:58 ` [PATCH v1 14/17] ARM: dts: imx6q-apalis: Add support for Toradex Ixora V1.2 carrier boards Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 16/17] ARM: dts: imx6q-apalis: backlight pwm: Adapt brightness steps Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 17/17] ARM: dts: imx6q-apalis: Cleanup Max Krummenacher
  16 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Fabio Estevam, Krzysztof Kozlowski, NXP Linux Team,
	Pengutronix Kernel Team, Rob Herring, Sascha Hauer, Shawn Guo,
	devicetree, linux-arm-kernel, linux-kernel

From: Max Krummenacher <max.krummenacher@toradex.com>

Set #pwm-cells to the default 3 to gain access to the parameter
which allows inverting the PWM signal. This is useful to specify
a backlight which has its highest brightness at 0.

With the change to use the PWM with inverted polarity the PWM signal
is inverted to how it was before this patch.
This changes the meaning of the values in the brightness-levels
property. I.e. the duty-cycle changes from x/255 to (255-x)/255.
Keeping the brightness-levels will then have a big brightness
jump from 0 to 127 duty cycle, the other 6 steps will then be
barely noticeable.

Change the brightness-levels to provide the same brightness-levels
as before.

Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/imx6qdl-apalis.dtsi | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
index 57642aefe349..49669caac8b7 100644
--- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
@@ -6,6 +6,7 @@
  */
 
 #include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/pwm/pwm.h>
 
 / {
 	model = "Toradex Apalis iMX6Q/D Module";
@@ -19,13 +20,13 @@
 
 	backlight: backlight {
 		compatible = "pwm-backlight";
+		brightness-levels = <0 4 8 16 32 64 128 255>;
+		default-brightness-level = <6>;
+		enable-gpios = <&gpio3 13 GPIO_ACTIVE_HIGH>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&pinctrl_gpio_bl_on>;
-		brightness-levels = <0 127 191 223 239 247 251 255>;
-		default-brightness-level = <1>;
-		enable-gpios = <&gpio3 13 GPIO_ACTIVE_HIGH>;
 		power-supply = <&reg_module_3v3>;
-		pwms = <&pwm4 0 5000000>;
+		pwms = <&pwm4 0 5000000 PWM_POLARITY_INVERTED>;
 		status = "disabled";
 	};
 
@@ -761,7 +762,6 @@
 };
 
 &pwm4 {
-	#pwm-cells = <2>;
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pwm4>;
 	status = "disabled";
-- 
2.20.1


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

* [PATCH v1 16/17] ARM: dts: imx6q-apalis: backlight pwm: Adapt brightness steps
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
                   ` (14 preceding siblings ...)
  2022-05-16 11:58 ` [PATCH v1 15/17] ARM: dts: imx6q-apalis: backlight pwm: Simplify inverted backlight Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  2022-05-16 11:58 ` [PATCH v1 17/17] ARM: dts: imx6q-apalis: Cleanup Max Krummenacher
  16 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Fabio Estevam, Krzysztof Kozlowski, NXP Linux Team,
	Pengutronix Kernel Team, Rob Herring, Sascha Hauer, Shawn Guo,
	devicetree, linux-arm-kernel, linux-kernel

From: Max Krummenacher <max.krummenacher@toradex.com>

Adapt the brightness steps as the backlight doesn't light up
for very low duty cycles.

Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---

 arch/arm/boot/dts/imx6qdl-apalis.dtsi | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
index 49669caac8b7..62d9d907432c 100644
--- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
@@ -20,8 +20,8 @@
 
 	backlight: backlight {
 		compatible = "pwm-backlight";
-		brightness-levels = <0 4 8 16 32 64 128 255>;
-		default-brightness-level = <6>;
+		brightness-levels = <0 45 63 88 119 158 203 255>;
+		default-brightness-level = <4>;
 		enable-gpios = <&gpio3 13 GPIO_ACTIVE_HIGH>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&pinctrl_gpio_bl_on>;
-- 
2.20.1


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

* [PATCH v1 17/17] ARM: dts: imx6q-apalis: Cleanup
  2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
                   ` (15 preceding siblings ...)
  2022-05-16 11:58 ` [PATCH v1 16/17] ARM: dts: imx6q-apalis: backlight pwm: Adapt brightness steps Max Krummenacher
@ 2022-05-16 11:58 ` Max Krummenacher
  16 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-16 11:58 UTC (permalink / raw)
  To: max.krummenacher
  Cc: Fabio Estevam, Krzysztof Kozlowski, NXP Linux Team,
	Pengutronix Kernel Team, Rob Herring, Sascha Hauer, Shawn Guo,
	devicetree, linux-arm-kernel, linux-kernel

From: Max Krummenacher <max.krummenacher@toradex.com>

- Sort nodes and properties alphabetical
- End all pinctrl node names in grp and avoid using dashes
- Change the pmic's node name to pmic@8 per binding requirement
- Add sound-dai-cells to the codec node per binding requirement

Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>

---

 arch/arm/boot/dts/imx6q-apalis-eval.dts  |  24 +--
 arch/arm/boot/dts/imx6q-apalis-ixora.dts |  19 +-
 arch/arm/boot/dts/imx6qdl-apalis.dtsi    | 221 ++++++++++++-----------
 3 files changed, 132 insertions(+), 132 deletions(-)

diff --git a/arch/arm/boot/dts/imx6q-apalis-eval.dts b/arch/arm/boot/dts/imx6q-apalis-eval.dts
index 5c4d9a4ec586..b3e169239a19 100644
--- a/arch/arm/boot/dts/imx6q-apalis-eval.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-eval.dts
@@ -36,31 +36,31 @@
 		pinctrl-0 = <&pinctrl_gpio_keys>;
 
 		wakeup {
-			label = "Wake-Up";
+			debounce-interval = <10>;
 			gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
+			label = "Wake-Up";
 			linux,code = <KEY_WAKEUP>;
-			debounce-interval = <10>;
 			wakeup-source;
 		};
 	};
 
 	reg_pcie_switch: regulator-pcie-switch {
 		compatible = "regulator-fixed";
-		regulator-name = "pcie_switch";
-		regulator-min-microvolt = <1800000>;
-		regulator-max-microvolt = <1800000>;
+		enable-active-high;
 		gpio = <&gpio1 2 GPIO_ACTIVE_HIGH>;
+		regulator-max-microvolt = <1800000>;
+		regulator-min-microvolt = <1800000>;
+		regulator-name = "pcie_switch";
 		startup-delay-us = <100000>;
-		enable-active-high;
 		status = "okay";
 	};
 
 	reg_3v3_sw: regulator-3v3-sw {
 		compatible = "regulator-fixed";
-		regulator-name = "3.3V_SW";
-		regulator-min-microvolt = <3300000>;
-		regulator-max-microvolt = <3300000>;
 		regulator-always-on;
+		regulator-max-microvolt = <3300000>;
+		regulator-min-microvolt = <3300000>;
+		regulator-name = "3.3V_SW";
 	};
 };
 
@@ -124,11 +124,11 @@
 	status = "okay";
 };
 
-&reg_usb_otg_vbus {
+&reg_usb_host_vbus {
 	status = "okay";
 };
 
-&reg_usb_host_vbus {
+&reg_usb_otg_vbus {
 	status = "okay";
 };
 
@@ -177,8 +177,8 @@
 
 /* SD1 */
 &usdhc2 {
+	cd-gpios = <&gpio6 14 GPIO_ACTIVE_LOW>;
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_usdhc2 &pinctrl_sd_cd>;
-	cd-gpios = <&gpio6 14 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
diff --git a/arch/arm/boot/dts/imx6q-apalis-ixora.dts b/arch/arm/boot/dts/imx6q-apalis-ixora.dts
index 97ddf4621bdf..8a12585ab062 100644
--- a/arch/arm/boot/dts/imx6q-apalis-ixora.dts
+++ b/arch/arm/boot/dts/imx6q-apalis-ixora.dts
@@ -36,38 +36,37 @@
 		pinctrl-0 = <&pinctrl_gpio_keys>;
 
 		wakeup {
-			label = "Wake-Up";
+			debounce-interval = <10>;
 			gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
+			label = "Wake-Up";
 			linux,code = <KEY_WAKEUP>;
-			debounce-interval = <10>;
 			wakeup-source;
 		};
 	};
 
 	leds {
 		compatible = "gpio-leds";
-
 		pinctrl-names = "default";
 		pinctrl-0 = <&pinctrl_leds_ixora>;
 
 		led4-green {
-			label = "LED_4_GREEN";
 			gpios = <&gpio1 17 GPIO_ACTIVE_HIGH>;
+			label = "LED_4_GREEN";
 		};
 
 		led4-red {
-			label = "LED_4_RED";
 			gpios = <&gpio1 21 GPIO_ACTIVE_HIGH>;
+			label = "LED_4_RED";
 		};
 
 		led5-green {
-			label = "LED_5_GREEN";
 			gpios = <&gpio2 1 GPIO_ACTIVE_HIGH>;
+			label = "LED_5_GREEN";
 		};
 
 		led5-red {
-			label = "LED_5_RED";
 			gpios = <&gpio2 2 GPIO_ACTIVE_HIGH>;
+			label = "LED_5_RED";
 		};
 	};
 };
@@ -129,11 +128,11 @@
 	status = "okay";
 };
 
-&reg_usb_otg_vbus {
+&reg_usb_host_vbus {
 	status = "okay";
 };
 
-&reg_usb_host_vbus {
+&reg_usb_otg_vbus {
 	status = "okay";
 };
 
@@ -177,9 +176,9 @@
 
 /* SD1 */
 &usdhc2 {
+	cd-gpios = <&gpio6 14 GPIO_ACTIVE_LOW>;
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_usdhc2 &pinctrl_sd_cd>;
-	cd-gpios = <&gpio6 14 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
index 62d9d907432c..7a1feaa5bc23 100644
--- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
@@ -89,18 +89,18 @@
 
 	reg_module_3v3: regulator-module-3v3 {
 		compatible = "regulator-fixed";
-		regulator-name = "+V3.3";
-		regulator-min-microvolt = <3300000>;
-		regulator-max-microvolt = <3300000>;
 		regulator-always-on;
+		regulator-max-microvolt = <3300000>;
+		regulator-min-microvolt = <3300000>;
+		regulator-name = "+V3.3";
 	};
 
 	reg_module_3v3_audio: regulator-module-3v3-audio {
 		compatible = "regulator-fixed";
-		regulator-name = "+V3.3_AUDIO";
-		regulator-min-microvolt = <3300000>;
-		regulator-max-microvolt = <3300000>;
 		regulator-always-on;
+		regulator-max-microvolt = <3300000>;
+		regulator-min-microvolt = <3300000>;
+		regulator-name = "+V3.3_AUDIO";
 	};
 
 	reg_ov5640_1v8_d_o_vdd: regulator-ov5640-1v8-d-o-vdd {
@@ -125,63 +125,63 @@
 
 	reg_usb_otg_vbus: regulator-usb-otg-vbus {
 		compatible = "regulator-fixed";
+		enable-active-high;
+		gpio = <&gpio3 22 GPIO_ACTIVE_HIGH>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&pinctrl_regulator_usbotg_pwr>;
-		regulator-name = "usb_otg_vbus";
-		regulator-min-microvolt = <5000000>;
 		regulator-max-microvolt = <5000000>;
-		gpio = <&gpio3 22 GPIO_ACTIVE_HIGH>;
-		enable-active-high;
+		regulator-min-microvolt = <5000000>;
+		regulator-name = "usb_otg_vbus";
 		status = "disabled";
 	};
 
 	/* on module USB hub */
 	reg_usb_host_vbus_hub: regulator-usb-host-vbus-hub {
 		compatible = "regulator-fixed";
+		enable-active-high;
+		gpio = <&gpio3 28 GPIO_ACTIVE_HIGH>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&pinctrl_regulator_usbhub_pwr>;
-		regulator-name = "usb_host_vbus_hub";
-		regulator-min-microvolt = <5000000>;
 		regulator-max-microvolt = <5000000>;
-		gpio = <&gpio3 28 GPIO_ACTIVE_HIGH>;
+		regulator-min-microvolt = <5000000>;
+		regulator-name = "usb_host_vbus_hub";
 		startup-delay-us = <2000>;
-		enable-active-high;
 		status = "okay";
 	};
 
 	reg_usb_host_vbus: regulator-usb-host-vbus {
 		compatible = "regulator-fixed";
+		enable-active-high;
+		gpio =  <&gpio1 0 GPIO_ACTIVE_HIGH>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&pinctrl_regulator_usbh_pwr>;
-		regulator-name = "usb_host_vbus";
-		regulator-min-microvolt = <5000000>;
 		regulator-max-microvolt = <5000000>;
-		gpio =  <&gpio1 0 GPIO_ACTIVE_HIGH>;
-		enable-active-high;
+		regulator-min-microvolt = <5000000>;
+		regulator-name = "usb_host_vbus";
 		vin-supply = <&reg_usb_host_vbus_hub>;
 		status = "disabled";
 	};
 
 	sound {
 		compatible = "fsl,imx-audio-sgtl5000";
-		model = "imx6q-apalis-sgtl5000";
-		ssi-controller = <&ssi1>;
 		audio-codec = <&codec>;
 		audio-routing =
 			"LINE_IN", "Line In Jack",
 			"MIC_IN", "Mic Jack",
 			"Mic Jack", "Mic Bias",
 			"Headphone Jack", "HP_OUT";
-		mux-int-port = <1>;
+		model = "imx6q-apalis-sgtl5000";
 		mux-ext-port = <4>;
+		mux-int-port = <1>;
+		ssi-controller = <&ssi1>;
 	};
 
 	sound_spdif: sound-spdif {
 		compatible = "fsl,imx-audio-spdif";
-		model = "imx-spdif";
 		spdif-controller = <&spdif>;
 		spdif-in;
 		spdif-out;
+		model = "imx-spdif";
 		status = "disabled";
 	};
 };
@@ -495,104 +495,105 @@
 	sda-gpios = <&gpio4 13 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
 	status = "okay";
 
-	pmic: pfuze100@8 {
+	pmic: pmic@8 {
 		compatible = "fsl,pfuze100";
 		fsl,pmic-stby-poweroff;
 		reg = <0x08>;
 
 		regulators {
 			sw1a_reg: sw1ab {
-				regulator-min-microvolt = <300000>;
-				regulator-max-microvolt = <1875000>;
-				regulator-boot-on;
 				regulator-always-on;
+				regulator-boot-on;
+				regulator-max-microvolt = <1875000>;
+				regulator-min-microvolt = <300000>;
 				regulator-ramp-delay = <6250>;
 			};
 
 			sw1c_reg: sw1c {
-				regulator-min-microvolt = <300000>;
-				regulator-max-microvolt = <1875000>;
-				regulator-boot-on;
 				regulator-always-on;
+				regulator-boot-on;
+				regulator-max-microvolt = <1875000>;
+				regulator-min-microvolt = <300000>;
 				regulator-ramp-delay = <6250>;
 			};
 
 			sw3a_reg: sw3a {
-				regulator-min-microvolt = <400000>;
-				regulator-max-microvolt = <1975000>;
-				regulator-boot-on;
 				regulator-always-on;
+				regulator-boot-on;
+				regulator-max-microvolt = <1975000>;
+				regulator-min-microvolt = <400000>;
 			};
 
 			swbst_reg: swbst {
-				regulator-min-microvolt = <5000000>;
-				regulator-max-microvolt = <5150000>;
-				regulator-boot-on;
 				regulator-always-on;
+				regulator-boot-on;
+				regulator-max-microvolt = <5150000>;
+				regulator-min-microvolt = <5000000>;
 			};
 
 			snvs_reg: vsnvs {
-				regulator-min-microvolt = <1000000>;
-				regulator-max-microvolt = <3000000>;
-				regulator-boot-on;
 				regulator-always-on;
+				regulator-boot-on;
+				regulator-max-microvolt = <3000000>;
+				regulator-min-microvolt = <1000000>;
 			};
 
 			vref_reg: vrefddr {
-				regulator-boot-on;
 				regulator-always-on;
+				regulator-boot-on;
 			};
 
 			vgen1_reg: vgen1 {
-				regulator-min-microvolt = <800000>;
-				regulator-max-microvolt = <1550000>;
-				regulator-boot-on;
 				regulator-always-on;
+				regulator-boot-on;
+				regulator-max-microvolt = <1550000>;
+				regulator-min-microvolt = <800000>;
 			};
 
 			vgen2_reg: vgen2 {
-				regulator-min-microvolt = <800000>;
-				regulator-max-microvolt = <1550000>;
-				regulator-boot-on;
 				regulator-always-on;
+				regulator-boot-on;
+				regulator-max-microvolt = <1550000>;
+				regulator-min-microvolt = <800000>;
 			};
 
 			vgen3_reg: vgen3 {
-				regulator-min-microvolt = <1800000>;
-				regulator-max-microvolt = <3300000>;
-				regulator-boot-on;
 				regulator-always-on;
+				regulator-boot-on;
+				regulator-max-microvolt = <3300000>;
+				regulator-min-microvolt = <1800000>;
 			};
 
 			vgen4_reg: vgen4 {
-				regulator-min-microvolt = <1800000>;
-				regulator-max-microvolt = <1800000>;
-				regulator-boot-on;
 				regulator-always-on;
+				regulator-boot-on;
+				regulator-max-microvolt = <1800000>;
+				regulator-min-microvolt = <1800000>;
 			};
 
 			vgen5_reg: vgen5 {
-				regulator-min-microvolt = <1800000>;
-				regulator-max-microvolt = <3300000>;
-				regulator-boot-on;
 				regulator-always-on;
+				regulator-boot-on;
+				regulator-max-microvolt = <3300000>;
+				regulator-min-microvolt = <1800000>;
 			};
 
 			vgen6_reg: vgen6 {
-				regulator-min-microvolt = <1800000>;
-				regulator-max-microvolt = <3300000>;
-				regulator-boot-on;
 				regulator-always-on;
+				regulator-boot-on;
+				regulator-max-microvolt = <3300000>;
+				regulator-min-microvolt = <1800000>;
 			};
 		};
 	};
 
 	codec: sgtl5000@a {
 		compatible = "fsl,sgtl5000";
-		reg = <0x0a>;
+		#sound-dai-cells = <0>;
+		clocks = <&clks IMX6QDL_CLK_CKO>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&pinctrl_sgtl5000>;
-		clocks = <&clks IMX6QDL_CLK_CKO>;
+		reg = <0x0a>;
 		VDDA-supply = <&reg_module_3v3_audio>;
 		VDDIO-supply = <&reg_module_3v3>;
 		VDDD-supply = <&vgen4_reg>;
@@ -601,15 +602,15 @@
 	/* STMPE811 touch screen controller */
 	stmpe811@41 {
 		compatible = "st,stmpe811";
-		pinctrl-names = "default";
-		pinctrl-0 = <&pinctrl_touch_int>;
-		reg = <0x41>;
+		blocks = <0x5>;
+		id = <0>;
 		interrupts = <10 IRQ_TYPE_LEVEL_LOW>;
-		interrupt-parent = <&gpio4>;
 		interrupt-controller;
-		id = <0>;
-		blocks = <0x5>;
+		interrupt-parent = <&gpio4>;
 		irq-trigger = <0x1>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&pinctrl_touch_int>;
+		reg = <0x41>;
 		/* 3.25 MHz ADC clock speed */
 		st,adc-freq = <1>;
 		/* 12-bit ADC */
@@ -639,9 +640,9 @@
 
 		stmpe_adc: stmpe_adc {
 			compatible = "st,stmpe-adc";
+			#io-channel-cells = <1>;
 			/* forbid to use ADC channels 3-0 (touch) */
 			st,norequest-mask = <0x0F>;
-			#io-channel-cells = <1>;
 		};
 	};
 };
@@ -661,9 +662,9 @@
 
 	adv_7280: adv7280@21 {
 		compatible = "adi,adv7280";
-		reg = <0x21>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&pinctrl_ipu1_csi0>;
+		reg = <0x21>;
 		status = "disabled";
 
 		port {
@@ -679,8 +680,8 @@
 		AVDD-supply = <&reg_ov5640_2v8_a_vdd>;
 		DOVDD-supply = <&reg_ov5640_1v8_d_o_vdd>;
 		DVDD-supply = <&reg_ov5640_1v8_d_o_vdd>;
-		clocks = <&clks IMX6QDL_CLK_CKO2>;
 		clock-names = "xclk";
+		clocks = <&clks IMX6QDL_CLK_CKO2>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&pinctrl_cam_mclk>;
 		/* These GPIOs are muxed with the iomuxc node */
@@ -778,73 +779,73 @@
 };
 
 &uart1 {
+	fsl,dte-mode;
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_uart1_dte &pinctrl_uart1_ctrl>;
-	fsl,dte-mode;
 	uart-has-rtscts;
 	status = "disabled";
 };
 
 &uart2 {
+	fsl,dte-mode;
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_uart2_dte>;
-	fsl,dte-mode;
 	uart-has-rtscts;
 	status = "disabled";
 };
 
 &uart4 {
+	fsl,dte-mode;
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_uart4_dte>;
-	fsl,dte-mode;
 	status = "disabled";
 };
 
 &uart5 {
+	fsl,dte-mode;
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_uart5_dte>;
-	fsl,dte-mode;
 	status = "disabled";
 };
 
 &usbotg {
+	disable-over-current;
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_usbotg>;
-	disable-over-current;
 	status = "disabled";
 };
 
 /* MMC1 */
 &usdhc1 {
-	pinctrl-names = "default";
-	pinctrl-0 = <&pinctrl_usdhc1_4bit &pinctrl_usdhc1_8bit &pinctrl_mmc_cd>;
-	cd-gpios = <&gpio4 20 GPIO_ACTIVE_LOW>;
-	vqmmc-supply = <&reg_module_3v3>;
 	bus-width = <8>;
+	cd-gpios = <&gpio4 20 GPIO_ACTIVE_LOW>;
 	disable-wp;
 	no-1-8-v;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_usdhc1_4bit &pinctrl_usdhc1_8bit &pinctrl_mmc_cd>;
+	vqmmc-supply = <&reg_module_3v3>;
 	status = "disabled";
 };
 
 /* SD1 */
 &usdhc2 {
-	pinctrl-names = "default";
-	pinctrl-0 = <&pinctrl_usdhc2>;
-	vqmmc-supply = <&reg_module_3v3>;
 	bus-width = <4>;
 	disable-wp;
 	no-1-8-v;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_usdhc2>;
+	vqmmc-supply = <&reg_module_3v3>;
 	status = "disabled";
 };
 
 /* eMMC */
 &usdhc3 {
-	pinctrl-names = "default";
-	pinctrl-0 = <&pinctrl_usdhc3>;
-	vqmmc-supply = <&reg_module_3v3>;
 	bus-width = <8>;
 	no-1-8-v;
 	non-removable;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_usdhc3>;
+	vqmmc-supply = <&reg_module_3v3>;
 	status = "okay";
 };
 
@@ -861,49 +862,49 @@
 		     &pinctrl_apalis_gpio7 &pinctrl_apalis_gpio8
 		    >;
 
-	pinctrl_apalis_gpio1: gpio2io04grp {
+	pinctrl_apalis_gpio1: apalisgpio1grp {
 		fsl,pins = <
 			MX6QDL_PAD_NANDF_D4__GPIO2_IO04 0x130b0
 		>;
 	};
 
-	pinctrl_apalis_gpio2: gpio2io05grp {
+	pinctrl_apalis_gpio2: apalisgpio2grp {
 		fsl,pins = <
 			MX6QDL_PAD_NANDF_D5__GPIO2_IO05 0x130b0
 		>;
 	};
 
-	pinctrl_apalis_gpio3: gpio2io06grp {
+	pinctrl_apalis_gpio3: apalisgpio3grp {
 		fsl,pins = <
 			MX6QDL_PAD_NANDF_D6__GPIO2_IO06 0x130b0
 		>;
 	};
 
-	pinctrl_apalis_gpio4: gpio2io07grp {
+	pinctrl_apalis_gpio4: apalisgpio4grp {
 		fsl,pins = <
 			MX6QDL_PAD_NANDF_D7__GPIO2_IO07 0x130b0
 		>;
 	};
 
-	pinctrl_apalis_gpio5: gpio6io10grp {
+	pinctrl_apalis_gpio5: apalisgpio5grp {
 		fsl,pins = <
 			MX6QDL_PAD_NANDF_RB0__GPIO6_IO10 0x130b0
 		>;
 	};
 
-	pinctrl_apalis_gpio6: gpio6io09grp {
+	pinctrl_apalis_gpio6: apalisgpio6grp {
 		fsl,pins = <
 			MX6QDL_PAD_NANDF_WP_B__GPIO6_IO09 0x130b0
 		>;
 	};
 
-	pinctrl_apalis_gpio7: gpio1io02grp {
+	pinctrl_apalis_gpio7: apalisgpio7grp {
 		fsl,pins = <
 			MX6QDL_PAD_GPIO_2__GPIO1_IO02 0x130b0
 		>;
 	};
 
-	pinctrl_apalis_gpio8: gpio1io06grp {
+	pinctrl_apalis_gpio8: apalisgpio8grp {
 		fsl,pins = <
 			MX6QDL_PAD_GPIO_6__GPIO1_IO06 0x130b0
 		>;
@@ -996,7 +997,7 @@
 		>;
 	};
 
-	pinctrl_gpio_bl_on: gpioblon {
+	pinctrl_gpio_bl_on: gpioblongrp {
 		fsl,pins = <
 			MX6QDL_PAD_EIM_DA13__GPIO3_IO13 0x1b0b0
 		>;
@@ -1141,7 +1142,7 @@
 		>;
 	};
 
-	pinctrl_mmc_cd: gpiommccdgrp {
+	pinctrl_mmc_cd: mmccdgrp {
 		fsl,pins = <
 			 /* MMC1 CD */
 			MX6QDL_PAD_DI0_PIN4__GPIO4_IO20 0x000b0
@@ -1172,35 +1173,35 @@
 		>;
 	};
 
-	pinctrl_regulator_usbh_pwr: gpioregusbhpwrgrp {
+	pinctrl_regulator_usbh_pwr: regusbhpwrgrp {
 		fsl,pins = <
 			/* USBH_EN */
 			MX6QDL_PAD_GPIO_0__GPIO1_IO00 0x0f058
 		>;
 	};
 
-	pinctrl_regulator_usbhub_pwr: gpioregusbhubpwrgrp {
+	pinctrl_regulator_usbhub_pwr: regusbhubpwrgrp {
 		fsl,pins = <
 			/* USBH_HUB_EN */
 			MX6QDL_PAD_EIM_D28__GPIO3_IO28 0x0f058
 		>;
 	};
 
-	pinctrl_regulator_usbotg_pwr: gpioregusbotgpwrgrp {
+	pinctrl_regulator_usbotg_pwr: regusbotgpwrgrp {
 		fsl,pins = <
 			/* USBO1 power en */
 			MX6QDL_PAD_EIM_D22__GPIO3_IO22 0x0f058
 		>;
 	};
 
-	pinctrl_reset_moci: gpioresetmocigrp {
+	pinctrl_reset_moci: resetmocigrp {
 		fsl,pins = <
 			/* RESET_MOCI control */
 			MX6QDL_PAD_ENET_TX_EN__GPIO1_IO28 0x0f058
 		>;
 	};
 
-	pinctrl_sd_cd: gpiosdcdgrp {
+	pinctrl_sd_cd: sdcdgrp {
 		fsl,pins = <
 			/* SD1 CD */
 			MX6QDL_PAD_NANDF_CS1__GPIO6_IO14 0x000b0
@@ -1220,13 +1221,22 @@
 		>;
 	};
 
-	pinctrl_touch_int: gpiotouchintgrp {
+	pinctrl_touch_int: touchintgrp {
 		fsl,pins = <
 			/* STMPE811 interrupt */
 			MX6QDL_PAD_KEY_COL2__GPIO4_IO10 0x1b0b0
 		>;
 	};
 
+	/* Additional DTR, DSR, DCD */
+	pinctrl_uart1_ctrl: uart1ctrlgrp {
+		fsl,pins = <
+			MX6QDL_PAD_EIM_D23__UART1_DCD_B 0x1b0b0
+			MX6QDL_PAD_EIM_D24__UART1_DTR_B 0x1b0b0
+			MX6QDL_PAD_EIM_D25__UART1_DSR_B 0x1b0b0
+		>;
+	};
+
 	pinctrl_uart1_dce: uart1dcegrp {
 		fsl,pins = <
 			MX6QDL_PAD_CSI0_DAT10__UART1_TX_DATA 0x1b0b1
@@ -1244,15 +1254,6 @@
 		>;
 	};
 
-	/* Additional DTR, DSR, DCD */
-	pinctrl_uart1_ctrl: uart1ctrlgrp {
-		fsl,pins = <
-			MX6QDL_PAD_EIM_D23__UART1_DCD_B 0x1b0b0
-			MX6QDL_PAD_EIM_D24__UART1_DTR_B 0x1b0b0
-			MX6QDL_PAD_EIM_D25__UART1_DSR_B 0x1b0b0
-		>;
-	};
-
 	pinctrl_uart2_dce: uart2dcegrp {
 		fsl,pins = <
 			MX6QDL_PAD_SD4_DAT4__UART2_RX_DATA	0x1b0b1
@@ -1306,7 +1307,7 @@
 		>;
 	};
 
-	pinctrl_usdhc1_4bit: usdhc1grp_4bit {
+	pinctrl_usdhc1_4bit: usdhc1-4bitgrp {
 		fsl,pins = <
 			MX6QDL_PAD_SD1_CMD__SD1_CMD    0x17071
 			MX6QDL_PAD_SD1_CLK__SD1_CLK    0x10071
@@ -1317,7 +1318,7 @@
 		>;
 	};
 
-	pinctrl_usdhc1_8bit: usdhc1grp_8bit {
+	pinctrl_usdhc1_8bit: usdhc1-8bitgrp {
 		fsl,pins = <
 			MX6QDL_PAD_NANDF_D0__SD1_DATA4 0x17071
 			MX6QDL_PAD_NANDF_D1__SD1_DATA5 0x17071
-- 
2.20.1


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

* Re: [PATCH v1 11/17] ARM: dts: imx6q-apalis: Add ov5640 mipi csi camera
  2022-05-16 11:58 ` [PATCH v1 11/17] ARM: dts: imx6q-apalis: Add ov5640 mipi csi camera Max Krummenacher
@ 2022-05-16 12:08   ` Fabio Estevam
  2022-05-18 14:21     ` Max Krummenacher
  2022-05-17 18:28   ` Fabio Estevam
  1 sibling, 1 reply; 32+ messages in thread
From: Fabio Estevam @ 2022-05-16 12:08 UTC (permalink / raw)
  To: Max Krummenacher
  Cc: Max Krummenacher, Oleksandr Suvorov, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE,
	linux-kernel

Hi Max,

On Mon, May 16, 2022 at 8:59 AM Max Krummenacher <max.oss.09@gmail.com> wrote:
>
> From: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
>
> The Apalis iMX6 modules allow connecting a mipi-csi video input.
> Add support for our OV5640 camera module but have it disabled.
> This allows to enable it in an overlay per the current system
> configuration.
>
> Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
> ---
>
>  arch/arm/boot/dts/imx6qdl-apalis.dtsi | 67 ++++++++++++++++++++++++++-
>  1 file changed, 66 insertions(+), 1 deletion(-)
>
> diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
> index 506d040ea37a..0d1004eede62 100644
> --- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
> +++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
> @@ -29,6 +29,12 @@
>                 status = "disabled";
>         };
>
> +       clk_ov5640_osc: clk_ov5640_osc_int {

Node names should have "-", not "_"

clk_ov5640_osc: clk-ov5640-osc

Also, no need for the _int suffix.

Just curious: is ov5640 mipi support functional?

I recalled that I had issues in getting Gstreamer pipeline to capture
from the ov5640 mipi.

There were some errors related to LP-11 during the start of the capture.

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

* Re: [PATCH v1 12/17] ARM: dts: imx6q-apalis: Add adv7280 video input
  2022-05-16 11:58 ` [PATCH v1 12/17] ARM: dts: imx6q-apalis: Add adv7280 video input Max Krummenacher
@ 2022-05-16 12:10   ` Fabio Estevam
  2022-05-18 14:07     ` Max Krummenacher
  0 siblings, 1 reply; 32+ messages in thread
From: Fabio Estevam @ 2022-05-16 12:10 UTC (permalink / raw)
  To: Max Krummenacher
  Cc: Max Krummenacher, Oleksandr Suvorov, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE,
	linux-kernel

Hi Max,

On Mon, May 16, 2022 at 8:59 AM Max Krummenacher <max.oss.09@gmail.com> wrote:

> +       adv_7280: adv7280@21 {
> +               compatible = "adi,adv7280";
> +               reg = <0x21>;
> +               pinctrl-names = "default";
> +               pinctrl-0 = <&pinctrl_ipu1_csi0>;

I suggest passing "adv,force-bt656-4" property as this fixes sync problems.

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

* Re: [PATCH v1 02/17] Revert "ARM: dts: imx6qdl-apalis: Avoid underscore in node name"
  2022-05-16 11:58 ` [PATCH v1 02/17] Revert "ARM: dts: imx6qdl-apalis: Avoid underscore in node name" Max Krummenacher
@ 2022-05-16 12:49   ` Ahmad Fatoum
  2022-05-16 14:53     ` Francesco Dolcini
  2022-05-18 19:01   ` Rob Herring
  1 sibling, 1 reply; 32+ messages in thread
From: Ahmad Fatoum @ 2022-05-16 12:49 UTC (permalink / raw)
  To: Max Krummenacher, max.krummenacher
  Cc: devicetree, Shawn Guo, Sascha Hauer, linux-kernel, Rob Herring,
	NXP Linux Team, Pengutronix Kernel Team, Krzysztof Kozlowski,
	Fabio Estevam, linux-arm-kernel

On 16.05.22 13:58, Max Krummenacher wrote:
> From: Max Krummenacher <max.krummenacher@toradex.com>
> 
> The STMPE MFD device binding requires the child node to have a fixed
> name, i.e. with '_', not '-'. Otherwise the stmpe_adc, stmpe_touchscreen
> drivers will not be probed.

IMO, the Linux driver should be fixed and the requirement to use a fixed
node name be dropped from the binding. The driver itself already probes
by compatible, the node name seems only to be used by the MFD driver to
detect which functions to enable. It could do the same by checking for
compatibles. Otherwise you invite a game of cat and mouse, where in
future, this is changed back again reintroducing the regression..
 
> Fixes: 56086b5e804f ("ARM: dts: imx6qdl-apalis: Avoid underscore in node name")
> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>

Anyway, as a fix, this looks ok for now:

Reviewed-by: Ahmad Fatoum <a.fatoum@pengutronix.de>

Cheers,
Ahmad

> ---
> 
>  arch/arm/boot/dts/imx6qdl-apalis.dtsi | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
> index bd763bae596b..da919d0544a8 100644
> --- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
> +++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
> @@ -315,7 +315,7 @@
>  		/* ADC conversion time: 80 clocks */
>  		st,sample-time = <4>;
>  
> -		stmpe_touchscreen: stmpe-touchscreen {
> +		stmpe_touchscreen: stmpe_touchscreen {
>  			compatible = "st,stmpe-ts";
>  			/* 8 sample average control */
>  			st,ave-ctrl = <3>;
> @@ -332,7 +332,7 @@
>  			st,touch-det-delay = <5>;
>  		};
>  
> -		stmpe_adc: stmpe-adc {
> +		stmpe_adc: stmpe_adc {
>  			compatible = "st,stmpe-adc";
>  			/* forbid to use ADC channels 3-0 (touch) */
>  			st,norequest-mask = <0x0F>;


-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

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

* Re: [PATCH v1 02/17] Revert "ARM: dts: imx6qdl-apalis: Avoid underscore in node name"
  2022-05-16 12:49   ` Ahmad Fatoum
@ 2022-05-16 14:53     ` Francesco Dolcini
  2022-05-16 15:07       ` Ahmad Fatoum
  0 siblings, 1 reply; 32+ messages in thread
From: Francesco Dolcini @ 2022-05-16 14:53 UTC (permalink / raw)
  To: Ahmad Fatoum
  Cc: Max Krummenacher, max.krummenacher, devicetree, Shawn Guo,
	Sascha Hauer, linux-kernel, Rob Herring, NXP Linux Team,
	Pengutronix Kernel Team, Krzysztof Kozlowski, Fabio Estevam,
	linux-arm-kernel

On Mon, May 16, 2022 at 02:49:12PM +0200, Ahmad Fatoum wrote:
> On 16.05.22 13:58, Max Krummenacher wrote:
> > From: Max Krummenacher <max.krummenacher@toradex.com>
> > 
> > The STMPE MFD device binding requires the child node to have a fixed
> > name, i.e. with '_', not '-'. Otherwise the stmpe_adc, stmpe_touchscreen
> > drivers will not be probed.
> 
> IMO, the Linux driver should be fixed and the requirement to use a fixed
> node name be dropped from the binding. The driver itself already probes
> by compatible, the node name seems only to be used by the MFD driver to
> detect which functions to enable. It could do the same by checking for
> compatibles. Otherwise you invite a game of cat and mouse, where in
> future, this is changed back again reintroducing the regression..

How would you handle in general such kind of change? Would you keep the
driver probing for both the old name with the `_` and the compatible or
you just break the compatibility?

Francesco


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

* Re: [PATCH v1 02/17] Revert "ARM: dts: imx6qdl-apalis: Avoid underscore in node name"
  2022-05-16 14:53     ` Francesco Dolcini
@ 2022-05-16 15:07       ` Ahmad Fatoum
  0 siblings, 0 replies; 32+ messages in thread
From: Ahmad Fatoum @ 2022-05-16 15:07 UTC (permalink / raw)
  To: Francesco Dolcini
  Cc: Max Krummenacher, max.krummenacher, devicetree, Shawn Guo,
	Sascha Hauer, linux-kernel, Rob Herring, NXP Linux Team,
	Pengutronix Kernel Team, Krzysztof Kozlowski, Fabio Estevam,
	linux-arm-kernel

Hello Francesco,

On 16.05.22 16:53, Francesco Dolcini wrote:
> On Mon, May 16, 2022 at 02:49:12PM +0200, Ahmad Fatoum wrote:
>> On 16.05.22 13:58, Max Krummenacher wrote:
>>> From: Max Krummenacher <max.krummenacher@toradex.com>
>>>
>>> The STMPE MFD device binding requires the child node to have a fixed
>>> name, i.e. with '_', not '-'. Otherwise the stmpe_adc, stmpe_touchscreen
>>> drivers will not be probed.
>>
>> IMO, the Linux driver should be fixed and the requirement to use a fixed
>> node name be dropped from the binding. The driver itself already probes
>> by compatible, the node name seems only to be used by the MFD driver to
>> detect which functions to enable. It could do the same by checking for
>> compatibles. Otherwise you invite a game of cat and mouse, where in
>> future, this is changed back again reintroducing the regression..
> 
> How would you handle in general such kind of change? Would you keep the
> driver probing for both the old name with the `_` and the compatible or
> you just break the compatibility?

The Binding requires child nodes to have both a specific node name and
compatible. So if we remove the node name restriction, we stay compliant
to the binding.

The MFD driver requires specific node names, while the MFD cell drivers
seem to be matched by compatibles. It's thus should be safe to replace
the node name readout in the MFD driver with a compatible check.

Existing device trees will continue to work. Newer device trees can use
dashes. Once the binding is converted to YAML, we could enforce a name
to get everyone aligned, but it will be just a binding checker warning,
not a breakage on update.

Cheers,
Ahmad

> 
> Francesco
> 
> 


-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

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

* Re: [PATCH v1 11/17] ARM: dts: imx6q-apalis: Add ov5640 mipi csi camera
  2022-05-16 11:58 ` [PATCH v1 11/17] ARM: dts: imx6q-apalis: Add ov5640 mipi csi camera Max Krummenacher
  2022-05-16 12:08   ` Fabio Estevam
@ 2022-05-17 18:28   ` Fabio Estevam
  2022-05-18 14:28     ` Max Krummenacher
  1 sibling, 1 reply; 32+ messages in thread
From: Fabio Estevam @ 2022-05-17 18:28 UTC (permalink / raw)
  To: Max Krummenacher
  Cc: Max Krummenacher, Oleksandr Suvorov, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE,
	linux-kernel

Hi Max,

On Mon, May 16, 2022 at 8:59 AM Max Krummenacher <max.oss.09@gmail.com> wrote:

> +       ov5640_csi_cam: ov5640_mipi@3c {
> +               compatible = "ovti,ov5640";

Does it make sense to describe the ov5640 camera in the Apalis SoM dtsi?

The camera is not populated in the SoM. What if the customer baseboard
uses a different camera?

The same applies to the adv720 description.

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

* Re: [PATCH v1 01/17] dt-bindings: arm: fsl: Add carrier for toradex,apalis-imx6q
  2022-05-16 11:58 ` [PATCH v1 01/17] dt-bindings: arm: fsl: Add carrier for toradex,apalis-imx6q Max Krummenacher
@ 2022-05-18  0:57   ` Rob Herring
  0 siblings, 0 replies; 32+ messages in thread
From: Rob Herring @ 2022-05-18  0:57 UTC (permalink / raw)
  To: Max Krummenacher
  Cc: linux-kernel, Krzysztof Kozlowski, Tim Harvey, Matthias Schiffer,
	max.krummenacher, Christoph Niedermaier, devicetree,
	Alexander Stein, Sebastian Reichel, Rob Herring, Marcel Ziswiler,
	Shawn Guo, Oleksij Rempel, Li Yang, Lucas Stach

On Mon, 16 May 2022 13:58:29 +0200, Max Krummenacher wrote:
> From: Max Krummenacher <max.krummenacher@toradex.com>
> 
> Add binding for the Ixora V1.2 carrier board our Apalis iMX6D/Q
> may be mated with.
> 
> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
> ---
> 
>  Documentation/devicetree/bindings/arm/fsl.yaml | 1 +
>  1 file changed, 1 insertion(+)
> 

Acked-by: Rob Herring <robh@kernel.org>

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

* Re: [PATCH v1 12/17] ARM: dts: imx6q-apalis: Add adv7280 video input
  2022-05-16 12:10   ` Fabio Estevam
@ 2022-05-18 14:07     ` Max Krummenacher
  2022-05-18 14:10       ` Fabio Estevam
  0 siblings, 1 reply; 32+ messages in thread
From: Max Krummenacher @ 2022-05-18 14:07 UTC (permalink / raw)
  To: Fabio Estevam
  Cc: Max Krummenacher, Oleksandr Suvorov, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE,
	linux-kernel

Hi Fabio

On Mon, May 16, 2022 at 2:10 PM Fabio Estevam <festevam@gmail.com> wrote:
>
> Hi Max,
>
> On Mon, May 16, 2022 at 8:59 AM Max Krummenacher <max.oss.09@gmail.com> wrote:
>
> > +       adv_7280: adv7280@21 {
> > +               compatible = "adi,adv7280";
> > +               reg = <0x21>;
> > +               pinctrl-names = "default";
> > +               pinctrl-0 = <&pinctrl_ipu1_csi0>;
>
> I suggest passing "adv,force-bt656-4" property as this fixes sync problems.

I will add the property in a V2 of the patchset. Thanks for the suggestion.
With my setup, i.e. PAL camera as the signal source I see no
noticeable change though.

Max

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

* Re: [PATCH v1 12/17] ARM: dts: imx6q-apalis: Add adv7280 video input
  2022-05-18 14:07     ` Max Krummenacher
@ 2022-05-18 14:10       ` Fabio Estevam
  0 siblings, 0 replies; 32+ messages in thread
From: Fabio Estevam @ 2022-05-18 14:10 UTC (permalink / raw)
  To: Max Krummenacher
  Cc: Max Krummenacher, Oleksandr Suvorov, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE,
	linux-kernel

Hi Max,

On Wed, May 18, 2022 at 11:07 AM Max Krummenacher <max.oss.09@gmail.com> wrote:

> I will add the property in a V2 of the patchset. Thanks for the suggestion.
> With my setup, i.e. PAL camera as the signal source I see no
> noticeable change though.

Correct. This property helps to fix the sync with NTSC video.

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

* Re: [PATCH v1 11/17] ARM: dts: imx6q-apalis: Add ov5640 mipi csi camera
  2022-05-16 12:08   ` Fabio Estevam
@ 2022-05-18 14:21     ` Max Krummenacher
  2022-05-18 14:25       ` Fabio Estevam
  0 siblings, 1 reply; 32+ messages in thread
From: Max Krummenacher @ 2022-05-18 14:21 UTC (permalink / raw)
  To: Fabio Estevam
  Cc: Max Krummenacher, Oleksandr Suvorov, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE,
	linux-kernel

Hi Fabio

On Mon, May 16, 2022 at 2:08 PM Fabio Estevam <festevam@gmail.com> wrote:
>
> Hi Max,
>
> On Mon, May 16, 2022 at 8:59 AM Max Krummenacher <max.oss.09@gmail.com> wrote:
> >
> > From: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
> >
> > The Apalis iMX6 modules allow connecting a mipi-csi video input.
> > Add support for our OV5640 camera module but have it disabled.
> > This allows to enable it in an overlay per the current system
> > configuration.
> >
> > Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
> > Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
> > ---
> >
> >  arch/arm/boot/dts/imx6qdl-apalis.dtsi | 67 ++++++++++++++++++++++++++-
> >  1 file changed, 66 insertions(+), 1 deletion(-)
> >
> > diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
> > index 506d040ea37a..0d1004eede62 100644
> > --- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
> > +++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
> > @@ -29,6 +29,12 @@
> >                 status = "disabled";
> >         };
> >
> > +       clk_ov5640_osc: clk_ov5640_osc_int {
>
> Node names should have "-", not "_"

Ups, missed that one. Will fix it in V2. Thanks.

>
> clk_ov5640_osc: clk-ov5640-osc
>
> Also, no need for the _int suffix.
>
> Just curious: is ov5640 mipi support functional?
>
> I recalled that I had issues in getting Gstreamer pipeline to capture
> from the ov5640 mipi.
>
> There were some errors related to LP-11 during the start of the capture.

In my (limited) testing I saw no issues that the camera would not come up.
It takes 2 to 3 seconds until the pipeline is running but I noted no hickups.
I did this with setting the resolution to 640x480 and 1920x1080 which
probably would not relate to the LP-11 issue you mention.

I.e. I set up the v4l2 pipeline and start capture to the screen as follows:
```
media-ctl -l "'ov5640 1-003c':0 -> 'imx6-mipi-csi2':0[1]"
media-ctl -l "'imx6-mipi-csi2':2 -> 'ipu1_csi1':0[1]"
media-ctl -l "'ipu1_csi1':2 -> 'ipu1_csi1 capture':0[1]"
media-ctl -V "'ov5640 1-003c':0 [fmt:UYVY2X8/640x480 field:none]"
media-ctl -V "'imx6-mipi-csi2':2 [fmt:UYVY2X8/640x480 field:none]"
media-ctl -V "'ipu1_csi1':2 [fmt:AYUV32/640x480 field:none]"
gst-launch-1.0 v4l2src device='/dev/video0' ! videoconvert ! waylandsink
```

Max

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

* Re: [PATCH v1 11/17] ARM: dts: imx6q-apalis: Add ov5640 mipi csi camera
  2022-05-18 14:21     ` Max Krummenacher
@ 2022-05-18 14:25       ` Fabio Estevam
  2022-05-18 14:54         ` Max Krummenacher
  0 siblings, 1 reply; 32+ messages in thread
From: Fabio Estevam @ 2022-05-18 14:25 UTC (permalink / raw)
  To: Max Krummenacher
  Cc: Max Krummenacher, Oleksandr Suvorov, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE,
	linux-kernel

Hi Max,

On Wed, May 18, 2022 at 11:21 AM Max Krummenacher <max.oss.09@gmail.com> wrote:

> In my (limited) testing I saw no issues that the camera would not come up.
> It takes 2 to 3 seconds until the pipeline is running but I noted no hickups.
> I did this with setting the resolution to 640x480 and 1920x1080 which
> probably would not relate to the LP-11 issue you mention.
>
> I.e. I set up the v4l2 pipeline and start capture to the screen as follows:

Just curious: which baseboard did you use to test the ov5640 camera?

Most likely there was an issue with the customer's baseboard that
prevented the camera capture to start.

Thanks

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

* Re: [PATCH v1 11/17] ARM: dts: imx6q-apalis: Add ov5640 mipi csi camera
  2022-05-17 18:28   ` Fabio Estevam
@ 2022-05-18 14:28     ` Max Krummenacher
  0 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-18 14:28 UTC (permalink / raw)
  To: Fabio Estevam
  Cc: Max Krummenacher, Oleksandr Suvorov, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Rob Herring,
	Sascha Hauer, Shawn Guo,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE,
	linux-kernel

Hi Fabio

On Tue, May 17, 2022 at 8:28 PM Fabio Estevam <festevam@gmail.com> wrote:
>
> Hi Max,
>
> On Mon, May 16, 2022 at 8:59 AM Max Krummenacher <max.oss.09@gmail.com> wrote:
>
> > +       ov5640_csi_cam: ov5640_mipi@3c {
> > +               compatible = "ovti,ov5640";
>
> Does it make sense to describe the ov5640 camera in the Apalis SoM dtsi?
>
> The camera is not populated in the SoM. What if the customer baseboard
> uses a different camera?
>
> The same applies to the adv720 description.

We moved to a pattern where we do describe the 'Toradex' peripherals
in the SoM dtsi but
keep their status disabled. Then if the peripheral is on the carrier
board we only have to
enable it in the carrier board dts, for peripherals attached to the
carrier boards (e.g. like the
cameras) we enable it in device tree overlays.
This did reduce code duplication a lot.
A customer who attaches a different camera would add its camera node
in its device tree
or overlay and keep the ov5640 or adv7280 nodes disabled.

So I would rather not change anything here.

Max

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

* Re: [PATCH v1 11/17] ARM: dts: imx6q-apalis: Add ov5640 mipi csi camera
  2022-05-18 14:25       ` Fabio Estevam
@ 2022-05-18 14:54         ` Max Krummenacher
  0 siblings, 0 replies; 32+ messages in thread
From: Max Krummenacher @ 2022-05-18 14:54 UTC (permalink / raw)
  To: Fabio Estevam
  Cc: Max Krummenacher, Krzysztof Kozlowski, NXP Linux Team,
	Pengutronix Kernel Team, Rob Herring, Sascha Hauer, Shawn Guo,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE,
	linux-kernel

Hi Fabio

On Wed, May 18, 2022 at 4:25 PM Fabio Estevam <festevam@gmail.com> wrote:
>
> Hi Max,
>
> On Wed, May 18, 2022 at 11:21 AM Max Krummenacher <max.oss.09@gmail.com> wrote:
>
> > In my (limited) testing I saw no issues that the camera would not come up.
> > It takes 2 to 3 seconds until the pipeline is running but I noted no hickups.
> > I did this with setting the resolution to 640x480 and 1920x1080 which
> > probably would not relate to the LP-11 issue you mention.
> >
> > I.e. I set up the v4l2 pipeline and start capture to the screen as follows:
>
> Just curious: which baseboard did you use to test the ov5640 camera?
>
> Most likely there was an issue with the customer's baseboard that
> prevented the camera capture to start.

I used an 'Apalis Evaluation Board' with an 'Apalis iMX6 Mezannine V2.0A'.
Now I did retry and it works equally well on an 'Ixora V1.1A'

Note that in the beginning the camera module required the SoM to provide
a 24MHz clock. The V1.1B HW version then got its local oscillator and the
clock input no longer requires a clock. That may or may not have been the
issue your customer saw.

Max

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

* Re: [PATCH v1 02/17] Revert "ARM: dts: imx6qdl-apalis: Avoid underscore in node name"
  2022-05-16 11:58 ` [PATCH v1 02/17] Revert "ARM: dts: imx6qdl-apalis: Avoid underscore in node name" Max Krummenacher
  2022-05-16 12:49   ` Ahmad Fatoum
@ 2022-05-18 19:01   ` Rob Herring
  1 sibling, 0 replies; 32+ messages in thread
From: Rob Herring @ 2022-05-18 19:01 UTC (permalink / raw)
  To: Max Krummenacher
  Cc: max.krummenacher, Fabio Estevam, Krzysztof Kozlowski,
	NXP Linux Team, Pengutronix Kernel Team, Sascha Hauer, Shawn Guo,
	devicetree, linux-arm-kernel, linux-kernel

On Mon, May 16, 2022 at 01:58:30PM +0200, Max Krummenacher wrote:
> From: Max Krummenacher <max.krummenacher@toradex.com>
> 
> The STMPE MFD device binding requires the child node to have a fixed
> name, i.e. with '_', not '-'. Otherwise the stmpe_adc, stmpe_touchscreen
> drivers will not be probed.
> 
> Fixes: 56086b5e804f ("ARM: dts: imx6qdl-apalis: Avoid underscore in node name")
> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
> ---
> 
>  arch/arm/boot/dts/imx6qdl-apalis.dtsi | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/arch/arm/boot/dts/imx6qdl-apalis.dtsi b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
> index bd763bae596b..da919d0544a8 100644
> --- a/arch/arm/boot/dts/imx6qdl-apalis.dtsi
> +++ b/arch/arm/boot/dts/imx6qdl-apalis.dtsi
> @@ -315,7 +315,7 @@
>  		/* ADC conversion time: 80 clocks */
>  		st,sample-time = <4>;
>  
> -		stmpe_touchscreen: stmpe-touchscreen {
> +		stmpe_touchscreen: stmpe_touchscreen {

In any case, the correct name would have been 'touchscreen' and 'adc'.

>  			compatible = "st,stmpe-ts";
>  			/* 8 sample average control */
>  			st,ave-ctrl = <3>;
> @@ -332,7 +332,7 @@
>  			st,touch-det-delay = <5>;
>  		};
>  
> -		stmpe_adc: stmpe-adc {
> +		stmpe_adc: stmpe_adc {
>  			compatible = "st,stmpe-adc";
>  			/* forbid to use ADC channels 3-0 (touch) */
>  			st,norequest-mask = <0x0F>;
> -- 
> 2.20.1
> 

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

end of thread, other threads:[~2022-05-18 19:01 UTC | newest]

Thread overview: 32+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-16 11:58 [PATCH v1 00/17] ARM: dts: imx6q-apalis: Misc improvements and newly added carrier Max Krummenacher
2022-05-16 11:58 ` [PATCH v1 01/17] dt-bindings: arm: fsl: Add carrier for toradex,apalis-imx6q Max Krummenacher
2022-05-18  0:57   ` Rob Herring
2022-05-16 11:58 ` [PATCH v1 02/17] Revert "ARM: dts: imx6qdl-apalis: Avoid underscore in node name" Max Krummenacher
2022-05-16 12:49   ` Ahmad Fatoum
2022-05-16 14:53     ` Francesco Dolcini
2022-05-16 15:07       ` Ahmad Fatoum
2022-05-18 19:01   ` Rob Herring
2022-05-16 11:58 ` [PATCH v1 03/17] ARM: dts: imx6q-apalis: Add gpio-line-names Max Krummenacher
2022-05-16 11:58 ` [PATCH v1 04/17] ARM: dts: imx6q-apalis: Command pmic to standby for poweroff Max Krummenacher
2022-05-16 11:58 ` [PATCH v1 05/17] ARM: dts: imx6q-apalis: Move parallel rgb interface to SoM dtsi Max Krummenacher
2022-05-16 11:58 ` [PATCH v1 06/17] ARM: dts: imx6q-apalis: Move pinmux groups " Max Krummenacher
2022-05-16 11:58 ` [PATCH v1 07/17] ARM: dts: imx6q-apalis: Move Atmel MXT touch ctrl " Max Krummenacher
2022-05-16 11:58 ` [PATCH v1 08/17] ARM: dts: imx6q-apalis: Add LVDS panel support Max Krummenacher
2022-05-16 11:58 ` [PATCH v1 09/17] ARM: dts: imx6q-apalis: Disable HDMI Max Krummenacher
2022-05-16 11:58 ` [PATCH v1 10/17] ARM: dts: imx6q-apalis: Disable stmpe touchscreen Max Krummenacher
2022-05-16 11:58 ` [PATCH v1 11/17] ARM: dts: imx6q-apalis: Add ov5640 mipi csi camera Max Krummenacher
2022-05-16 12:08   ` Fabio Estevam
2022-05-18 14:21     ` Max Krummenacher
2022-05-18 14:25       ` Fabio Estevam
2022-05-18 14:54         ` Max Krummenacher
2022-05-17 18:28   ` Fabio Estevam
2022-05-18 14:28     ` Max Krummenacher
2022-05-16 11:58 ` [PATCH v1 12/17] ARM: dts: imx6q-apalis: Add adv7280 video input Max Krummenacher
2022-05-16 12:10   ` Fabio Estevam
2022-05-18 14:07     ` Max Krummenacher
2022-05-18 14:10       ` Fabio Estevam
2022-05-16 11:58 ` [PATCH v1 13/17] ARM: dts: imx6q-apalis: Clean-up sd card support Max Krummenacher
2022-05-16 11:58 ` [PATCH v1 14/17] ARM: dts: imx6q-apalis: Add support for Toradex Ixora V1.2 carrier boards Max Krummenacher
2022-05-16 11:58 ` [PATCH v1 15/17] ARM: dts: imx6q-apalis: backlight pwm: Simplify inverted backlight Max Krummenacher
2022-05-16 11:58 ` [PATCH v1 16/17] ARM: dts: imx6q-apalis: backlight pwm: Adapt brightness steps Max Krummenacher
2022-05-16 11:58 ` [PATCH v1 17/17] ARM: dts: imx6q-apalis: Cleanup Max Krummenacher

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