mbox series

[0/5] arm64: dts: rockchip: pinmux fixes and support for 2 adapters for Theobroma boards

Message ID 20250220-ringneck-dtbos-v1-0-25c97f2385e6@cherry.de (mailing list archive)
Headers show
Series arm64: dts: rockchip: pinmux fixes and support for 2 adapters for Theobroma boards | expand

Message

Quentin Schulz Feb. 20, 2025, 12:20 p.m. UTC
This is based on top of
https://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip.git/log/?h=v6.15-armsoc/dts64
6ee0b9ad3995 ("arm64: dts: rockchip: Add rng node to RK3588") as it
depends on the (merged) series from
https://lore.kernel.org/all/20250211-pre-ict-jaguar-v6-0-4484b0f88cfc@cherry.de/

Patches for Haikou Video Demo adapter for PX30 Ringneck and RK3399 Puma
(patches 4 and 5) also depend on the following patch series:
https://lore.kernel.org/linux-devicetree/20250220-pca976x-reset-driver-v1-0-6abbf043050e@cherry.de/

This fixes incorrect pinmux on UART0 and UART5 for PX30 Ringneck on
Haikou.

This adds support for the HAIKOU-LVDS-9904379 adapter for PX30 Ringneck
fitted on a Haikou carrierboard.

Additionally, this adds support for Haikou Video Demo adapter on PX30
Ringneck and RK3399 Puma fitted on a Haikou carrierboard. Notably
missing from the overlay is the OV5675 camera module which expects
19.2MHz which we cannot exactly feed right now. Modifications to the
OV5675 drivers will be made so it's more flexible and then support for
the camera module will be added. This adapter has a 720x1280 DSI display
with a GT911 touchscreen, a GPIO-controllable LED and an I2C GPIO
expander. Support for this adapter on RK3588 Tiger is being added in a
separate patch series[1].

Note that the DSI panel currently is glitchy on both PX30 Ringneck and
RK3399 Puma but this is being tackled in another series[2]. Since this
will not be fixed through DT properties for the panel, adding the DT
nodes for the DSI panel even if not perfect right now seems acceptable
to me.

[1] https://lore.kernel.org/linux-rockchip/20241127143719.660658-1-heiko@sntech.de/
[2] https://lore.kernel.org/r/20240626084722.832763-1-heiko@sntech.de

Signed-off-by: Quentin Schulz <quentin.schulz@cherry.de>
---
Quentin Schulz (5):
      arm64: dts: rockchip: fix pinmux of UART0 for PX30 Ringneck on Haikou
      arm64: dts: rockchip: fix pinmux of UART5 for PX30 Ringneck on Haikou
      arm64: dts: rockchip: add support for HAIKOU-LVDS-9904379 adapter for PX30 Ringneck
      arm64: dts: rockchip: add overlay for PX30 Ringneck Haikou Video Demo adapter
      arm64: dts: rockchip: add overlay for RK3399 Puma Haikou Video Demo adapter

 arch/arm64/boot/dts/rockchip/Makefile              |  15 ++
 .../px30-ringneck-haikou-lvds-9904379.dtso         | 130 ++++++++++++++
 .../rockchip/px30-ringneck-haikou-video-demo.dtso  | 190 +++++++++++++++++++++
 .../boot/dts/rockchip/px30-ringneck-haikou.dts     |  10 +-
 .../rockchip/rk3399-puma-haikou-video-demo.dtso    | 166 ++++++++++++++++++
 5 files changed, 510 insertions(+), 1 deletion(-)
---
base-commit: 6ee0b9ad3995ee5fa229035c69013b7dd0d3634b
change-id: 20250128-ringneck-dtbos-98064839355e
prerequisite-change-id: 20250219-pca976x-reset-driver-c9aa95869426:v1
prerequisite-patch-id: 24af74693654b4a456aca0a1399ec8509e141c01
prerequisite-patch-id: df17910ec117317f2f456f679a77ed60e9168fa3

Best regards,

Comments

Rob Herring (Arm) Feb. 20, 2025, 9:29 p.m. UTC | #1
On Thu, 20 Feb 2025 13:20:09 +0100, Quentin Schulz wrote:
> This is based on top of
> https://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip.git/log/?h=v6.15-armsoc/dts64
> 6ee0b9ad3995 ("arm64: dts: rockchip: Add rng node to RK3588") as it
> depends on the (merged) series from
> https://lore.kernel.org/all/20250211-pre-ict-jaguar-v6-0-4484b0f88cfc@cherry.de/
> 
> Patches for Haikou Video Demo adapter for PX30 Ringneck and RK3399 Puma
> (patches 4 and 5) also depend on the following patch series:
> https://lore.kernel.org/linux-devicetree/20250220-pca976x-reset-driver-v1-0-6abbf043050e@cherry.de/
> 
> This fixes incorrect pinmux on UART0 and UART5 for PX30 Ringneck on
> Haikou.
> 
> This adds support for the HAIKOU-LVDS-9904379 adapter for PX30 Ringneck
> fitted on a Haikou carrierboard.
> 
> Additionally, this adds support for Haikou Video Demo adapter on PX30
> Ringneck and RK3399 Puma fitted on a Haikou carrierboard. Notably
> missing from the overlay is the OV5675 camera module which expects
> 19.2MHz which we cannot exactly feed right now. Modifications to the
> OV5675 drivers will be made so it's more flexible and then support for
> the camera module will be added. This adapter has a 720x1280 DSI display
> with a GT911 touchscreen, a GPIO-controllable LED and an I2C GPIO
> expander. Support for this adapter on RK3588 Tiger is being added in a
> separate patch series[1].
> 
> Note that the DSI panel currently is glitchy on both PX30 Ringneck and
> RK3399 Puma but this is being tackled in another series[2]. Since this
> will not be fixed through DT properties for the panel, adding the DT
> nodes for the DSI panel even if not perfect right now seems acceptable
> to me.
> 
> [1] https://lore.kernel.org/linux-rockchip/20241127143719.660658-1-heiko@sntech.de/
> [2] https://lore.kernel.org/r/20240626084722.832763-1-heiko@sntech.de
> 
> Signed-off-by: Quentin Schulz <quentin.schulz@cherry.de>
> ---
> Quentin Schulz (5):
>       arm64: dts: rockchip: fix pinmux of UART0 for PX30 Ringneck on Haikou
>       arm64: dts: rockchip: fix pinmux of UART5 for PX30 Ringneck on Haikou
>       arm64: dts: rockchip: add support for HAIKOU-LVDS-9904379 adapter for PX30 Ringneck
>       arm64: dts: rockchip: add overlay for PX30 Ringneck Haikou Video Demo adapter
>       arm64: dts: rockchip: add overlay for RK3399 Puma Haikou Video Demo adapter
> 
>  arch/arm64/boot/dts/rockchip/Makefile              |  15 ++
>  .../px30-ringneck-haikou-lvds-9904379.dtso         | 130 ++++++++++++++
>  .../rockchip/px30-ringneck-haikou-video-demo.dtso  | 190 +++++++++++++++++++++
>  .../boot/dts/rockchip/px30-ringneck-haikou.dts     |  10 +-
>  .../rockchip/rk3399-puma-haikou-video-demo.dtso    | 166 ++++++++++++++++++
>  5 files changed, 510 insertions(+), 1 deletion(-)
> ---
> base-commit: 6ee0b9ad3995ee5fa229035c69013b7dd0d3634b
> change-id: 20250128-ringneck-dtbos-98064839355e
> prerequisite-change-id: 20250219-pca976x-reset-driver-c9aa95869426:v1
> prerequisite-patch-id: 24af74693654b4a456aca0a1399ec8509e141c01
> prerequisite-patch-id: df17910ec117317f2f456f679a77ed60e9168fa3
> 
> Best regards,
> --
> Quentin Schulz <quentin.schulz@cherry.de>
> 
> 
> 


My bot found new DTB warnings on the .dts files added or changed in this
series.

Some warnings may be from an existing SoC .dtsi. Or perhaps the warnings
are fixed by another series. Ultimately, it is up to the platform
maintainer whether these warnings are acceptable or not. No need to reply
unless the platform maintainer has comments.

If you already ran DT checks and didn't see these error(s), then
make sure dt-schema is up to date:

  pip3 install dtschema --upgrade


New warnings running 'make CHECK_DTBS=y for arch/arm64/boot/dts/rockchip/' for 20250220-ringneck-dtbos-v1-0-25c97f2385e6@cherry.de:

arch/arm64/boot/dts/rockchip/px30-ringneck-haikou.dtb: uart: uart5-rts-gpio: {'rockchip,pins': [[0, 13, 0, 147]], 'phandle': 70} is not of type 'array'
	from schema $id: http://devicetree.org/schemas/gpio/gpio-consumer.yaml#
Quentin Schulz Feb. 21, 2025, 10:01 a.m. UTC | #2
Hi Rob, Heiko,

On 2/20/25 10:29 PM, Rob Herring (Arm) wrote:
> 
> On Thu, 20 Feb 2025 13:20:09 +0100, Quentin Schulz wrote:
[...]
> My bot found new DTB warnings on the .dts files added or changed in this
> series.
> 
> Some warnings may be from an existing SoC .dtsi. Or perhaps the warnings
> are fixed by another series. Ultimately, it is up to the platform
> maintainer whether these warnings are acceptable or not. No need to reply
> unless the platform maintainer has comments.
> 
> If you already ran DT checks and didn't see these error(s), then
> make sure dt-schema is up to date:
> 
>    pip3 install dtschema --upgrade
> 
> 
> New warnings running 'make CHECK_DTBS=y for arch/arm64/boot/dts/rockchip/' for 20250220-ringneck-dtbos-v1-0-25c97f2385e6@cherry.de:
> 

$ make ARCH=arm64 CROSS_COMPILE="ccache aarch64-linux-gnu-" O=ringneck/ 
CHECK_DTBS=y for arch/arm64/boot/dts/rockchip/
make[1]: Entering directory '/home/qschulz/work/upstream/linux/ringneck'
make[3]: *** No rule to make target 'for'.  Stop.
make[2]: *** [/home/qschulz/work/upstream/linux/Makefile:372: 
__build_one_by_one] Error 2
make[1]: *** [/home/qschulz/work/upstream/linux/Makefile:251: 
__sub-make] Error 2
make[1]: Leaving directory '/home/qschulz/work/upstream/linux/ringneck'
make: *** [Makefile:251: __sub-make] Error 2

Is there a way your bot can provide a command we can actually run?

I believe for me it is something like:

make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- CHECK_DTBS=y $(for dtb 
in arch/arm64/boot/dts/rockchip/*.dtb; do D=$(basename $(dirname 
"$dtb")); B=$(basename "$dtb"); echo -n "$D/$B "; done)

> arch/arm64/boot/dts/rockchip/px30-ringneck-haikou.dtb: uart: uart5-rts-gpio: {'rockchip,pins': [[0, 13, 0, 147]], 'phandle': 70} is not of type 'array'
> 	from schema $id: http://devicetree.org/schemas/gpio/gpio-consumer.yaml#
> 
> 

I believe this is a false positive due to the node suffix being -gpio? 
If I change -gpio suffix to -pin, it doesn't complain anymore.

"""
diff --git a/arch/arm64/boot/dts/rockchip/px30-ringneck-haikou.dts 
b/arch/arm64/boot/dts/rockchip/px30-ringneck-haikou.dts
index 08a11e4758413..249e50d64791e 100644
--- a/arch/arm64/boot/dts/rockchip/px30-ringneck-haikou.dts
+++ b/arch/arm64/boot/dts/rockchip/px30-ringneck-haikou.dts
@@ -196,7 +196,7 @@ sd_card_led_pin: sd-card-led-pin {
  	};

  	uart {
-		uart5_rts_gpio: uart5-rts-gpio {
+		uart5_rts_pin: uart5-rts-pin {
  			rockchip,pins =
  			  <0 RK_PB5 RK_FUNC_GPIO &pcfg_pull_up>;
  		};
@@ -234,7 +234,7 @@ &uart0 {
  };

  &uart5 {
-	pinctrl-0 = <&uart5_xfer &uart5_rts_gpio>;
+	pinctrl-0 = <&uart5_xfer &uart5_rts_pin>;
  	rts-gpios = <&gpio0 RK_PB5 GPIO_ACTIVE_HIGH>;
  	status = "okay";
  };
"""

@Heiko, I guess you would like a warning-less DT :) I can send a v2 with 
that change then if that works for you? I can wait a few days for other 
reviews :)

I'm specifically avoiding naming it uart5_rts because it already exists 
for the RTS function muxing of the UART5 controller and I don't think 
it's appropriate to just override it like that.

Cheers,
Quentin
Heiko Stübner Feb. 21, 2025, 10:07 a.m. UTC | #3
Hi Quentin,

Am Freitag, 21. Februar 2025, 11:01:44 MEZ schrieb Quentin Schulz:
> On 2/20/25 10:29 PM, Rob Herring (Arm) wrote:
> > On Thu, 20 Feb 2025 13:20:09 +0100, Quentin Schulz wrote:
> I believe this is a false positive due to the node suffix being -gpio? 
> If I change -gpio suffix to -pin, it doesn't complain anymore.
> 
> """
> diff --git a/arch/arm64/boot/dts/rockchip/px30-ringneck-haikou.dts 
> b/arch/arm64/boot/dts/rockchip/px30-ringneck-haikou.dts
> index 08a11e4758413..249e50d64791e 100644
> --- a/arch/arm64/boot/dts/rockchip/px30-ringneck-haikou.dts
> +++ b/arch/arm64/boot/dts/rockchip/px30-ringneck-haikou.dts
> @@ -196,7 +196,7 @@ sd_card_led_pin: sd-card-led-pin {
>   	};
> 
>   	uart {
> -		uart5_rts_gpio: uart5-rts-gpio {
> +		uart5_rts_pin: uart5-rts-pin {
>   			rockchip,pins =
>   			  <0 RK_PB5 RK_FUNC_GPIO &pcfg_pull_up>;
>   		};
> @@ -234,7 +234,7 @@ &uart0 {
>   };
> 
>   &uart5 {
> -	pinctrl-0 = <&uart5_xfer &uart5_rts_gpio>;
> +	pinctrl-0 = <&uart5_xfer &uart5_rts_pin>;
>   	rts-gpios = <&gpio0 RK_PB5 GPIO_ACTIVE_HIGH>;
>   	status = "okay";
>   };
> """
> 
> @Heiko, I guess you would like a warning-less DT :) I can send a v2 with 
> that change then if that works for you? I can wait a few days for other 
> reviews :)

that would be great - the v2.

We already had patches addressing the -gpio thing for other boards in the
past, so going to "-pin" is the preferred solution here.

Also, your patches are totally specific to Theobroma-boards, so just send
your v2 at your convenience - I don't really expect that much additional
outside review comments ;-) .


Heiko