]> git.ipfire.org Git - people/arne_f/kernel.git/commit
platform/x86: thinkpad_acpi: Send tablet mode switch at wakeup time
authorBenjamin Berg <bberg@redhat.com>
Mon, 23 Nov 2020 13:21:57 +0000 (14:21 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 2 Dec 2020 07:52:00 +0000 (08:52 +0100)
commit83bec121880cc0cf36c9029b0d996cffd7b02fed
tree2f1639a07d252c876fa9d103fa5e8311236b7ac3
parent90198983bd2851dd2831a65f9d07040d55d4bf43
platform/x86: thinkpad_acpi: Send tablet mode switch at wakeup time

[ Upstream commit e40cc1b476d60f22628741e53cf3446a29e6e6b9 ]

The lid state may change while the machine is suspended. As such, we may
need to re-check the state at wake-up time (at least when waking up from
hibernation).
Add the appropriate call to the resume handler in order to sync the
SW_TABLET_MODE switch state with the hardware state.

Fixes: dda3ec0aa631 ("platform/x86: thinkpad_acpi: Implement tablet mode using GMMS method")
BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=210269
Signed-off-by: Benjamin Berg <bberg@redhat.com>
Acked-by: Henrique de Moraes Holschuh <hnh@hmh.eng.br>
Link: https://lore.kernel.org/r/20201123132157.866303-1-benjamin@sipsolutions.net
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/platform/x86/thinkpad_acpi.c