devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] arm64: dts: mt7622: fix BPI-R64 WPS button
@ 2022-06-30 11:16 Nick Hainke
  2022-07-07 14:45 ` Matthias Brugger
  0 siblings, 1 reply; 2+ messages in thread
From: Nick Hainke @ 2022-06-30 11:16 UTC (permalink / raw)
  To: linux-mediatek
  Cc: Nick Hainke, INAGAKI Hiroshi, Rob Herring, Krzysztof Kozlowski,
	Matthias Brugger, Ryder Lee, devicetree, linux-arm-kernel,
	linux-kernel

The bananapi R64 (BPI-R64) experiences wrong WPS button signals.
In OpenWrt pushing the WPS button while powering on the device will set
it to recovery mode. Currently, this also happens without any user
interaction. In particular, the wrong signals appear while booting the
device or restarting it, e.g. after doing a system upgrade. If the
device is in recovery mode the user needs to manually power cycle or
restart it.

The official BPI-R64 sources set the WPS button to GPIO_ACTIVE_LOW in
the device tree. This setting seems to suppress the unwanted WPS button
press signals. So this commit changes the button from GPIO_ACTIVE_HIGH to
GPIO_ACTIVE_LOW.

The official BPI-R64 sources can be found on
https://github.com/BPI-SINOVOIP/BPI-R64-openwrt

Fixes: 0b6286dd96c0 ("arm64: dts: mt7622: add bananapi BPI-R64 board")

Suggested-by: INAGAKI Hiroshi <musashino.open@gmail.com>
Signed-off-by: Nick Hainke <vincent@systemli.org>
---
 arch/arm64/boot/dts/mediatek/mt7622-bananapi-bpi-r64.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/mediatek/mt7622-bananapi-bpi-r64.dts b/arch/arm64/boot/dts/mediatek/mt7622-bananapi-bpi-r64.dts
index 2b9bf8dd14ec..7538918c7a82 100644
--- a/arch/arm64/boot/dts/mediatek/mt7622-bananapi-bpi-r64.dts
+++ b/arch/arm64/boot/dts/mediatek/mt7622-bananapi-bpi-r64.dts
@@ -49,7 +49,7 @@ factory {
 		wps {
 			label = "wps";
 			linux,code = <KEY_WPS_BUTTON>;
-			gpios = <&pio 102 GPIO_ACTIVE_HIGH>;
+			gpios = <&pio 102 GPIO_ACTIVE_LOW>;
 		};
 	};
 
-- 
2.37.0


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

* Re: [PATCH] arm64: dts: mt7622: fix BPI-R64 WPS button
  2022-06-30 11:16 [PATCH] arm64: dts: mt7622: fix BPI-R64 WPS button Nick Hainke
@ 2022-07-07 14:45 ` Matthias Brugger
  0 siblings, 0 replies; 2+ messages in thread
From: Matthias Brugger @ 2022-07-07 14:45 UTC (permalink / raw)
  To: Nick Hainke, linux-mediatek
  Cc: INAGAKI Hiroshi, Rob Herring, Krzysztof Kozlowski, Ryder Lee,
	devicetree, linux-arm-kernel, linux-kernel



On 30/06/2022 13:16, Nick Hainke wrote:
> The bananapi R64 (BPI-R64) experiences wrong WPS button signals.
> In OpenWrt pushing the WPS button while powering on the device will set
> it to recovery mode. Currently, this also happens without any user
> interaction. In particular, the wrong signals appear while booting the
> device or restarting it, e.g. after doing a system upgrade. If the
> device is in recovery mode the user needs to manually power cycle or
> restart it.
> 
> The official BPI-R64 sources set the WPS button to GPIO_ACTIVE_LOW in
> the device tree. This setting seems to suppress the unwanted WPS button
> press signals. So this commit changes the button from GPIO_ACTIVE_HIGH to
> GPIO_ACTIVE_LOW.
> 
> The official BPI-R64 sources can be found on
> https://github.com/BPI-SINOVOIP/BPI-R64-openwrt
> 
> Fixes: 0b6286dd96c0 ("arm64: dts: mt7622: add bananapi BPI-R64 board")
> 
> Suggested-by: INAGAKI Hiroshi <musashino.open@gmail.com>
> Signed-off-by: Nick Hainke <vincent@systemli.org>

Applied, thanks!

> ---
>   arch/arm64/boot/dts/mediatek/mt7622-bananapi-bpi-r64.dts | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/arm64/boot/dts/mediatek/mt7622-bananapi-bpi-r64.dts b/arch/arm64/boot/dts/mediatek/mt7622-bananapi-bpi-r64.dts
> index 2b9bf8dd14ec..7538918c7a82 100644
> --- a/arch/arm64/boot/dts/mediatek/mt7622-bananapi-bpi-r64.dts
> +++ b/arch/arm64/boot/dts/mediatek/mt7622-bananapi-bpi-r64.dts
> @@ -49,7 +49,7 @@ factory {
>   		wps {
>   			label = "wps";
>   			linux,code = <KEY_WPS_BUTTON>;
> -			gpios = <&pio 102 GPIO_ACTIVE_HIGH>;
> +			gpios = <&pio 102 GPIO_ACTIVE_LOW>;
>   		};
>   	};
>   

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

end of thread, other threads:[~2022-07-07 14:45 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-06-30 11:16 [PATCH] arm64: dts: mt7622: fix BPI-R64 WPS button Nick Hainke
2022-07-07 14:45 ` Matthias Brugger

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