Use the EVIOCGID ioctl for synaptics event device auto

detection. This is much simpler than parsing /proc/bus/input/devices
and more robust too.
This commit is contained in:
Peter Osterlund
2003-09-24 23:03:43 +02:00
parent 95256de7ca
commit fe3d1e6d2b
2 changed files with 41 additions and 105 deletions

View File

@@ -14,9 +14,19 @@ struct input_event {
unsigned long tv_usec;
unsigned short type;
unsigned short code;
unsigned int value;
int value;
};
struct input_id {
unsigned short bustype;
unsigned short vendor;
unsigned short product;
unsigned short version;
};
#define EVIOCGID _IOR('E', 0x02, struct input_id) /* get device ID */
#define EV_SYN 0x00
#define EV_KEY 0x01
#define EV_REL 0x02
@@ -44,4 +54,10 @@ struct input_event {
#define MSC_GESTURE 0x02
#define BUS_I8042 0x11
#define PSMOUSE_SYNAPTICS 7
#endif /* _LINUX_INPUT_H_ */