Commit f0787592 authored by Benjamin Tissoires's avatar Benjamin Tissoires Committed by Dmitry Torokhov

Input: elantech - split device info into a separate structure

In preparation for SMBus device support, move static device
information that we query form the touchpad upon initialization into
separate structure. This will allow us to query the device without
allocating memory first.
Signed-off-by: default avatarBenjamin Tissoires <benjamin.tissoires@redhat.com>
Acked-by: default avatarKT Liao <kt.liao@emc.com.tw>
Signed-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
parent 559b3df7
This diff is collapsed.
......@@ -114,6 +114,22 @@ struct finger_pos {
unsigned int y;
};
struct elantech_device_info {
unsigned char capabilities[3];
unsigned char samples[3];
unsigned char debug;
unsigned char hw_version;
unsigned int fw_version;
bool paritycheck;
bool jumpy_cursor;
bool reports_pressure;
bool crc_enabled;
bool set_hw_resolution;
bool has_trackpoint;
int (*send_cmd)(struct psmouse *psmouse, unsigned char c,
unsigned char *param);
};
struct elantech_data {
struct input_dev *tp_dev; /* Relative device for trackpoint */
char tp_phys[32];
......@@ -127,22 +143,12 @@ struct elantech_data {
unsigned char reg_24;
unsigned char reg_25;
unsigned char reg_26;
unsigned char debug;
unsigned char capabilities[3];
unsigned char samples[3];
bool paritycheck;
bool jumpy_cursor;
bool reports_pressure;
bool crc_enabled;
bool set_hw_resolution;
unsigned char hw_version;
unsigned int fw_version;
unsigned int single_finger_reports;
unsigned int y_max;
unsigned int width;
struct finger_pos mt[ETP_MAX_FINGERS];
unsigned char parity[256];
int (*send_cmd)(struct psmouse *psmouse, unsigned char c, unsigned char *param);
struct elantech_device_info info;
void (*original_set_rate)(struct psmouse *psmouse, unsigned int rate);
};
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment