Re: [PATCH] Input: ad714x: Convert to using managed resources

2015-09-12 Thread Vaishali Thakkar
On Sat, Sep 12, 2015 at 11:52 PM, Dmitry Torokhov wrote: > On Sat, Sep 12, 2015 at 08:26:18PM +0530, Vaishali Thakkar wrote: >> Use managed resource functions devm_request_threaded_irq, >> devm_inpute_allocate_device and devm_kzalloc to simplify >> error handling. Also, remove use of input_unregis

Re: [PATCH] Input: ad714x: Convert to using managed resources

2015-09-12 Thread Dmitry Torokhov
On Sat, Sep 12, 2015 at 08:26:18PM +0530, Vaishali Thakkar wrote: > Use managed resource functions devm_request_threaded_irq, > devm_inpute_allocate_device and devm_kzalloc to simplify > error handling. Also, remove use of input_unregister_device > as input_register_device itself handles it and wor

Re: [PATCH 2/4] devicetree: bindings: Add header file with evdev type and abs/rel code defines

2015-09-12 Thread Dmitry Torokhov
On Thu, Sep 10, 2015 at 3:48 PM, Rob Herring wrote: > +Ian > > On 09/10/2015 01:50 PM, Hans de Goede wrote: >> Hi, >> >> On 10-09-15 20:42, Dmitry Torokhov wrote: >>> On Thu, Sep 10, 2015 at 11:40 AM, Hans de Goede >>> wrote: Hi, On 10-09-15 20:34, Dmitry Torokhov wrote: >

[PATCH 2/6] Input: edt-ft5x06 - drop parsing of irq gpio

2015-09-12 Thread Dmitry Torokhov
The driver does not use irq gpio as gpio, but rather relies on I2C core or board code to set up client's structure IRQ line, so let's stop trying to locate the resource and parse it. Signed-off-by: Dmitry Torokhov --- drivers/input/touchscreen/edt-ft5x06.c | 10 -- 1 file changed, 10 del

[PATCH 5/6] Input: edt-ft5x06 - do not hardcode interrupt trigger type

2015-09-12 Thread Dmitry Torokhov
Instead of hardcoding IRQ trigger type to IRQF_TRIGGER_FALLING, let's respect settings specified in device tree. To be compatible with older DTSes, if trigger type is not set up in DTS we'll set it to default (falling edge). Signed-off-by: Dmitry Torokhov --- .../devicetree/bindings/input/touchs

[PATCH 3/6] Input: edt-ft5x06 - remove support for platform data

2015-09-12 Thread Dmitry Torokhov
We do not have any users of platform data in the tree and all newer platforms are either DT or ACPI, so let's drop handling of platform data. Signed-off-by: Dmitry Torokhov --- drivers/input/touchscreen/edt-ft5x06.c | 41 -- include/linux/input/edt-ft5x06.h

[PATCH 6/6] ARM: dts: set up trigger type for edt-ft5x06 interrupts

2015-09-12 Thread Dmitry Torokhov
Now that the driver respects IRQ trigger settings from device tree, let's fix them up in individual DTSes (note that the driver is still compatible with older DTSes). Signed-off-by: Dmitry Torokhov --- arch/arm/boot/dts/am437x-sk-evm.dts | 2 +- arch/arm/boot/dts/imx28-tx28.dts | 3 ++- a

[PATCH 4/6] Input: edt-ft5x06 - use generic properties API

2015-09-12 Thread Dmitry Torokhov
Instead of only parsing device tree properties let's switch to using generic properties API so that the driver can also work on other platforms. Signed-off-by: Dmitry Torokhov --- drivers/input/touchscreen/edt-ft5x06.c | 26 +++--- 1 file changed, 15 insertions(+), 11 deletio

[PATCH 1/6] Input: edt-ft5x06 - switch to newer gpio framework

2015-09-12 Thread Dmitry Torokhov
From: Franklin S Cooper Jr The current/old gpio framework used doesn't properly listen to ACTIVE_LOW and ACTIVE_HIGH flags. The newer gpio framework takes into account these flags when setting gpio values. Since the values being output were based on voltage and not logic they change to reflect t

Re: [PATCH] Input: elan_i2c - fix X205TA iap version

2015-09-12 Thread Dmitry Torokhov
HI Michele, On Sat, Sep 12, 2015 at 12:24 AM, Michele Curti wrote: > After commit commit 58f1eae48e53 ("Input: elan_i2c - use iap_version to > get firmware information") the touchpad on the Asus X205TA does not > work anymore, iap version is 0, so modify the switch-case index. > > The 0x08 case w

[PATCH] Input: ad714x: Convert to using managed resources

2015-09-12 Thread Vaishali Thakkar
Use managed resource functions devm_request_threaded_irq, devm_inpute_allocate_device and devm_kzalloc to simplify error handling. Also, remove use of input_unregister_device as input_register_device itself handles it and works as resource managed function. To be compatible with the change, variou

[PATCH 0/3] input / dt-bindings: Unify defining of evdev codes

2015-09-12 Thread Hans de Goede
Hi All, Here is a patch-set to unify the defining of evdev codes between uapi/linux/input.h and dt-bindings/input/input.h by using a single shared file, rather then manually keeping things in sync. The third patch is mainly included as an example using some new / extra evcodes this makes availabl

[PATCH 2/3] devicetree: bindings: use input-event-codes.h for evdev codes

2015-09-12 Thread Hans de Goede
Add a symlink to uapi/linux/input-event-codes.h, and include that instead of (re)defining all the evdev type and code values in dt-bindings/input/input.h. This way we do not need to keep all the event codes synced manually. Signed-off-by: Hans de Goede --- include/dt-bindings/input/input-event-c

[PATCH 3/3] ARM: dts: sun4i: inet9f-rev03: Add support for game buttons / joysticks

2015-09-12 Thread Hans de Goede
The inet9f-rev03 tablet has multiple fire-buttons / direction controls, add support for these using the same axis mapping as ps2 compatible game controllers with the same stick / button layout use. Signed-off-by: Hans de Goede --- Changes in v2: -Do not include dt-bindings/input/evdev.h, as the n

[PATCH 1/3] input: Add an input-event-codes header file

2015-09-12 Thread Hans de Goede
Add an input-event-codes header file and move all type and axis defines there. The purpose of this new header file is to have a single canonical source for event-codes which can be used outside of C-code too. One example of such usage is the use of event-codes in devicetree source files. Signed-o

[PATCH v2] devicetree: bindings: Update gpio-keys-polled with support for abs/rel axis

2015-09-12 Thread Hans de Goede
The devicetree binding for gpio-keys-polled already allows specifying what type of events (key / rel / abs) a button generates when pressed. But for rel / abs axis we also need to specify which value this specific gpio represents. One usecase is digital joysticks / direction-pads which are hooked

[PATCH v2 0/1] devicetree: bindings: Update gpio-keys-polled with support

2015-09-12 Thread Hans de Goede
Hi All, Here is v2 of the patch adding support for EV_ABS/EV_REL to the' gpio-keys-polled devicetree bindings. This version addresses Rob's comments. Dmitry, I believe it makes the most sense if you merge this together with the patch actually implementing support for this in the gpio_keys_polled.

[PATCH] Input: elan_i2c - fix X205TA iap version

2015-09-12 Thread Michele Curti
After commit commit 58f1eae48e53 ("Input: elan_i2c - use iap_version to get firmware information") the touchpad on the Asus X205TA does not work anymore, iap version is 0, so modify the switch-case index. The 0x08 case was added for the X205TA in commit 534fcb3bdaab ("Input: elan_i2c - enable ELA