summaryrefslogtreecommitdiffstats
path: root/0001-HID-rmi-introduce-RMI-driver-for-Synaptics-touchpads.patch
diff options
context:
space:
mode:
Diffstat (limited to '0001-HID-rmi-introduce-RMI-driver-for-Synaptics-touchpads.patch')
-rw-r--r--0001-HID-rmi-introduce-RMI-driver-for-Synaptics-touchpads.patch55
1 files changed, 1 insertions, 54 deletions
diff --git a/0001-HID-rmi-introduce-RMI-driver-for-Synaptics-touchpads.patch b/0001-HID-rmi-introduce-RMI-driver-for-Synaptics-touchpads.patch
index b3ec026c3..632174608 100644
--- a/0001-HID-rmi-introduce-RMI-driver-for-Synaptics-touchpads.patch
+++ b/0001-HID-rmi-introduce-RMI-driver-for-Synaptics-touchpads.patch
@@ -32,19 +32,15 @@ Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
- Removed obviously wrong hid_hw_stop() at the end of probe
-- emulate hid_hw_raw_request and hid_hw_output_report that has been
- interoduced in 3.15
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
---
drivers/hid/Kconfig | 8 +
drivers/hid/Makefile | 1 +
- drivers/hid/compat.h | 43 +++
drivers/hid/hid-core.c | 2 +
drivers/hid/hid-rmi.c | 890 +++++++++++++++++++++++++++++++++++++++++++++++++
include/linux/hid.h | 2 +
6 files changed, 946 insertions(+)
- create mode 100644 drivers/hid/compat.h
create mode 100644 drivers/hid/hid-rmi.c
diff --git a/drivers/hid/Kconfig b/drivers/hid/Kconfig
@@ -78,55 +74,6 @@ index 30e4431..b326f79 100644
obj-$(CONFIG_HID_SAITEK) += hid-saitek.o
obj-$(CONFIG_HID_SAMSUNG) += hid-samsung.o
obj-$(CONFIG_HID_SMARTJOYPLUS) += hid-sjoy.o
-diff --git a/drivers/hid/compat.h b/drivers/hid/compat.h
-new file mode 100644
-index 0000000..1318ca6e
---- /dev/null
-+++ b/drivers/hid/compat.h
-@@ -0,0 +1,43 @@
-+/*
-+ * Copyright (c) 2014 Benjamin Tissoires <benjamin.tissoires@gmail.com>
-+ * Copyright (c) 2014 Red Hat, Inc
-+ *
-+ * This program is free software; you can redistribute it and/or modify it
-+ * under the terms of the GNU General Public License as published by the Free
-+ * Software Foundation; either version 2 of the License, or (at your option)
-+ * any later version.
-+ */
-+
-+#include <linux/version.h>
-+
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 15, 0)
-+
-+static inline int hid_hw_raw_request(struct hid_device *hdev,
-+ unsigned char reportnum, __u8 *buf,
-+ size_t len, unsigned char rtype, int reqtype)
-+{
-+ if (len < 1 || len > HID_MAX_BUFFER_SIZE || !buf)
-+ return -EINVAL;
-+
-+ switch (reqtype) {
-+ case HID_REQ_SET_REPORT:
-+ if (reportnum != buf[0])
-+ return -EINVAL;
-+ return hdev->hid_output_raw_report(hdev, buf, len, rtype);
-+ case HID_REQ_GET_REPORT:
-+ return hdev->hid_get_raw_report(hdev, reportnum, buf, len, rtype);
-+ }
-+
-+ return -ENOSYS;
-+}
-+
-+static inline int hid_hw_output_report(struct hid_device *hdev, __u8 *buf,
-+ size_t len)
-+{
-+ if (len < 1 || len > HID_MAX_BUFFER_SIZE || !buf)
-+ return -EINVAL;
-+
-+ return hdev->hid_output_raw_report(hdev, buf, len, HID_OUTPUT_REPORT);
-+}
-+
-+#endif
diff --git a/drivers/hid/hid-core.c b/drivers/hid/hid-core.c
index 253fe23..543dd1f 100644
--- a/drivers/hid/hid-core.c
@@ -169,7 +116,7 @@ index 0000000..a4f04d4
+#include <linux/sched.h>
+#include "hid-ids.h"
+
-+#include "compat.h"
++/* removed backported compat.h include */
+
+#define RMI_MOUSE_REPORT_ID 0x01 /* Mouse emulation Report */
+#define RMI_WRITE_REPORT_ID 0x09 /* Output Report */