aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/touchscreen/hideep.c
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2019-08-12 00:00:16 -0700
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2019-08-12 00:03:11 -0700
commit104c995fd6ab7c2bdb275a54334123184fd2efb2 (patch)
tree3564393dd17af82d474d4cc8e0c870ca44bd5ba8 /drivers/input/touchscreen/hideep.c
parentInput: mpr121 - switch to use device_property_count_u32() (diff)
downloadlinux-dev-104c995fd6ab7c2bdb275a54334123184fd2efb2.tar.xz
linux-dev-104c995fd6ab7c2bdb275a54334123184fd2efb2.zip
Input: hideep - switch to use device_property_count_u32()
Use use device_property_count_u32() directly, that makes code neater. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input/touchscreen/hideep.c')
-rw-r--r--drivers/input/touchscreen/hideep.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/input/touchscreen/hideep.c b/drivers/input/touchscreen/hideep.c
index 84fbbf415c43..ddad4a82a5e5 100644
--- a/drivers/input/touchscreen/hideep.c
+++ b/drivers/input/touchscreen/hideep.c
@@ -811,8 +811,7 @@ static int hideep_init_input(struct hideep_ts *ts)
if (error)
return error;
- ts->key_num = device_property_read_u32_array(dev, "linux,keycodes",
- NULL, 0);
+ ts->key_num = device_property_count_u32(dev, "linux,keycodes");
if (ts->key_num > HIDEEP_KEY_MAX) {
dev_err(dev, "too many keys defined: %d\n",
ts->key_num);