]> git.baikalelectronics.ru Git - kernel.git/commit
platform/x86: ideapad-laptop: Add sysfs interface for touchpad state
authorRitesh Raj Sarraf <rrs@debian.org>
Fri, 17 Feb 2017 18:47:56 +0000 (00:17 +0530)
committerAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Mon, 15 May 2017 09:06:09 +0000 (12:06 +0300)
commite629977655f816eb5a205d49c32687b7f18034dd
treed275ed7b6becf3c36861ebc0ff279ac318afed43
parent81e0e7134ab085ac5d0890177bfed38a0f2be4f8
platform/x86: ideapad-laptop: Add sysfs interface for touchpad state

Lenovo Yoga (many variants: Yoga, Yoga2 Pro, Yoga2 13, Yoga3 Pro, Yoga 3
14, etc) has multiple modles that are a hybrid laptop, working in laptop
mode as well as tablet mode.

Currently, there is no easy interface to determine the touchpad status,
which in case of the Yoga family of machines, can also be useful to
assume tablet mode status.

Note: The ideapad-laptop driver does not provide a SW_TABLET_MODE either.

For a detailed discussion  on why we want either of the interfaces,
please see:
https://bugs.launchpad.net/onboard/+bug/1366421/comments/43

This patch adds a sysfs interface for read/write access under:
/sys/bus/platform/devices/VPC2004\:00/touchpad_mode

Signed-off-by: Ritesh Raj Sarraf <rrs@debian.org>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Documentation/ABI/testing/sysfs-platform-ideapad-laptop
drivers/platform/x86/ideapad-laptop.c