summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSvyatoslav Ryhel <[email protected]>2025-09-01 08:50:13 +0300
committerSvyatoslav Ryhel <[email protected]>2025-09-01 11:23:21 +0300
commitbd903be32409de11e0f71e6a28835d4333c3e418 (patch)
tree334d72eb40c821695ab1ad3881d6f4d80a3cb944
parenta353211288464543e67b3ec4a421a751fcae98ce (diff)
ARM: tegra20: transformer: fix Hall sensor behavior
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 <[email protected]>
-rw-r--r--arch/arm/dts/tegra20-asus-sl101.dts10
-rw-r--r--arch/arm/dts/tegra20-asus-tf101.dts10
-rw-r--r--arch/arm/dts/tegra20-asus-tf101g.dts10
-rw-r--r--arch/arm/dts/tegra20-asus-transformer.dtsi6
4 files changed, 30 insertions, 6 deletions
diff --git a/arch/arm/dts/tegra20-asus-sl101.dts b/arch/arm/dts/tegra20-asus-sl101.dts
index b4709c3e9a4..9f78b0febf3 100644
--- a/arch/arm/dts/tegra20-asus-sl101.dts
+++ b/arch/arm/dts/tegra20-asus-sl101.dts
@@ -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>;
+ };
+ };
};
diff --git a/arch/arm/dts/tegra20-asus-tf101.dts b/arch/arm/dts/tegra20-asus-tf101.dts
index 7c734fb5b19..03ba78c5dc2 100644
--- a/arch/arm/dts/tegra20-asus-tf101.dts
+++ b/arch/arm/dts/tegra20-asus-tf101.dts
@@ -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>;
+ };
+ };
};
diff --git a/arch/arm/dts/tegra20-asus-tf101g.dts b/arch/arm/dts/tegra20-asus-tf101g.dts
index f49a358a267..44d5fdfc2b5 100644
--- a/arch/arm/dts/tegra20-asus-tf101g.dts
+++ b/arch/arm/dts/tegra20-asus-tf101g.dts
@@ -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>;
+ };
+ };
};
diff --git a/arch/arm/dts/tegra20-asus-transformer.dtsi b/arch/arm/dts/tegra20-asus-transformer.dtsi
index 61b1cea6e90..df078a6fcdc 100644
--- a/arch/arm/dts/tegra20-asus-transformer.dtsi
+++ b/arch/arm/dts/tegra20-asus-transformer.dtsi
@@ -497,12 +497,6 @@
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 {