All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] arm64: dts: rockchip: fix input enable pinconf on rk3399
@ 2022-12-15 10:19 ` Arnaud Ferraris
  0 siblings, 0 replies; 9+ messages in thread
From: Arnaud Ferraris @ 2022-12-15 10:19 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Heiko Stuebner, Caleb Connolly,
	devicetree, linux-arm-kernel, linux-rockchip, linux-kernel
  Cc: kernel, Arnaud Ferraris

When the input enable pinconf was introduced, a default drive-strength
value of 2 was set for the pull up/down configs. However, this parameter
is unneeded when configuring the pin as input, and having a single
hardcoded value here is actually harmful: GPIOs on the RK3399 have
various same drive-strength capabilities depending on the bank and port
they belong to.

As an example, trying to configure the GPIO4_PD3 pin as an input with
pull-up enabled fails with the following output:

  [   10.706542] rockchip-pinctrl pinctrl: unsupported driver strength 2
  [   10.713661] rockchip-pinctrl pinctrl: pin_config_set op failed for pin 155

(acceptable drive-strength values for this pin being 3, 6, 9 and 12)

Let's drop the drive-strength property from all input pinconfs in order
to solve this issue.

Fixes: ec48c3e82ca3 ("arm64: dts: rockchip: add an input enable pinconf to rk3399")
Signed-off-by: Arnaud Ferraris <arnaud.ferraris@collabora.com>
---
 arch/arm64/boot/dts/rockchip/rk3399.dtsi | 2 --
 1 file changed, 2 deletions(-)

diff --git a/arch/arm64/boot/dts/rockchip/rk3399.dtsi b/arch/arm64/boot/dts/rockchip/rk3399.dtsi
index 92c2207e686c..59858f2dc8b9 100644
--- a/arch/arm64/boot/dts/rockchip/rk3399.dtsi
+++ b/arch/arm64/boot/dts/rockchip/rk3399.dtsi
@@ -2221,13 +2221,11 @@ pcfg_input_enable: pcfg-input-enable {
 		pcfg_input_pull_up: pcfg-input-pull-up {
 			input-enable;
 			bias-pull-up;
-			drive-strength = <2>;
 		};
 
 		pcfg_input_pull_down: pcfg-input-pull-down {
 			input-enable;
 			bias-pull-down;
-			drive-strength = <2>;
 		};
 
 		clock {
-- 
2.35.1


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

* [PATCH] arm64: dts: rockchip: fix input enable pinconf on rk3399
@ 2022-12-15 10:19 ` Arnaud Ferraris
  0 siblings, 0 replies; 9+ messages in thread
From: Arnaud Ferraris @ 2022-12-15 10:19 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Heiko Stuebner, Caleb Connolly,
	devicetree, linux-arm-kernel, linux-rockchip, linux-kernel
  Cc: kernel, Arnaud Ferraris

When the input enable pinconf was introduced, a default drive-strength
value of 2 was set for the pull up/down configs. However, this parameter
is unneeded when configuring the pin as input, and having a single
hardcoded value here is actually harmful: GPIOs on the RK3399 have
various same drive-strength capabilities depending on the bank and port
they belong to.

As an example, trying to configure the GPIO4_PD3 pin as an input with
pull-up enabled fails with the following output:

  [   10.706542] rockchip-pinctrl pinctrl: unsupported driver strength 2
  [   10.713661] rockchip-pinctrl pinctrl: pin_config_set op failed for pin 155

(acceptable drive-strength values for this pin being 3, 6, 9 and 12)

Let's drop the drive-strength property from all input pinconfs in order
to solve this issue.

Fixes: ec48c3e82ca3 ("arm64: dts: rockchip: add an input enable pinconf to rk3399")
Signed-off-by: Arnaud Ferraris <arnaud.ferraris@collabora.com>
---
 arch/arm64/boot/dts/rockchip/rk3399.dtsi | 2 --
 1 file changed, 2 deletions(-)

diff --git a/arch/arm64/boot/dts/rockchip/rk3399.dtsi b/arch/arm64/boot/dts/rockchip/rk3399.dtsi
index 92c2207e686c..59858f2dc8b9 100644
--- a/arch/arm64/boot/dts/rockchip/rk3399.dtsi
+++ b/arch/arm64/boot/dts/rockchip/rk3399.dtsi
@@ -2221,13 +2221,11 @@ pcfg_input_enable: pcfg-input-enable {
 		pcfg_input_pull_up: pcfg-input-pull-up {
 			input-enable;
 			bias-pull-up;
-			drive-strength = <2>;
 		};
 
 		pcfg_input_pull_down: pcfg-input-pull-down {
 			input-enable;
 			bias-pull-down;
-			drive-strength = <2>;
 		};
 
 		clock {
-- 
2.35.1


_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

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

* [PATCH] arm64: dts: rockchip: fix input enable pinconf on rk3399
@ 2022-12-15 10:19 ` Arnaud Ferraris
  0 siblings, 0 replies; 9+ messages in thread
From: Arnaud Ferraris @ 2022-12-15 10:19 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Heiko Stuebner, Caleb Connolly,
	devicetree, linux-arm-kernel, linux-rockchip, linux-kernel
  Cc: kernel, Arnaud Ferraris

When the input enable pinconf was introduced, a default drive-strength
value of 2 was set for the pull up/down configs. However, this parameter
is unneeded when configuring the pin as input, and having a single
hardcoded value here is actually harmful: GPIOs on the RK3399 have
various same drive-strength capabilities depending on the bank and port
they belong to.

As an example, trying to configure the GPIO4_PD3 pin as an input with
pull-up enabled fails with the following output:

  [   10.706542] rockchip-pinctrl pinctrl: unsupported driver strength 2
  [   10.713661] rockchip-pinctrl pinctrl: pin_config_set op failed for pin 155

(acceptable drive-strength values for this pin being 3, 6, 9 and 12)

Let's drop the drive-strength property from all input pinconfs in order
to solve this issue.

Fixes: ec48c3e82ca3 ("arm64: dts: rockchip: add an input enable pinconf to rk3399")
Signed-off-by: Arnaud Ferraris <arnaud.ferraris@collabora.com>
---
 arch/arm64/boot/dts/rockchip/rk3399.dtsi | 2 --
 1 file changed, 2 deletions(-)

diff --git a/arch/arm64/boot/dts/rockchip/rk3399.dtsi b/arch/arm64/boot/dts/rockchip/rk3399.dtsi
index 92c2207e686c..59858f2dc8b9 100644
--- a/arch/arm64/boot/dts/rockchip/rk3399.dtsi
+++ b/arch/arm64/boot/dts/rockchip/rk3399.dtsi
@@ -2221,13 +2221,11 @@ pcfg_input_enable: pcfg-input-enable {
 		pcfg_input_pull_up: pcfg-input-pull-up {
 			input-enable;
 			bias-pull-up;
-			drive-strength = <2>;
 		};
 
 		pcfg_input_pull_down: pcfg-input-pull-down {
 			input-enable;
 			bias-pull-down;
-			drive-strength = <2>;
 		};
 
 		clock {
-- 
2.35.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH] arm64: dts: rockchip: fix input enable pinconf on rk3399
  2022-12-15 10:19 ` Arnaud Ferraris
  (?)
@ 2022-12-15 20:42   ` Caleb Connolly
  -1 siblings, 0 replies; 9+ messages in thread
From: Caleb Connolly @ 2022-12-15 20:42 UTC (permalink / raw)
  To: Arnaud Ferraris, Rob Herring, Krzysztof Kozlowski,
	Heiko Stuebner, devicetree, linux-arm-kernel, linux-rockchip,
	linux-kernel
  Cc: kernel



On 15/12/2022 10:19, Arnaud Ferraris wrote:
> When the input enable pinconf was introduced, a default drive-strength
> value of 2 was set for the pull up/down configs. However, this parameter
> is unneeded when configuring the pin as input, and having a single
> hardcoded value here is actually harmful: GPIOs on the RK3399 have
> various same drive-strength capabilities depending on the bank and port
> they belong to.
> 
> As an example, trying to configure the GPIO4_PD3 pin as an input with
> pull-up enabled fails with the following output:
> 
>    [   10.706542] rockchip-pinctrl pinctrl: unsupported driver strength 2
>    [   10.713661] rockchip-pinctrl pinctrl: pin_config_set op failed for pin 155
> 
> (acceptable drive-strength values for this pin being 3, 6, 9 and 12)
> 
> Let's drop the drive-strength property from all input pinconfs in order
> to solve this issue.
> 
> Fixes: ec48c3e82ca3 ("arm64: dts: rockchip: add an input enable pinconf to rk3399")
> Signed-off-by: Arnaud Ferraris <arnaud.ferraris@collabora.com>

Reviewed-by: Caleb Connolly <kc@postmarketos.org>

> ---
>   arch/arm64/boot/dts/rockchip/rk3399.dtsi | 2 --
>   1 file changed, 2 deletions(-)
> 
> diff --git a/arch/arm64/boot/dts/rockchip/rk3399.dtsi b/arch/arm64/boot/dts/rockchip/rk3399.dtsi
> index 92c2207e686c..59858f2dc8b9 100644
> --- a/arch/arm64/boot/dts/rockchip/rk3399.dtsi
> +++ b/arch/arm64/boot/dts/rockchip/rk3399.dtsi
> @@ -2221,13 +2221,11 @@ pcfg_input_enable: pcfg-input-enable {
>   		pcfg_input_pull_up: pcfg-input-pull-up {
>   			input-enable;
>   			bias-pull-up;
> -			drive-strength = <2>;
>   		};
>   
>   		pcfg_input_pull_down: pcfg-input-pull-down {
>   			input-enable;
>   			bias-pull-down;
> -			drive-strength = <2>;
>   		};
>   
>   		clock {

-- 
Kind Regards,
Caleb (they/them)

_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

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

* Re: [PATCH] arm64: dts: rockchip: fix input enable pinconf on rk3399
@ 2022-12-15 20:42   ` Caleb Connolly
  0 siblings, 0 replies; 9+ messages in thread
From: Caleb Connolly @ 2022-12-15 20:42 UTC (permalink / raw)
  To: Arnaud Ferraris, Rob Herring, Krzysztof Kozlowski,
	Heiko Stuebner, devicetree, linux-arm-kernel, linux-rockchip,
	linux-kernel
  Cc: kernel



On 15/12/2022 10:19, Arnaud Ferraris wrote:
> When the input enable pinconf was introduced, a default drive-strength
> value of 2 was set for the pull up/down configs. However, this parameter
> is unneeded when configuring the pin as input, and having a single
> hardcoded value here is actually harmful: GPIOs on the RK3399 have
> various same drive-strength capabilities depending on the bank and port
> they belong to.
> 
> As an example, trying to configure the GPIO4_PD3 pin as an input with
> pull-up enabled fails with the following output:
> 
>    [   10.706542] rockchip-pinctrl pinctrl: unsupported driver strength 2
>    [   10.713661] rockchip-pinctrl pinctrl: pin_config_set op failed for pin 155
> 
> (acceptable drive-strength values for this pin being 3, 6, 9 and 12)
> 
> Let's drop the drive-strength property from all input pinconfs in order
> to solve this issue.
> 
> Fixes: ec48c3e82ca3 ("arm64: dts: rockchip: add an input enable pinconf to rk3399")
> Signed-off-by: Arnaud Ferraris <arnaud.ferraris@collabora.com>

Reviewed-by: Caleb Connolly <kc@postmarketos.org>

> ---
>   arch/arm64/boot/dts/rockchip/rk3399.dtsi | 2 --
>   1 file changed, 2 deletions(-)
> 
> diff --git a/arch/arm64/boot/dts/rockchip/rk3399.dtsi b/arch/arm64/boot/dts/rockchip/rk3399.dtsi
> index 92c2207e686c..59858f2dc8b9 100644
> --- a/arch/arm64/boot/dts/rockchip/rk3399.dtsi
> +++ b/arch/arm64/boot/dts/rockchip/rk3399.dtsi
> @@ -2221,13 +2221,11 @@ pcfg_input_enable: pcfg-input-enable {
>   		pcfg_input_pull_up: pcfg-input-pull-up {
>   			input-enable;
>   			bias-pull-up;
> -			drive-strength = <2>;
>   		};
>   
>   		pcfg_input_pull_down: pcfg-input-pull-down {
>   			input-enable;
>   			bias-pull-down;
> -			drive-strength = <2>;
>   		};
>   
>   		clock {

-- 
Kind Regards,
Caleb (they/them)

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH] arm64: dts: rockchip: fix input enable pinconf on rk3399
@ 2022-12-15 20:42   ` Caleb Connolly
  0 siblings, 0 replies; 9+ messages in thread
From: Caleb Connolly @ 2022-12-15 20:42 UTC (permalink / raw)
  To: Arnaud Ferraris, Rob Herring, Krzysztof Kozlowski,
	Heiko Stuebner, devicetree, linux-arm-kernel, linux-rockchip,
	linux-kernel
  Cc: kernel



On 15/12/2022 10:19, Arnaud Ferraris wrote:
> When the input enable pinconf was introduced, a default drive-strength
> value of 2 was set for the pull up/down configs. However, this parameter
> is unneeded when configuring the pin as input, and having a single
> hardcoded value here is actually harmful: GPIOs on the RK3399 have
> various same drive-strength capabilities depending on the bank and port
> they belong to.
> 
> As an example, trying to configure the GPIO4_PD3 pin as an input with
> pull-up enabled fails with the following output:
> 
>    [   10.706542] rockchip-pinctrl pinctrl: unsupported driver strength 2
>    [   10.713661] rockchip-pinctrl pinctrl: pin_config_set op failed for pin 155
> 
> (acceptable drive-strength values for this pin being 3, 6, 9 and 12)
> 
> Let's drop the drive-strength property from all input pinconfs in order
> to solve this issue.
> 
> Fixes: ec48c3e82ca3 ("arm64: dts: rockchip: add an input enable pinconf to rk3399")
> Signed-off-by: Arnaud Ferraris <arnaud.ferraris@collabora.com>

Reviewed-by: Caleb Connolly <kc@postmarketos.org>

> ---
>   arch/arm64/boot/dts/rockchip/rk3399.dtsi | 2 --
>   1 file changed, 2 deletions(-)
> 
> diff --git a/arch/arm64/boot/dts/rockchip/rk3399.dtsi b/arch/arm64/boot/dts/rockchip/rk3399.dtsi
> index 92c2207e686c..59858f2dc8b9 100644
> --- a/arch/arm64/boot/dts/rockchip/rk3399.dtsi
> +++ b/arch/arm64/boot/dts/rockchip/rk3399.dtsi
> @@ -2221,13 +2221,11 @@ pcfg_input_enable: pcfg-input-enable {
>   		pcfg_input_pull_up: pcfg-input-pull-up {
>   			input-enable;
>   			bias-pull-up;
> -			drive-strength = <2>;
>   		};
>   
>   		pcfg_input_pull_down: pcfg-input-pull-down {
>   			input-enable;
>   			bias-pull-down;
> -			drive-strength = <2>;
>   		};
>   
>   		clock {

-- 
Kind Regards,
Caleb (they/them)

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

* Re: [PATCH] arm64: dts: rockchip: fix input enable pinconf on rk3399
  2022-12-15 10:19 ` Arnaud Ferraris
  (?)
@ 2023-01-11 10:48   ` Heiko Stuebner
  -1 siblings, 0 replies; 9+ messages in thread
From: Heiko Stuebner @ 2023-01-11 10:48 UTC (permalink / raw)
  To: linux-arm-kernel, linux-kernel, Arnaud Ferraris, Caleb Connolly,
	devicetree, linux-rockchip, Rob Herring, Krzysztof Kozlowski
  Cc: Heiko Stuebner, kernel

On Thu, 15 Dec 2022 11:19:47 +0100, Arnaud Ferraris wrote:
> When the input enable pinconf was introduced, a default drive-strength
> value of 2 was set for the pull up/down configs. However, this parameter
> is unneeded when configuring the pin as input, and having a single
> hardcoded value here is actually harmful: GPIOs on the RK3399 have
> various same drive-strength capabilities depending on the bank and port
> they belong to.
> 
> [...]

Applied, thanks!

[1/1] arm64: dts: rockchip: fix input enable pinconf on rk3399
      commit: 6f515b663d49a14fb63f8c5d0a2a4ae53d44790a

Best regards,
-- 
Heiko Stuebner <heiko@sntech.de>

_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

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

* Re: [PATCH] arm64: dts: rockchip: fix input enable pinconf on rk3399
@ 2023-01-11 10:48   ` Heiko Stuebner
  0 siblings, 0 replies; 9+ messages in thread
From: Heiko Stuebner @ 2023-01-11 10:48 UTC (permalink / raw)
  To: linux-arm-kernel, linux-kernel, Arnaud Ferraris, Caleb Connolly,
	devicetree, linux-rockchip, Rob Herring, Krzysztof Kozlowski
  Cc: Heiko Stuebner, kernel

On Thu, 15 Dec 2022 11:19:47 +0100, Arnaud Ferraris wrote:
> When the input enable pinconf was introduced, a default drive-strength
> value of 2 was set for the pull up/down configs. However, this parameter
> is unneeded when configuring the pin as input, and having a single
> hardcoded value here is actually harmful: GPIOs on the RK3399 have
> various same drive-strength capabilities depending on the bank and port
> they belong to.
> 
> [...]

Applied, thanks!

[1/1] arm64: dts: rockchip: fix input enable pinconf on rk3399
      commit: 6f515b663d49a14fb63f8c5d0a2a4ae53d44790a

Best regards,
-- 
Heiko Stuebner <heiko@sntech.de>

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

* Re: [PATCH] arm64: dts: rockchip: fix input enable pinconf on rk3399
@ 2023-01-11 10:48   ` Heiko Stuebner
  0 siblings, 0 replies; 9+ messages in thread
From: Heiko Stuebner @ 2023-01-11 10:48 UTC (permalink / raw)
  To: linux-arm-kernel, linux-kernel, Arnaud Ferraris, Caleb Connolly,
	devicetree, linux-rockchip, Rob Herring, Krzysztof Kozlowski
  Cc: Heiko Stuebner, kernel

On Thu, 15 Dec 2022 11:19:47 +0100, Arnaud Ferraris wrote:
> When the input enable pinconf was introduced, a default drive-strength
> value of 2 was set for the pull up/down configs. However, this parameter
> is unneeded when configuring the pin as input, and having a single
> hardcoded value here is actually harmful: GPIOs on the RK3399 have
> various same drive-strength capabilities depending on the bank and port
> they belong to.
> 
> [...]

Applied, thanks!

[1/1] arm64: dts: rockchip: fix input enable pinconf on rk3399
      commit: 6f515b663d49a14fb63f8c5d0a2a4ae53d44790a

Best regards,
-- 
Heiko Stuebner <heiko@sntech.de>

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

end of thread, other threads:[~2023-01-11 10:49 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-12-15 10:19 [PATCH] arm64: dts: rockchip: fix input enable pinconf on rk3399 Arnaud Ferraris
2022-12-15 10:19 ` Arnaud Ferraris
2022-12-15 10:19 ` Arnaud Ferraris
2022-12-15 20:42 ` Caleb Connolly
2022-12-15 20:42   ` Caleb Connolly
2022-12-15 20:42   ` Caleb Connolly
2023-01-11 10:48 ` Heiko Stuebner
2023-01-11 10:48   ` Heiko Stuebner
2023-01-11 10:48   ` Heiko Stuebner

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.