summaryrefslogtreecommitdiff
path: root/drivers/input/mouse/elan_i2c_smbus.c
diff options
context:
space:
mode:
authorKT Liao <ktalex.liao@gmail.com>2016-11-28 07:59:29 +0300
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2017-05-12 03:44:23 +0300
commita2eaf299d134cfe780c68c771f88d81516c1e70d (patch)
tree76c6b5e035fefb17e15d4cfc60bdda871e1be9c0 /drivers/input/mouse/elan_i2c_smbus.c
parentc5928551fd41b2eecdad78fa2be2a4a13ed5fde9 (diff)
downloadlinux-a2eaf299d134cfe780c68c771f88d81516c1e70d.tar.xz
Input: elan_i2c - add support for fetching chip type on newer hardware
Newer Elantech hardware requires different way of fetching chip type and version data. Signed-off-by: KT Liao <kt.liao@emc.com.tw> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input/mouse/elan_i2c_smbus.c')
-rw-r--r--drivers/input/mouse/elan_i2c_smbus.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/drivers/input/mouse/elan_i2c_smbus.c b/drivers/input/mouse/elan_i2c_smbus.c
index e23b2495d52e..df7a57ca7331 100644
--- a/drivers/input/mouse/elan_i2c_smbus.c
+++ b/drivers/input/mouse/elan_i2c_smbus.c
@@ -166,7 +166,7 @@ static int elan_smbus_get_version(struct i2c_client *client,
}
static int elan_smbus_get_sm_version(struct i2c_client *client,
- u8 *ic_type, u8 *version)
+ u16 *ic_type, u8 *version)
{
int error;
u8 val[3];
@@ -495,6 +495,12 @@ static int elan_smbus_finish_fw_update(struct i2c_client *client,
return 0;
}
+static int elan_smbus_get_pattern(struct i2c_client *client, u8 *pattern)
+{
+ *pattern = 0;
+ return 0;
+}
+
const struct elan_transport_ops elan_smbus_ops = {
.initialize = elan_smbus_initialize,
.sleep_control = elan_smbus_sleep_control,
@@ -524,4 +530,5 @@ const struct elan_transport_ops elan_smbus_ops = {
.finish_fw_update = elan_smbus_finish_fw_update,
.get_report = elan_smbus_get_report,
+ .get_pattern = elan_smbus_get_pattern,
};