Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 930e1924 authored by Marcos Paulo de Souza's avatar Marcos Paulo de Souza Committed by Dmitry Torokhov
Browse files

Input: i8042 - skip selftest on ASUS laptops

On suspend/resume cycle, selftest is executed to reset i8042 controller.
But when this is done in Asus devices, subsequent calls to detect/init
functions to elantech driver fails. Skipping selftest fixes this problem.

An easier step to reproduce this problem is adding i8042.reset=1 as a
kernel parameter. On Asus laptops, it'll make the system to start with the
touchpad already stuck, since psmouse_probe forcibly calls the selftest
function.

This patch was inspired by John Hiesey's change[1], but, since this problem
affects a lot of models of Asus, let's avoid running selftests on them.

All models affected by this problem:
A455LD
K401LB
K501LB
K501LX
R409L
V502LX
X302LA
X450LCP
X450LD
X455LAB
X455LDB
X455LF
Z450LA

[1]: https://marc.info/?l=linux-input&m=144312209020616&w=2

Fixes: "ETPS/2 Elantech Touchpad dies after resume from suspend"
(https://bugzilla.kernel.org/show_bug.cgi?id=107971

)

Signed-off-by: default avatarMarcos Paulo de Souza <marcos.souza.org@gmail.com>
Cc: stable@vger.kernel.org
Signed-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
parent 4e1bff07
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -1409,7 +1409,14 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
	i8042.nopnp	[HW] Don't use ACPIPnP / PnPBIOS to discover KBD/AUX
			     controllers
	i8042.notimeout	[HW] Ignore timeout condition signalled by controller
	i8042.reset	[HW] Reset the controller during init and cleanup
	i8042.reset	[HW] Reset the controller during init, cleanup and
			     suspend-to-ram transitions, only during s2r
			     transitions, or never reset
			Format: { 1 | Y | y | 0 | N | n }
			1, Y, y: always reset controller
			0, N, n: don't ever reset controller
			Default: only on s2r transitions on x86; most other
			architectures force reset to be always executed
	i8042.unlock	[HW] Unlock (ignore) the keylock
	i8042.kbdreset  [HW] Reset device connected to KBD port

+1 −1
Original line number Diff line number Diff line
@@ -81,7 +81,7 @@ static inline int i8042_platform_init(void)
		return -EBUSY;
#endif

	i8042_reset = 1;
	i8042_reset = I8042_RESET_ALWAYS;
	return 0;
}

+1 −1
Original line number Diff line number Diff line
@@ -61,7 +61,7 @@ static inline int i8042_platform_init(void)
		return -EBUSY;
#endif

	i8042_reset = 1;
	i8042_reset = I8042_RESET_ALWAYS;

	return 0;
}
+1 −1
Original line number Diff line number Diff line
@@ -44,7 +44,7 @@ static inline void i8042_write_command(int val)

static inline int i8042_platform_init(void)
{
	i8042_reset = 1;
	i8042_reset = I8042_RESET_ALWAYS;
	return 0;
}

+1 −1
Original line number Diff line number Diff line
@@ -130,7 +130,7 @@ static int __init i8042_platform_init(void)
		}
	}

	i8042_reset = 1;
	i8042_reset = I8042_RESET_ALWAYS;

	return 0;
}
Loading