]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
ARM: tegra20: transformer: fix Hall sensor behavior
authorSvyatoslav Ryhel <clamor95@gmail.com>
Mon, 1 Sep 2025 05:50:13 +0000 (08:50 +0300)
committerSvyatoslav Ryhel <clamor95@gmail.com>
Mon, 1 Sep 2025 08:23:21 +0000 (11:23 +0300)
Hall sensor found in SL101 is not used for closed dock detection as on
TF101 or TF101G, it is used to detect if keyboard slider is out. To address
this, lets move Lid sensor switch into TF101/G trees and add Tablet mode
switch into SL101 tree.

Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
arch/arm/dts/tegra20-asus-sl101.dts
arch/arm/dts/tegra20-asus-tf101.dts
arch/arm/dts/tegra20-asus-tf101g.dts
arch/arm/dts/tegra20-asus-transformer.dtsi

index b4709c3e9a45b31ede1722277eaa5e36862d07f4..9f78b0febf39bf76051c70534697dffcc6558b60 100644 (file)
@@ -6,4 +6,14 @@
 / {
        model = "ASUS EeePad Slider SL101";
        compatible = "asus,sl101", "nvidia,tegra20";
+
+       extcon-keys {
+               compatible = "gpio-keys";
+
+               switch-tablet-mode {
+                       label = "Tablet Mode";
+                       gpios = <&gpio TEGRA_GPIO(S, 4) GPIO_ACTIVE_LOW>;
+                       linux,code = <SW_TABLET_MODE>;
+               };
+       };
 };
index 7c734fb5b195c6c0e942b4c652d55ec1084287d4..03ba78c5dc27ed753a409cbefb13a66b9a179a97 100644 (file)
@@ -6,4 +6,14 @@
 / {
        model = "ASUS EeePad Transformer TF101";
        compatible = "asus,tf101", "nvidia,tegra20";
+
+       extcon-keys {
+               compatible = "gpio-keys";
+
+               switch-dock-hall-sensor {
+                       label = "Lid sensor";
+                       gpios = <&gpio TEGRA_GPIO(S, 4) GPIO_ACTIVE_LOW>;
+                       linux,code = <SW_LID>;
+               };
+       };
 };
index f49a358a267ea5952d8deddbbbdf6a25e447760b..44d5fdfc2b576cdfaf84ea3efbd3a2f756e41bc7 100644 (file)
@@ -6,4 +6,14 @@
 / {
        model = "ASUS EeePad Transformer TF101G";
        compatible = "asus,tf101g", "nvidia,tegra20";
+
+       extcon-keys {
+               compatible = "gpio-keys";
+
+               switch-dock-hall-sensor {
+                       label = "Lid sensor";
+                       gpios = <&gpio TEGRA_GPIO(S, 4) GPIO_ACTIVE_LOW>;
+                       linux,code = <SW_LID>;
+               };
+       };
 };
index 61b1cea6e90bee00c7272fea2ef4c9a8468c15be..df078a6fcdc58388a28c24ee766925dd21f019f4 100644 (file)
                        gpios = <&gpio TEGRA_GPIO(Q, 5) GPIO_ACTIVE_LOW>;
                        linux,code = <KEY_UP>;
                };
-
-               switch-dock-hall-sensor {
-                       label = "Lid sensor";
-                       gpios = <&gpio TEGRA_GPIO(S, 4) GPIO_ACTIVE_LOW>;
-                       linux,code = <SW_LID>;
-               };
        };
 
        panel: panel {