summaryrefslogtreecommitdiff
path: root/drivers/input
diff options
context:
space:
mode:
authorMao Li <maol@codeaurora.org>2016-02-24 14:04:18 +0800
committerDavid Keitel <dkeitel@codeaurora.org>2016-03-25 16:02:35 -0700
commit954d86462266ec5e3fb1122cf01b9a339947cb00 (patch)
treea916d181f736e947e8bead19ef44b4243c2a5d43 /drivers/input
parent07ceb38173c00cc36d74500ed1742a8daf2d66a0 (diff)
input: synaptics_dsx_2.6: update driver to enable touch S332U
Synaptics reference driver V2.6 is being cleaned up to enable touch controller S332U. Add Kconfig and Makefile changes to enable Synaptics dsx V2.6 driver's compilation. CRs-Fixed: 943896 Change-Id: I7e79e9ee321b7a7c90d27f065281dc73cee65391 Signed-off-by: Mao Li <maol@codeaurora.org>
Diffstat (limited to 'drivers/input')
-rw-r--r--drivers/input/touchscreen/Kconfig1
-rw-r--r--drivers/input/touchscreen/Makefile1
-rw-r--r--drivers/input/touchscreen/synaptics_dsx_2.6/Kconfig66
-rw-r--r--drivers/input/touchscreen/synaptics_dsx_2.6/Makefile22
-rw-r--r--drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_active_pen.c2
-rw-r--r--drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_core.c23
-rw-r--r--drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_core.h4
-rw-r--r--drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_fw_update.c18
-rw-r--r--drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_gesture.c2
-rw-r--r--drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_i2c.c10
-rw-r--r--drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_proximity.c2
-rw-r--r--drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_rmi_dev.c22
-rw-r--r--drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_rmi_hid_i2c.c10
-rw-r--r--drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_spi.c10
-rw-r--r--drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_test_reporting.c2
-rw-r--r--drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_video.c2
16 files changed, 102 insertions, 95 deletions
diff --git a/drivers/input/touchscreen/Kconfig b/drivers/input/touchscreen/Kconfig
index fa87a7733074..93ad9df1f294 100644
--- a/drivers/input/touchscreen/Kconfig
+++ b/drivers/input/touchscreen/Kconfig
@@ -12,6 +12,7 @@ menuconfig INPUT_TOUCHSCREEN
if INPUT_TOUCHSCREEN
source "drivers/input/touchscreen/synaptics_dsx/Kconfig"
+source "drivers/input/touchscreen/synaptics_dsx_2.6/Kconfig"
config OF_TOUCHSCREEN
def_tristate INPUT
diff --git a/drivers/input/touchscreen/Makefile b/drivers/input/touchscreen/Makefile
index 66f45d0e2eef..aaf7f587ed19 100644
--- a/drivers/input/touchscreen/Makefile
+++ b/drivers/input/touchscreen/Makefile
@@ -68,6 +68,7 @@ obj-$(CONFIG_TOUCHSCREEN_STMPE) += stmpe-ts.o
obj-$(CONFIG_TOUCHSCREEN_SUN4I) += sun4i-ts.o
obj-$(CONFIG_TOUCHSCREEN_SUR40) += sur40.o
obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_v21) += synaptics_dsx/
+obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_v26) += synaptics_dsx_2.6/
obj-$(CONFIG_TOUCHSCREEN_TI_AM335X_TSC) += ti_am335x_tsc.o
obj-$(CONFIG_TOUCHSCREEN_TOUCHIT213) += touchit213.o
obj-$(CONFIG_TOUCHSCREEN_TOUCHRIGHT) += touchright.o
diff --git a/drivers/input/touchscreen/synaptics_dsx_2.6/Kconfig b/drivers/input/touchscreen/synaptics_dsx_2.6/Kconfig
index b40f26e0a555..78b995ec7c8a 100644
--- a/drivers/input/touchscreen/synaptics_dsx_2.6/Kconfig
+++ b/drivers/input/touchscreen/synaptics_dsx_2.6/Kconfig
@@ -1,33 +1,33 @@
#
-# Synaptics DSX touchscreen driver configuration
+# Synaptics DSX v2.6 touchscreen driver configuration
#
-menuconfig TOUCHSCREEN_SYNAPTICS_DSX
- bool "Synaptics DSX touchscreen"
- default N
+menuconfig TOUCHSCREEN_SYNAPTICS_DSX_v26
+ bool "Synaptics DSX v2.6 touchscreen"
+ default y
help
Say Y here if you have a Synaptics DSX touchscreen connected
to your system.
If unsure, say N.
-if TOUCHSCREEN_SYNAPTICS_DSX
+if TOUCHSCREEN_SYNAPTICS_DSX_v26
choice
- default TOUCHSCREEN_SYNAPTICS_DSX_I2C
- prompt "Synaptics DSX bus interface"
-config TOUCHSCREEN_SYNAPTICS_DSX_I2C
+ default TOUCHSCREEN_SYNAPTICS_DSX_I2C_v26
+ prompt "Synaptics DSX v2.6 bus interface"
+config TOUCHSCREEN_SYNAPTICS_DSX_I2C_v26
bool "RMI over I2C"
depends on I2C
-config TOUCHSCREEN_SYNAPTICS_DSX_SPI
+config TOUCHSCREEN_SYNAPTICS_DSX_SPI_v26
bool "RMI over SPI"
depends on SPI_MASTER
-config TOUCHSCREEN_SYNAPTICS_DSX_RMI_HID_I2C
+config TOUCHSCREEN_SYNAPTICS_DSX_RMI_HID_I2C_v26
bool "HID over I2C"
depends on I2C
endchoice
-config TOUCHSCREEN_SYNAPTICS_DSX_CORE
- tristate "Synaptics DSX core driver module"
+config TOUCHSCREEN_SYNAPTICS_DSX_CORE_v26
+ tristate "Synaptics DSX v2.6 core driver module"
depends on I2C || SPI_MASTER
help
Say Y here to enable basic touch reporting functionality.
@@ -37,9 +37,9 @@ config TOUCHSCREEN_SYNAPTICS_DSX_CORE
To compile this driver as a module, choose M here: the
module will be called synaptics_dsx_core.
-config TOUCHSCREEN_SYNAPTICS_DSX_RMI_DEV
- tristate "Synaptics DSX RMI device module"
- depends on TOUCHSCREEN_SYNAPTICS_DSX_CORE
+config TOUCHSCREEN_SYNAPTICS_DSX_RMI_DEV_v26
+ tristate "Synaptics DSX v2.6 RMI device module"
+ depends on TOUCHSCREEN_SYNAPTICS_DSX_CORE_v26
help
Say Y here to enable support for direct RMI register access.
@@ -48,9 +48,9 @@ config TOUCHSCREEN_SYNAPTICS_DSX_RMI_DEV
To compile this driver as a module, choose M here: the
module will be called synaptics_dsx_rmi_dev.
-config TOUCHSCREEN_SYNAPTICS_DSX_FW_UPDATE
- tristate "Synaptics DSX firmware update module"
- depends on TOUCHSCREEN_SYNAPTICS_DSX_CORE
+config TOUCHSCREEN_SYNAPTICS_DSX_FW_UPDATE_v26
+ tristate "Synaptics DSX v2.6 firmware update module"
+ depends on TOUCHSCREEN_SYNAPTICS_DSX_CORE_v26
help
Say Y here to enable support for doing firmware update.
@@ -59,9 +59,9 @@ config TOUCHSCREEN_SYNAPTICS_DSX_FW_UPDATE
To compile this driver as a module, choose M here: the
module will be called synaptics_dsx_fw_update.
-config TOUCHSCREEN_SYNAPTICS_DSX_TEST_REPORTING
- tristate "Synaptics DSX test reporting module"
- depends on TOUCHSCREEN_SYNAPTICS_DSX_CORE
+config TOUCHSCREEN_SYNAPTICS_DSX_TEST_REPORTING_v26
+ tristate "Synaptics DSX v2.6 test reporting module"
+ depends on TOUCHSCREEN_SYNAPTICS_DSX_CORE_v26
help
Say Y here to enable support for retrieving production test reports.
@@ -70,9 +70,9 @@ config TOUCHSCREEN_SYNAPTICS_DSX_TEST_REPORTING
To compile this driver as a module, choose M here: the
module will be called synaptics_dsx_test_reporting.
-config TOUCHSCREEN_SYNAPTICS_DSX_PROXIMITY
- tristate "Synaptics DSX proximity module"
- depends on TOUCHSCREEN_SYNAPTICS_DSX_CORE
+config TOUCHSCREEN_SYNAPTICS_DSX_PROXIMITY_v26
+ tristate "Synaptics DSX v2.6 proximity module"
+ depends on TOUCHSCREEN_SYNAPTICS_DSX_CORE_v26
help
Say Y here to enable support for proximity functionality.
@@ -81,9 +81,9 @@ config TOUCHSCREEN_SYNAPTICS_DSX_PROXIMITY
To compile this driver as a module, choose M here: the
module will be called synaptics_dsx_proximity.
-config TOUCHSCREEN_SYNAPTICS_DSX_ACTIVE_PEN
- tristate "Synaptics DSX active pen module"
- depends on TOUCHSCREEN_SYNAPTICS_DSX_CORE
+config TOUCHSCREEN_SYNAPTICS_DSX_ACTIVE_PEN_v26
+ tristate "Synaptics DSX v2.6 active pen module"
+ depends on TOUCHSCREEN_SYNAPTICS_DSX_CORE_v26
help
Say Y here to enable support for active pen functionality.
@@ -92,9 +92,9 @@ config TOUCHSCREEN_SYNAPTICS_DSX_ACTIVE_PEN
To compile this driver as a module, choose M here: the
module will be called synaptics_dsx_active_pen.
-config TOUCHSCREEN_SYNAPTICS_DSX_GESTURE
- tristate "Synaptics DSX user defined gesture module"
- depends on TOUCHSCREEN_SYNAPTICS_DSX_CORE
+config TOUCHSCREEN_SYNAPTICS_DSX_GESTURE_v26
+ tristate "Synaptics DSX v2.6 user defined gesture module"
+ depends on TOUCHSCREEN_SYNAPTICS_DSX_CORE_v26
help
Say Y here to enable support for user defined gesture functionality.
@@ -103,9 +103,9 @@ config TOUCHSCREEN_SYNAPTICS_DSX_GESTURE
To compile this driver as a module, choose M here: the
module will be called synaptics_dsx_gesture.
-config TOUCHSCREEN_SYNAPTICS_DSX_VIDEO
- tristate "Synaptics DSX video module"
- depends on TOUCHSCREEN_SYNAPTICS_DSX_CORE
+config TOUCHSCREEN_SYNAPTICS_DSX_VIDEO_v26
+ tristate "Synaptics DSX v2.6 video module"
+ depends on TOUCHSCREEN_SYNAPTICS_DSX_CORE_v26
help
Say Y here to enable support for video communication functionality.
diff --git a/drivers/input/touchscreen/synaptics_dsx_2.6/Makefile b/drivers/input/touchscreen/synaptics_dsx_2.6/Makefile
index 515bc17e1563..e5e72153f8c4 100644
--- a/drivers/input/touchscreen/synaptics_dsx_2.6/Makefile
+++ b/drivers/input/touchscreen/synaptics_dsx_2.6/Makefile
@@ -4,14 +4,14 @@
# Each configuration option enables a list of files.
-obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_I2C) += synaptics_dsx_i2c.o
-obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_SPI) += synaptics_dsx_spi.o
-obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_RMI_HID_I2C) += synaptics_dsx_rmi_hid_i2c.o
-obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_CORE) += synaptics_dsx_core.o
-obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_RMI_DEV) += synaptics_dsx_rmi_dev.o
-obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_FW_UPDATE) += synaptics_dsx_fw_update.o
-obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_TEST_REPORTING) += synaptics_dsx_test_reporting.o
-obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_PROXIMITY) += synaptics_dsx_proximity.o
-obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_ACTIVE_PEN) += synaptics_dsx_active_pen.o
-obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_GESTURE) += synaptics_dsx_gesture.o
-obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_VIDEO) += synaptics_dsx_video.o
+obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_I2C_v26) += synaptics_dsx_i2c.o
+obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_SPI_v26) += synaptics_dsx_spi.o
+obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_RMI_HID_I2C_v26) += synaptics_dsx_rmi_hid_i2c.o
+obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_CORE_v26) += synaptics_dsx_core.o
+obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_RMI_DEV_v26) += synaptics_dsx_rmi_dev.o
+obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_FW_UPDATE_v26) += synaptics_dsx_fw_update.o
+obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_TEST_REPORTING_v26) += synaptics_dsx_test_reporting.o
+obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_PROXIMITY_v26) += synaptics_dsx_proximity.o
+obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_ACTIVE_PEN_v26) += synaptics_dsx_active_pen.o
+obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_GESTURE_v26) += synaptics_dsx_gesture.o
+obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_VIDEO_v26) += synaptics_dsx_video.o
diff --git a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_active_pen.c b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_active_pen.c
index 0e617084e911..db5324ab09fe 100644
--- a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_active_pen.c
+++ b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_active_pen.c
@@ -38,7 +38,7 @@
#include <linux/delay.h>
#include <linux/input.h>
#include <linux/platform_device.h>
-#include <linux/input/synaptics_dsx.h>
+#include <linux/input/synaptics_dsx_v2_6.h>
#include "synaptics_dsx_core.h"
#define APEN_PHYS_NAME "synaptics_dsx/active_pen"
diff --git a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_core.c b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_core.c
index 158329925a32..07d2c479aa39 100644
--- a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_core.c
+++ b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_core.c
@@ -40,7 +40,7 @@
#include <linux/gpio.h>
#include <linux/platform_device.h>
#include <linux/regulator/consumer.h>
-#include <linux/input/synaptics_dsx.h>
+#include <linux/input/synaptics_dsx_v2_6.h>
#include "synaptics_dsx_core.h"
#ifdef KERNEL_ABOVE_2_6_38
#include <linux/input/mt.h>
@@ -67,11 +67,11 @@
#define F12_DATA_15_WORKAROUND
#define IGNORE_FN_INIT_FAILURE
-/*
+
#define FB_READY_RESET
#define FB_READY_WAIT_MS 100
#define FB_READY_TIMEOUT_S 30
-*/
+
#define RPT_TYPE (1 << 0)
#define RPT_X_LSB (1 << 1)
#define RPT_X_MSB (1 << 2)
@@ -596,7 +596,7 @@ static struct synaptics_rmi4_exp_fn_data exp_data;
static struct synaptics_dsx_button_map *vir_button_map;
static struct device_attribute attrs[] = {
- __ATTR(reset, S_IWUGO,
+ __ATTR(reset, S_IRUGO | S_IWUSR | S_IWGRP,
synaptics_rmi4_show_error,
synaptics_rmi4_f01_reset_store),
__ATTR(productinfo, S_IRUGO,
@@ -608,13 +608,13 @@ static struct device_attribute attrs[] = {
__ATTR(flashprog, S_IRUGO,
synaptics_rmi4_f01_flashprog_show,
synaptics_rmi4_store_error),
- __ATTR(0dbutton, (S_IRUGO | S_IWUGO),
+ __ATTR(0dbutton, (S_IRUGO | S_IWUSR | S_IWGRP),
synaptics_rmi4_0dbutton_show,
synaptics_rmi4_0dbutton_store),
- __ATTR(suspend, S_IWUGO,
+ __ATTR(suspend, S_IRUGO | S_IWUSR | S_IWGRP,
synaptics_rmi4_show_error,
synaptics_rmi4_suspend_store),
- __ATTR(wake_gesture, (S_IRUGO | S_IWUGO),
+ __ATTR(wake_gesture, (S_IRUGO | S_IWUSR | S_IWGRP),
synaptics_rmi4_wake_gesture_show,
synaptics_rmi4_wake_gesture_store),
};
@@ -1422,6 +1422,11 @@ static void synaptics_rmi4_sensor_report(struct synaptics_rmi4_data *rmi4_data,
rmi = &(rmi4_data->rmi4_mod_info);
+ if (rmi4_data->stay_awake) {
+ msleep(30);
+ return;
+ }
+
/*
* Get interrupt status information from F01 Data1 register to
* determine the source(s) that are flagging the interrupt.
@@ -4306,7 +4311,7 @@ static int __init synaptics_rmi4_init(void)
{
int retval;
- retval = synaptics_rmi4_bus_init();
+ retval = synaptics_rmi4_bus_init_v26();
if (retval)
return retval;
@@ -4317,7 +4322,7 @@ static void __exit synaptics_rmi4_exit(void)
{
platform_driver_unregister(&synaptics_rmi4_driver);
- synaptics_rmi4_bus_exit();
+ synaptics_rmi4_bus_exit_v26();
return;
}
diff --git a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_core.h b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_core.h
index 1b4079cfda6a..0de0e9905cb4 100644
--- a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_core.h
+++ b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_core.h
@@ -405,9 +405,9 @@ struct synaptics_rmi4_exp_fn {
unsigned char intr_mask);
};
-int synaptics_rmi4_bus_init(void);
+int synaptics_rmi4_bus_init_v26(void);
-void synaptics_rmi4_bus_exit(void);
+void synaptics_rmi4_bus_exit_v26(void);
void synaptics_rmi4_new_function(struct synaptics_rmi4_exp_fn *exp_fn_module,
bool insert);
diff --git a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_fw_update.c b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_fw_update.c
index 5dd0ec4e53cc..34201f3957c3 100644
--- a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_fw_update.c
+++ b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_fw_update.c
@@ -39,7 +39,7 @@
#include <linux/input.h>
#include <linux/firmware.h>
#include <linux/platform_device.h>
-#include <linux/input/synaptics_dsx.h>
+#include <linux/input/synaptics_dsx_v2_6.h>
#include "synaptics_dsx_core.h"
#define FW_IMAGE_NAME "synaptics/startup_fw_update.img"
@@ -661,25 +661,25 @@ static struct bin_attribute dev_attr_data = {
};
static struct device_attribute attrs[] = {
- __ATTR(dorecovery, S_IWUGO,
+ __ATTR(dorecovery, S_IRUGO | S_IWUSR | S_IWGRP,
synaptics_rmi4_show_error,
fwu_sysfs_do_recovery_store),
- __ATTR(doreflash, S_IWUGO,
+ __ATTR(doreflash, S_IRUGO | S_IWUSR | S_IWGRP,
synaptics_rmi4_show_error,
fwu_sysfs_do_reflash_store),
- __ATTR(writeconfig, S_IWUGO,
+ __ATTR(writeconfig, S_IRUGO | S_IWUSR | S_IWGRP,
synaptics_rmi4_show_error,
fwu_sysfs_write_config_store),
- __ATTR(readconfig, S_IWUGO,
+ __ATTR(readconfig, S_IRUGO | S_IWUSR | S_IWGRP,
synaptics_rmi4_show_error,
fwu_sysfs_read_config_store),
- __ATTR(configarea, S_IWUGO,
+ __ATTR(configarea, S_IRUGO | S_IWUSR | S_IWGRP,
synaptics_rmi4_show_error,
fwu_sysfs_config_area_store),
- __ATTR(imagename, S_IWUGO,
+ __ATTR(imagename, S_IRUGO | S_IWUSR | S_IWGRP,
synaptics_rmi4_show_error,
fwu_sysfs_image_name_store),
- __ATTR(imagesize, S_IWUGO,
+ __ATTR(imagesize, S_IRUGO | S_IWUSR | S_IWGRP,
synaptics_rmi4_show_error,
fwu_sysfs_image_size_store),
__ATTR(blocksize, S_IRUGO,
@@ -703,7 +703,7 @@ static struct device_attribute attrs[] = {
__ATTR(guestcodeblockcount, S_IRUGO,
fwu_sysfs_guest_code_block_count_show,
synaptics_rmi4_store_error),
- __ATTR(writeguestcode, S_IWUGO,
+ __ATTR(writeguestcode, S_IRUGO | S_IWUSR | S_IWGRP,
synaptics_rmi4_show_error,
fwu_sysfs_write_guest_code_store),
};
diff --git a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_gesture.c b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_gesture.c
index 7630a60737cd..dcada834c6cb 100644
--- a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_gesture.c
+++ b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_gesture.c
@@ -38,7 +38,7 @@
#include <linux/delay.h>
#include <linux/input.h>
#include <linux/platform_device.h>
-#include <linux/input/synaptics_dsx.h>
+#include <linux/input/synaptics_dsx_v2_6.h>
#include "synaptics_dsx_core.h"
#define GESTURE_PHYS_NAME "synaptics_dsx/gesture"
diff --git a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_i2c.c b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_i2c.c
index 3be3bcaab29a..784de607aa08 100644
--- a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_i2c.c
+++ b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_i2c.c
@@ -40,7 +40,7 @@
#include <linux/types.h>
#include <linux/of_gpio.h>
#include <linux/platform_device.h>
-#include <linux/input/synaptics_dsx.h>
+#include <linux/input/synaptics_dsx_v2_6.h>
#include "synaptics_dsx_core.h"
#define SYN_I2C_RETRY_TIMES 10
@@ -625,13 +625,13 @@ static struct i2c_driver synaptics_rmi4_i2c_driver = {
.id_table = synaptics_rmi4_id_table,
};
-int synaptics_rmi4_bus_init(void)
+int synaptics_rmi4_bus_init_v26(void)
{
return i2c_add_driver(&synaptics_rmi4_i2c_driver);
}
-EXPORT_SYMBOL(synaptics_rmi4_bus_init);
+EXPORT_SYMBOL(synaptics_rmi4_bus_init_v26);
-void synaptics_rmi4_bus_exit(void)
+void synaptics_rmi4_bus_exit_v26(void)
{
kfree(wr_buf);
@@ -639,7 +639,7 @@ void synaptics_rmi4_bus_exit(void)
return;
}
-EXPORT_SYMBOL(synaptics_rmi4_bus_exit);
+EXPORT_SYMBOL(synaptics_rmi4_bus_exit_v26);
MODULE_AUTHOR("Synaptics, Inc.");
MODULE_DESCRIPTION("Synaptics DSX I2C Bus Support Module");
diff --git a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_proximity.c b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_proximity.c
index 2507c7743d9a..d9e27c306af5 100644
--- a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_proximity.c
+++ b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_proximity.c
@@ -38,7 +38,7 @@
#include <linux/delay.h>
#include <linux/input.h>
#include <linux/platform_device.h>
-#include <linux/input/synaptics_dsx.h>
+#include <linux/input/synaptics_dsx_v2_6.h>
#include "synaptics_dsx_core.h"
#define PROX_PHYS_NAME "synaptics_dsx/proximity"
diff --git a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_rmi_dev.c b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_rmi_dev.c
index 9d19bda545f7..582e43666b17 100644
--- a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_rmi_dev.c
+++ b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_rmi_dev.c
@@ -43,7 +43,7 @@
#include <linux/uaccess.h>
#include <linux/cdev.h>
#include <linux/platform_device.h>
-#include <linux/input/synaptics_dsx.h>
+#include <linux/input/synaptics_dsx_v2_6.h>
#include "synaptics_dsx_core.h"
#define CHAR_DEVICE_NAME "rmi"
@@ -118,7 +118,7 @@ struct rmidev_data {
static struct bin_attribute attr_data = {
.attr = {
.name = "data",
- .mode = (S_IRUGO | S_IWUGO),
+ .mode = (S_IRUGO | S_IWUSR),
},
.size = 0,
.read = rmidev_sysfs_data_show,
@@ -126,25 +126,25 @@ static struct bin_attribute attr_data = {
};
static struct device_attribute attrs[] = {
- __ATTR(open, S_IWUGO,
+ __ATTR(open, S_IRUGO | S_IWUSR | S_IWGRP,
synaptics_rmi4_show_error,
rmidev_sysfs_open_store),
- __ATTR(release, S_IWUGO,
+ __ATTR(release, S_IRUGO | S_IWUSR | S_IWGRP,
synaptics_rmi4_show_error,
rmidev_sysfs_release_store),
__ATTR(attn_state, S_IRUGO,
rmidev_sysfs_attn_state_show,
synaptics_rmi4_store_error),
- __ATTR(pid, S_IRUGO | S_IWUGO,
+ __ATTR(pid, S_IRUGO | S_IRUGO | S_IWUSR | S_IWGRP,
rmidev_sysfs_pid_show,
rmidev_sysfs_pid_store),
- __ATTR(term, S_IWUGO,
+ __ATTR(term, S_IRUGO | S_IWUSR | S_IWGRP,
synaptics_rmi4_show_error,
rmidev_sysfs_term_store),
- __ATTR(intr_mask, S_IRUGO | S_IWUGO,
+ __ATTR(intr_mask, S_IRUGO,
rmidev_sysfs_intr_mask_show,
rmidev_sysfs_intr_mask_store),
- __ATTR(concurrent, S_IRUGO | S_IWUGO,
+ __ATTR(concurrent, S_IRUGO,
rmidev_sysfs_concurrent_show,
rmidev_sysfs_concurrent_store),
};
@@ -155,7 +155,7 @@ static struct class *rmidev_device_class;
static struct rmidev_handle *rmidev;
-DECLARE_COMPLETION(rmidev_remove_complete);
+DECLARE_COMPLETION(rmidev_remove_complete_v26);
static irqreturn_t rmidev_sysfs_irq(int irq, void *data)
{
@@ -1016,7 +1016,7 @@ static void rmidev_remove_device(struct synaptics_rmi4_data *rmi4_data)
rmidev = NULL;
exit:
- complete(&rmidev_remove_complete);
+ complete(&rmidev_remove_complete_v26);
return;
}
@@ -1045,7 +1045,7 @@ static void __exit rmidev_module_exit(void)
{
synaptics_rmi4_new_function(&rmidev_module, false);
- wait_for_completion(&rmidev_remove_complete);
+ wait_for_completion(&rmidev_remove_complete_v26);
return;
}
diff --git a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_rmi_hid_i2c.c b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_rmi_hid_i2c.c
index df6e357a8ec3..7e02487ece5a 100644
--- a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_rmi_hid_i2c.c
+++ b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_rmi_hid_i2c.c
@@ -42,7 +42,7 @@
#include <linux/types.h>
#include <linux/of_gpio.h>
#include <linux/platform_device.h>
-#include <linux/input/synaptics_dsx.h>
+#include <linux/input/synaptics_dsx_v2_6.h>
#include "synaptics_dsx_core.h"
#define SYN_I2C_RETRY_TIMES 10
@@ -987,19 +987,19 @@ static struct i2c_driver synaptics_rmi4_i2c_driver = {
.id_table = synaptics_rmi4_id_table,
};
-int synaptics_rmi4_bus_init(void)
+int synaptics_rmi4_bus_init_v26(void)
{
return i2c_add_driver(&synaptics_rmi4_i2c_driver);
}
-EXPORT_SYMBOL(synaptics_rmi4_bus_init);
+EXPORT_SYMBOL(synaptics_rmi4_bus_init_v26);
-void synaptics_rmi4_bus_exit(void)
+void synaptics_rmi4_bus_exit_v26(void)
{
i2c_del_driver(&synaptics_rmi4_i2c_driver);
return;
}
-EXPORT_SYMBOL(synaptics_rmi4_bus_exit);
+EXPORT_SYMBOL(synaptics_rmi4_bus_exit_v26);
MODULE_AUTHOR("Synaptics, Inc.");
MODULE_DESCRIPTION("Synaptics DSX I2C Bus Support Module");
diff --git a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_spi.c b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_spi.c
index d5d9c3cbf633..382a3dd029d7 100644
--- a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_spi.c
+++ b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_spi.c
@@ -40,7 +40,7 @@
#include <linux/types.h>
#include <linux/of_gpio.h>
#include <linux/platform_device.h>
-#include <linux/input/synaptics_dsx.h>
+#include <linux/input/synaptics_dsx_v2_6.h>
#include "synaptics_dsx_core.h"
#define SPI_READ 0x80
@@ -615,19 +615,19 @@ static struct spi_driver synaptics_rmi4_spi_driver = {
};
-int synaptics_rmi4_bus_init(void)
+int synaptics_rmi4_bus_init_v26(void)
{
return spi_register_driver(&synaptics_rmi4_spi_driver);
}
-EXPORT_SYMBOL(synaptics_rmi4_bus_init);
+EXPORT_SYMBOL(synaptics_rmi4_bus_init_v26);
-void synaptics_rmi4_bus_exit(void)
+void synaptics_rmi4_bus_exit_v26(void)
{
spi_unregister_driver(&synaptics_rmi4_spi_driver);
return;
}
-EXPORT_SYMBOL(synaptics_rmi4_bus_exit);
+EXPORT_SYMBOL(synaptics_rmi4_bus_exit_v26);
MODULE_AUTHOR("Synaptics, Inc.");
MODULE_DESCRIPTION("Synaptics DSX SPI Bus Support Module");
diff --git a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_test_reporting.c b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_test_reporting.c
index 6ed7bd62a6a4..a401457c3e4a 100644
--- a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_test_reporting.c
+++ b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_test_reporting.c
@@ -40,7 +40,7 @@
#include <linux/ctype.h>
#include <linux/hrtimer.h>
#include <linux/platform_device.h>
-#include <linux/input/synaptics_dsx.h>
+#include <linux/input/synaptics_dsx_v2_6.h>
#include "synaptics_dsx_core.h"
#define SYSFS_FOLDER_NAME "f54"
diff --git a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_video.c b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_video.c
index 493410ee0472..0916529e64e4 100644
--- a/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_video.c
+++ b/drivers/input/touchscreen/synaptics_dsx_2.6/synaptics_dsx_video.c
@@ -37,7 +37,7 @@
#include <linux/delay.h>
#include <linux/input.h>
#include <linux/platform_device.h>
-#include <linux/input/synaptics_dsx.h>
+#include <linux/input/synaptics_dsx_v2_6.h>
#include "synaptics_dsx_core.h"
#define SYSFS_FOLDER_NAME "video"