aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Documentation/ABI/testing/sysfs-platform-eeepc-wmi7
-rw-r--r--drivers/platform/x86/eeepc-wmi.c5
2 files changed, 12 insertions, 0 deletions
diff --git a/Documentation/ABI/testing/sysfs-platform-eeepc-wmi b/Documentation/ABI/testing/sysfs-platform-eeepc-wmi
index 9fc8d33e280d..26acb6842c44 100644
--- a/Documentation/ABI/testing/sysfs-platform-eeepc-wmi
+++ b/Documentation/ABI/testing/sysfs-platform-eeepc-wmi
@@ -22,3 +22,10 @@ KernelVersion: 2.6.39
22Contact: "Corentin Chary" <corentincj@iksaif.net> 22Contact: "Corentin Chary" <corentincj@iksaif.net>
23Description: 23Description:
24 Control the card reader. 1 means on, 0 means off. 24 Control the card reader. 1 means on, 0 means off.
25
26What: /sys/devices/platform/eeepc-wmi/touchpad
27Date: Jan 2010
28KernelVersion: 2.6.39
29Contact: "Corentin Chary" <corentincj@iksaif.net>
30Description:
31 Control the card touchpad. 1 means on, 0 means off.
diff --git a/drivers/platform/x86/eeepc-wmi.c b/drivers/platform/x86/eeepc-wmi.c
index a78a90d886da..16c7f2d62515 100644
--- a/drivers/platform/x86/eeepc-wmi.c
+++ b/drivers/platform/x86/eeepc-wmi.c
@@ -77,6 +77,7 @@ MODULE_ALIAS("wmi:"EEEPC_WMI_MGMT_GUID);
77#define EEEPC_WMI_DEVID_BRIGHTNESS 0x00050012 77#define EEEPC_WMI_DEVID_BRIGHTNESS 0x00050012
78#define EEEPC_WMI_DEVID_CAMERA 0x00060013 78#define EEEPC_WMI_DEVID_CAMERA 0x00060013
79#define EEEPC_WMI_DEVID_CARDREADER 0x00080013 79#define EEEPC_WMI_DEVID_CARDREADER 0x00080013
80#define EEEPC_WMI_DEVID_TOUCHPAD 0x00100011
80#define EEEPC_WMI_DEVID_TOUCHPAD_LED 0x00100012 81#define EEEPC_WMI_DEVID_TOUCHPAD_LED 0x00100012
81 82
82#define EEEPC_WMI_DSTS_STATUS_BIT 0x00000001 83#define EEEPC_WMI_DSTS_STATUS_BIT 0x00000001
@@ -1006,6 +1007,7 @@ static ssize_t show_sys_wmi(int devid, char *buf)
1006 .store = store_##_name, \ 1007 .store = store_##_name, \
1007 } 1008 }
1008 1009
1010EEEPC_WMI_CREATE_DEVICE_ATTR(touchpad, 0644, EEEPC_WMI_DEVID_TOUCHPAD);
1009EEEPC_WMI_CREATE_DEVICE_ATTR(camera, 0644, EEEPC_WMI_DEVID_CAMERA); 1011EEEPC_WMI_CREATE_DEVICE_ATTR(camera, 0644, EEEPC_WMI_DEVID_CAMERA);
1010EEEPC_WMI_CREATE_DEVICE_ATTR(cardr, 0644, EEEPC_WMI_DEVID_CARDREADER); 1012EEEPC_WMI_CREATE_DEVICE_ATTR(cardr, 0644, EEEPC_WMI_DEVID_CARDREADER);
1011 1013
@@ -1036,6 +1038,7 @@ static struct attribute *platform_attributes[] = {
1036 &dev_attr_cpufv.attr, 1038 &dev_attr_cpufv.attr,
1037 &dev_attr_camera.attr, 1039 &dev_attr_camera.attr,
1038 &dev_attr_cardr.attr, 1040 &dev_attr_cardr.attr,
1041 &dev_attr_touchpad.attr,
1039 NULL 1042 NULL
1040}; 1043};
1041 1044
@@ -1050,6 +1053,8 @@ static mode_t eeepc_sysfs_is_visible(struct kobject *kobj,
1050 devid = EEEPC_WMI_DEVID_CAMERA; 1053 devid = EEEPC_WMI_DEVID_CAMERA;
1051 else if (attr == &dev_attr_cardr.attr) 1054 else if (attr == &dev_attr_cardr.attr)
1052 devid = EEEPC_WMI_DEVID_CARDREADER; 1055 devid = EEEPC_WMI_DEVID_CARDREADER;
1056 else if (attr == &dev_attr_touchpad.attr)
1057 devid = EEEPC_WMI_DEVID_TOUCHPAD;
1053 1058
1054 if (devid != -1) 1059 if (devid != -1)
1055 supported = eeepc_wmi_get_devstate_simple(devid) != -ENODEV; 1060 supported = eeepc_wmi_get_devstate_simple(devid) != -ENODEV;