thinkpad-acpi: make driver events work in NVRAM poll mode
commit6a79a0708eecc65ade97a09ec4c11488374e1bbc
authorHenrique de Moraes Holschuh <hmh@hmh.eng.br>
Fri, 26 Feb 2010 00:29:00 +0000 (25 21:29 -0300)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 15 Mar 2010 16:06:47 +0000 (15 09:06 -0700)
treea72b453047b9099d3e24340af25e7bd48dd75e37
parentba0b9eadb8d5cb3679359c1064fa22de1bec393a
thinkpad-acpi: make driver events work in NVRAM poll mode

commit 7f0cf712a74fcc3ad21f0bde95bd32c2f2cc3888 upstream.

Thadeu Lima de Souza Cascardo reports this:

Brightness notification does not work until the user writes to
hotkey_mask attribute.  That's because the polling thread will only run
if hotkey_user_mask is set and someone is reading the input device or
if hotkey_driver_mask is set.  In this second case, this condition is
not tested after the mask is changed, because the brightness and
volume drivers are started after the hotkey drivers.

Fix tpacpi_hotkey_driver_mask_set() to call hotkey_poll_setup(), so
that the poller kthread will be started when needed.

Reported-by: Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
Tested-by: Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/platform/x86/thinkpad_acpi.c