Skip to content

Commit ed3e98e

Browse files
MerlijnWajerdtor
authored andcommitted
ARM: dts: n900: remove mmc1 card detect gpio
Instead, expose the key via the input framework, as SW_MACHINE_COVER The chip-detect GPIO is actually detecting if the cover is closed. Technically it's possible to use the SD card with open cover. The only downside is risk of battery falling out and user being able to physically remove the card. The behaviour of SD card not being available when the device is open is unexpected and creates more problems than it solves. There is a high chance, that more people accidentally break their rootfs by opening the case without physically removing the card. Reviewed-by: Sebastian Reichel <[email protected]> Acked-by: Tony Lindgren <[email protected]> Signed-off-by: Merlijn Wajer <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Dmitry Torokhov <[email protected]>
1 parent c463bb2 commit ed3e98e

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

arch/arm/boot/dts/omap3-n900.dts

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,14 @@
105105
linux,code = <SW_FRONT_PROXIMITY>;
106106
linux,can-disable;
107107
};
108+
109+
machine_cover {
110+
label = "Machine Cover";
111+
gpios = <&gpio6 0 GPIO_ACTIVE_LOW>; /* 160 */
112+
linux,input-type = <EV_SW>;
113+
linux,code = <SW_MACHINE_COVER>;
114+
linux,can-disable;
115+
};
108116
};
109117

110118
isp1707: isp1707 {
@@ -819,10 +827,6 @@
819827
pinctrl-0 = <&mmc1_pins>;
820828
vmmc-supply = <&vmmc1>;
821829
bus-width = <4>;
822-
/* For debugging, it is often good idea to remove this GPIO.
823-
It means you can remove back cover (to reboot by removing
824-
battery) and still use the MMC card. */
825-
cd-gpios = <&gpio6 0 GPIO_ACTIVE_LOW>; /* 160 */
826830
};
827831

828832
/* most boards use vaux3, only some old versions use vmmc2 instead */

0 commit comments

Comments
 (0)