summaryrefslogtreecommitdiffstats
path: root/drivers/input
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2019-03-04 02:21:28 -0500
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2019-03-04 02:38:38 -0500
commitfc226eb23e62731712b30114479f4a791fee4c00 (patch)
tree05fb8bb399ce808eae534a39020ce1a44870eb67 /drivers/input
parent44466306ebecc73c68835f5fe27d119591a1ab5c (diff)
Input: edt-ft5x06 - enable ACPI enumeration
ACPI allows to enumerate specific devices by using compatible strings. Enable that enumeration for EDT touchscreen devices. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input')
-rw-r--r--drivers/input/touchscreen/edt-ft5x06.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/input/touchscreen/edt-ft5x06.c b/drivers/input/touchscreen/edt-ft5x06.c
index 702bfda7ee77..a45bf6be1e40 100644
--- a/drivers/input/touchscreen/edt-ft5x06.c
+++ b/drivers/input/touchscreen/edt-ft5x06.c
@@ -39,7 +39,6 @@
39#include <linux/gpio/consumer.h> 39#include <linux/gpio/consumer.h>
40#include <linux/input/mt.h> 40#include <linux/input/mt.h>
41#include <linux/input/touchscreen.h> 41#include <linux/input/touchscreen.h>
42#include <linux/of_device.h>
43 42
44#define WORK_REGISTER_THRESHOLD 0x00 43#define WORK_REGISTER_THRESHOLD 0x00
45#define WORK_REGISTER_REPORT_RATE 0x08 44#define WORK_REGISTER_REPORT_RATE 0x08
@@ -1073,7 +1072,7 @@ static int edt_ft5x06_ts_probe(struct i2c_client *client,
1073 return -ENOMEM; 1072 return -ENOMEM;
1074 } 1073 }
1075 1074
1076 chip_data = of_device_get_match_data(&client->dev); 1075 chip_data = device_get_match_data(&client->dev);
1077 if (!chip_data) 1076 if (!chip_data)
1078 chip_data = (const struct edt_i2c_chip_data *)id->driver_data; 1077 chip_data = (const struct edt_i2c_chip_data *)id->driver_data;
1079 if (!chip_data || !chip_data->max_support_points) { 1078 if (!chip_data || !chip_data->max_support_points) {
@@ -1254,7 +1253,6 @@ static const struct i2c_device_id edt_ft5x06_ts_id[] = {
1254}; 1253};
1255MODULE_DEVICE_TABLE(i2c, edt_ft5x06_ts_id); 1254MODULE_DEVICE_TABLE(i2c, edt_ft5x06_ts_id);
1256 1255
1257#ifdef CONFIG_OF
1258static const struct of_device_id edt_ft5x06_of_match[] = { 1256static const struct of_device_id edt_ft5x06_of_match[] = {
1259 { .compatible = "edt,edt-ft5206", .data = &edt_ft5x06_data }, 1257 { .compatible = "edt,edt-ft5206", .data = &edt_ft5x06_data },
1260 { .compatible = "edt,edt-ft5306", .data = &edt_ft5x06_data }, 1258 { .compatible = "edt,edt-ft5306", .data = &edt_ft5x06_data },
@@ -1266,12 +1264,11 @@ static const struct of_device_id edt_ft5x06_of_match[] = {
1266 { /* sentinel */ } 1264 { /* sentinel */ }
1267}; 1265};
1268MODULE_DEVICE_TABLE(of, edt_ft5x06_of_match); 1266MODULE_DEVICE_TABLE(of, edt_ft5x06_of_match);
1269#endif
1270 1267
1271static struct i2c_driver edt_ft5x06_ts_driver = { 1268static struct i2c_driver edt_ft5x06_ts_driver = {
1272 .driver = { 1269 .driver = {
1273 .name = "edt_ft5x06", 1270 .name = "edt_ft5x06",
1274 .of_match_table = of_match_ptr(edt_ft5x06_of_match), 1271 .of_match_table = edt_ft5x06_of_match,
1275 .pm = &edt_ft5x06_ts_pm_ops, 1272 .pm = &edt_ft5x06_ts_pm_ops,
1276 }, 1273 },
1277 .id_table = edt_ft5x06_ts_id, 1274 .id_table = edt_ft5x06_ts_id,