aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2016-11-16Input: silead - add regulator supportHans de Goede2-0/+31
On some tablets the touchscreen controller is powered by separate regulators, add support for this. Signed-off-by: Hans de Goede <[email protected]> Acked-by: Rob Herring <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-16Input: bma150 - avoid binding to bma180 if IIO bma180 driver presentHans de Goede1-1/+8
commit ef3714fdbc8d ("Input: bma150 - extend chip detection for bma180"), adds bma180 chip-ids to the input bma150 driver, assuming that they are 100% compatible, but the bma180 is not compatible with the bma150 at all, it has 14 bits resolution instead of 10, and it has quite different control registers too. Treating the bma180 as a bma150 wrt its data registers will just result in throwing away the lowest 4 bits, which is not too bad. But the ctrl registers are a different story. Things happen to just work but supporting that certainly does not make treating the bma180 the same as the bma150 right. Since some setups depend on the evdev interface the bma150 driver offers on top of the bma180, we cannot simply remove the bma180 ids. So this commit only removes the bma180 id when the bma180 iio driver, which does treat the bma180 properly, is enabled. Signed-off-by: Hans de Goede <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-08Input: synaptics-rmi4 - add SMBus supportBenjamin Tissoires4-0/+472
Code obtained from https://raw.githubusercontent.com/mightybigcar/synaptics-rmi4/jf/drivers/input/rmi4/rmi_smbus.c and updated to match upstream. And fixed to make it work. Signed-off-by: Benjamin Tissoires <[email protected]> Signed-off-by: Andrew Duggan <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-08Input: synaptics-rmi4 - set the ABS_MT_TOOL_TYPE bit to report tool typeAndrew Duggan1-4/+6
The rmi4 2D sensor functions report the tool type via input_mt_report_slot_state(), but the abs parameter bit has not been set so the tool type is not reported to userspace. This patch set the ABS_MT_TOOL_TYPE bit. Signed-off-by: Andrew Duggan <[email protected]> Signed-off-by: Benjamin Tissoires <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-08Input: synaptics-rmi4 - add support for controlling dribble packets in F12Andrew Duggan1-1/+69
Implements reading and setting the dribble bit in F12's control registers. Signed-off-by: Andrew Duggan <[email protected]> Acked-by: Benjamin Tissoires <[email protected]> Signed-off-by: Benjamin Tissoires <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-08Input: synaptics-rmi4 - add parameters for dribble packets and palm detect ↵Andrew Duggan4-15/+46
gesture The rmi_f11 driver currently disables dribble packets and the palm detect gesture for all devices. This patch creates a parameter in the 2d sensor platform data for controlling this functionality on a per device basis. For more information on dribble packets: Commit 05ba999fcabb ("HID: rmi: disable dribble packets on Synaptics touchpads") For more information on the palm detect gesture: Commit f097deef59a6 ("HID: rmi: disable palm detect gesture when present") Signed-off-by: Andrew Duggan <[email protected]> Reviewed-by: Benjamin Tissoires <[email protected]> Signed-off-by: Benjamin Tissoires <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-08Input: synaptics-rmi4 - handle incomplete input dataAndrew Duggan3-20/+61
Commit 5b65c2a02966 ("HID: rmi: check sanity of the incoming report") added support for handling incomplete HID reports do to the input data being corrupted in transit. This patch reimplements this functionality in the function drivers so they can handle getting less valid data then they expect. Signed-off-by: Andrew Duggan <[email protected]> Signed-off-by: Benjamin Tissoires <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-08Input: synaptics-rmi4 - move IRQ handling to rmi_driverBjorn Andersson4-143/+83
The attn IRQ is related to the chip, rather than the transport, so move all handling of interrupts to the core driver. This also makes sure that there are no races between interrupts and availability of the resources used by the core driver. Signed-off-by: Bjorn Andersson <[email protected]> Signed-off-by: Benjamin Tissoires <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-08Input: da9062 - update bindings docs to account for da9061Steve Twiss1-15/+30
Add binding information for DA9061 onkey. This patch updates the compatible string "dlg,da9061-onkey" to support DA9061, removes the reference to KEY_SLEEP (which the driver no longer supports) and fixes a typo in the example for DA9063. Supporting KEY_SLEEP was not the general convention and the typical solution should have been for KEY_POWER to support both cases of suspend and S/W power off. This change was sent to the DA9063 ONKEY device driver in a separate patch, but the documentation was not updated at that time. - f889bea Report KEY_POWER instead of KEY_SLEEP during power key-press This patch also adds two new examples, one for DA9062 and one for DA9061. The DA9061 examples uses a fall-back compatible string for the DA9062 onkey driver. Signed-off-by: Steve Twiss <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-08Input: melfas_mip4 - add product ID reportingSangwon Jee1-1/+2
Add reporting product ID through input_id. Signed-off-by: Sangwon Jee <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-08Input: synaptics-rmi4 - add a couple of debug linesNick Dyer2-0/+4
Signed-off-by: Nick Dyer <[email protected]> Tested-by: Chris Healy <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-08Input: synaptics-rmi4 - factor out functions from probeNick Dyer1-53/+86
Signed-off-by: Nick Dyer <[email protected]> Signed-off-by: Benjamin Tissoires <[email protected]> Tested-by: Chris Healy <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-08Input: synaptics-rmi4 - stop scanning PDT after two empty pagesNick Dyer1-2/+14
We have encountered some RMI4 firmwares where there are blank pages in between PDT pages which contain functions. This change makes them correctly enumerate all functions on the device. Tested on S7817 (has empty page 2). Signed-off-by: Nick Dyer <[email protected]> [Tested successfully on S7817 and S7300 Synaptics touch controllers] Tested-by: Chris Healy <[email protected]> Reviewed-by: Andrew Duggan <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-07Merge tag 'media/v4.9-3' of ↵Dmitry Torokhov851-51601/+44227
git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media into synaptics-rmi4 Sync up with media tree to bring up latest Synaptics and Atmel changes.
2016-11-07Input: gpio_keys - switch to using generic device propertiesDmitry Torokhov1-72/+69
Make use of the device property API in this driver so that both OF based systems and ACPI based systems can use this driver. Suggested-by: Geert Uytterhoeven <[email protected]> Suggested-by: Mika Westerberg <[email protected]> Tested-by: Mika Westerberg <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-07Input: gpio_keys - add support for GPIO descriptorsGeert Uytterhoeven1-11/+26
GPIO descriptors are the preferred way over legacy GPIO numbers nowadays. Convert the driver to use GPIO descriptors internally but still allow passing legacy GPIO numbers from platform data to support existing platforms. Based on commits 633a21d80b4a2cd6 ("input: gpio_keys_polled: Add support for GPIO descriptors") and 1ae5ddb6f8837558 ("Input: gpio_keys_polled - request GPIO pin as input."). Signed-off-by: Geert Uytterhoeven <[email protected]> Reviewed-by: Linus Walleij <[email protected]> Tested-by: Mika Westerberg <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-07Input: gpio_keys - fix leaking DT node referencesDmitry Torokhov1-0/+3
for_each_available_child_of_node(node, pp) takes reference to 'pp' and drops it when attempting next iteration. However if we exit the loop early we need to drop the reference ourselves. Tested-by: Mika Westerberg <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-07Input: gpio_keys - annotate PM methods as __maybe_unusedDmitry Torokhov1-4/+2
Instead of using #ifdef, let's mark suspend and resume methods as __maybe_unused to provide better compile coverage. Tested-by: Mika Westerberg <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-07Input: gpio_keys_polled - always use gpiod_get_value_cansleepDmitry Torokhov1-11/+10
It does not matter if given GPIO may sleep or not when reading state, polling is always done in a non-atomic context, so we should always be able to simply use gpiod_get_value_cansleep(). Also let's note in the logs when we fail to read gpio state. Reviewed-by: Hans de Goede <[email protected]> Reviewed-by: Mika Westerberg <[email protected]> Tested-by: Mika Westerberg <[email protected]> Acked-by: Linus Walleij <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-11-07Input: gpio_keys_polled - keep button data constantDmitry Torokhov3-56/+64
Commit 633a21d80b4a ("input: gpio_keys_polled: Add support for GPIO descriptors") placed gpio descriptor into gpio_keys_button structure, which is supposed to be part of platform data and not modifiable by the driver. To keep the data constant, let's move the descriptor to gpio_keys_button_data structure instead. Tested-by: Mika Westerberg <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-10-26Input: da9063 - fix module autoload when registered via OFJavier Martinez Canillas1-0/+1
If the driver is built as a module, autoload won't work because the module alias information is not filled. So user-space can't match the registered device with the corresponding module. Export the module alias information using the MODULE_DEVICE_TABLE() macro. Before this patch: $ modinfo drivers/input/misc/da9063_onkey.ko | grep alias alias: platform:da9063-onkey After this patch: $ modinfo drivers/input/misc/da9063_onkey.ko | grep alias alias: platform:da9063-onkey alias: of:N*T*Cdlg,da9062-onkeyC* alias: of:N*T*Cdlg,da9062-onkey alias: of:N*T*Cdlg,da9063-onkeyC* alias: of:N*T*Cdlg,da9063-onkey Signed-off-by: Javier Martinez Canillas <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-10-26Input: fsl-imx25-tcq - fix module autoload when registered via OFJavier Martinez Canillas1-0/+1
If the driver is built as a module, autoload won't work because the module alias information is not filled. So user-space can't match the registered device with the corresponding module. Export the module alias information using the MODULE_DEVICE_TABLE() macro. Before this patch: $ modinfo drivers/input/touchscreen/fsl-imx25-tcq.ko | grep alias After this patch: $ modinfo drivers/input/touchscreen/fsl-imx25-tcq.ko | grep alias alias: of:N*T*Cfsl,imx25-tcqC* alias: of:N*T*Cfsl,imx25-tcq Signed-off-by: Javier Martinez Canillas <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-10-26Input: elan_i2c - always output the device informationBenjamin Tissoires1-9/+8
it's always easier to retrieve these information in bug reports when it is always printed in the dmesg. Signed-off-by: Benjamin Tissoires <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-10-26Input: tca8418_keypad - hide gcc-4.9 -Wmaybe-uninitialized warningArnd Bergmann1-9/+12
Older versions of gcc warn about the tca8418_irq_handler function as they can't keep track of the variable assignment inside of the loop when using the -Wmaybe-unintialized flag: drivers/input/keyboard/tca8418_keypad.c: In function ‘tca8418_irq_handler’: drivers/input/keyboard/tca8418_keypad.c:172:9: error: ‘reg’ may be used uninitialized in this function [-Werror=maybe-uninitialized] drivers/input/keyboard/tca8418_keypad.c:165:5: note: ‘reg’ was declared here This is fixed in gcc-6, but it's possible to rearrange the code in a way that avoids the warning on older compilers as well. Signed-off-by: Arnd Bergmann <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-10-26Input: melfas_mip4 - use product id for firmware nameSangwon Jee1-3/+9
Use product id for firmware name to request compatible firmware. Signed-off-by: Sangwon Jee <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-10-26Input: da9061 - onkey driverSteve Twiss2-7/+8
Copyright header is updated to add DA9061 in its description and the module description macro is extended to include DA9061. Minor change to the code, alters dev_dbg() statements to report a generic "PMIC" instead of DA9063. This device driver is compatible with DA9061, DA9062 and DA9063. Kconfig is updated to reflect support for DA9061/62/63. Signed-off-by: Steve Twiss <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-10-26Input: pxa27x_keypad - fix typo "debpunce" -> "debounce"Colin Ian King1-1/+1
Trivial fix to typo in dev_err message Signed-off-by: Colin Ian King <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-10-24Input: psmouse - cleanup Focaltech codeDmitry Tunin1-3/+3
psmouse->name "Focaltech Touchpad" is an overkill. In xinput it is too long as "FocaltechPS/2 Focaltech Focaltech Touchpad" In focaltech_report_state() pointer to psmouse->dev is already stored as *dev Signed-off-by: Dmitry Tunin <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-10-21Input: i8042 - use chassis info to skip selftest on Asus laptopsMarcos Paulo de Souza1-73/+1
Instead of relying on this model zoo let's skip selftest on all newer Asus laptops (newer as in when they changed "Computer" -> "COMPUTER" in their DMI data). Signed-off-by: Marcos Paulo de Souza <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-10-21Input: melfas_mip4 - add product_id sysfs attributeSangwon Jee1-2/+38
Add product_id sysfs attribute and update protocol version to support it. Signed-off-by: Sangwon Jee <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
2016-10-19Input: i8042 - add XMG C504 to keyboard reset tablePatrick Scheuring1-0/+7
The Schenker XMG C504 is a rebranded Gigabyte P35 v2 laptop. Therefore it also needs a keyboard reset to detect the Elantech touchpad. Otherwise the touchpad appears to be dead. With this patch the touchpad is detected: $ dmesg | grep -E "(i8042|Elantech|elantech)" [ 2.675399] i8042: PNP: PS/2 Controller [PNP0303:PS2K,PNP0f13:PS2M] at 0x60,0x64 irq 1,12 [ 2.680372] i8042: Attempting to reset device connected to KBD port [ 2.789037] serio: i8042 KBD port at 0x60,0x64 irq 1 [ 2.791586] serio: i8042 AUX port at 0x60,0x64 irq 12 [ 2.813840] input: AT Translated Set 2 keyboard as /devices/platform/i8042/serio0/input/input4 [ 3.811431] psmouse serio1: elantech: assuming hardware version 4 (with firmware version 0x361f0e) [ 3.825424] psmouse serio1: elantech: Synaptics capabilities query result 0x00, 0x15, 0x0f. [ 3.839424] psmouse serio1: elantech: Elan sample query result 03, 58, 74 [ 3.911349] input: ETPS/2 Elantech Touchpad as /devices/platform/i8042/serio1/input/input6 Signed-off-by: Patrick Scheuring <[email protected]> Cc: [email protected] Signed-off-by: Dmitry Torokhov <[email protected]>
2016-10-17[media] radio-bcm2048: don't ignore errorsMauro Carvalho Chehab1-0/+2
Remove this warning: drivers/staging/media/bcm2048/radio-bcm2048.c: In function 'bcm2048_set_rds_no_lock': drivers/staging/media/bcm2048/radio-bcm2048.c:467:6: warning: variable 'err' set but not used [-Wunused-but-set-variable] int err; ^~~ By returning the error code. Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] pctv452e: fix semicolon.cocci warningskbuild test robot1-1/+1
drivers/media/usb/dvb-usb/pctv452e.c:115:2-3: Unneeded semicolon Remove unneeded semicolon. Generated by: scripts/coccinelle/misc/semicolon.cocci Signed-off-by: Fengguang Wu <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] flexcop-usb: don't use stack for DMAMauro Carvalho Chehab2-37/+72
The USB control messages require DMA to work. We cannot pass a stack-allocated buffer, as it is not warranted that the stack would be into a DMA enabled area. While here, remove a dead function calling usb_control_msg(). Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] stk-webcam: don't use stack for DMAMauro Carvalho Chehab1-5/+11
The USB control messages require DMA to work. We cannot pass a stack-allocated buffer, as it is not warranted that the stack would be into a DMA enabled area. Signed-off-by: Mauro Carvalho Chehab <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] s2255drv: don't use stack for DMAMauro Carvalho Chehab1-2/+13
The USB control messages require DMA to work. We cannot pass a stack-allocated buffer, as it is not warranted that the stack would be into a DMA enabled area. Signed-off-by: Mauro Carvalho Chehab <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] cpia2_usb: don't use stack for DMAMauro Carvalho Chehab1-4/+30
The USB control messages require DMA to work. We cannot pass a stack-allocated buffer, as it is not warranted that the stack would be into a DMA enabled area. Signed-off-by: Mauro Carvalho Chehab <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] digitv: handle error code on RC queryMauro Carvalho Chehab1-4/+6
There's no sense on decoding and generating a RC key code if there was an error on the URB control message. Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] dw2102: return error if su3000_power_ctrl() failsMauro Carvalho Chehab1-1/+1
Instead of silently ignoring the error, return it. Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] nova-t-usb2: handle error code on RC queryMauro Carvalho Chehab1-3/+6
There's no sense on decoding and generating a RC key code if there was an error on the URB control message. Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] technisat-usb2: use DMA buffers for I2C transfersMauro Carvalho Chehab1-5/+11
The USB control messages require DMA to work. We cannot pass a stack-allocated buffer, as it is not warranted that the stack would be into a DMA enabled area. On this driver, most of the transfers are OK, but the I2C one was using stack. Reviewed-by: Patrick Boettcher <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] pctv452e: don't call BUG_ON() on non-fatal errorMauro Carvalho Chehab1-3/+4
There are some conditions on this driver that are tested with BUG_ON() with are not serious enough to hang a machine. So, just return an error if this happens. Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] pctv452e: don't do DMA on stackMauro Carvalho Chehab1-55/+74
The USB control messages require DMA to work. We cannot pass a stack-allocated buffer, as it is not warranted that the stack would be into a DMA enabled area. Reviewed-by: Patrick Boettcher <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] nova-t-usb2: don't do DMA on stackMauro Carvalho Chehab1-5/+13
The USB control messages require DMA to work. We cannot pass a stack-allocated buffer, as it is not warranted that the stack would be into a DMA enabled area. Reviewed-by: Patrick Boettcher <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] gp8psk: don't go past the buffer sizeMauro Carvalho Chehab1-0/+11
Add checks to avoid going out of the buffer. Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] gp8psk: don't do DMA on stackMauro Carvalho Chehab1-2/+12
The USB control messages require DMA to work. We cannot pass a stack-allocated buffer, as it is not warranted that the stack would be into a DMA enabled area. Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] dtv5100: don't do DMA on stackMauro Carvalho Chehab1-2/+8
The USB control messages require DMA to work. We cannot pass a stack-allocated buffer, as it is not warranted that the stack would be into a DMA enabled area. Signed-off-by: Mauro Carvalho Chehab <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] dtt200u: handle USB control message errorsMauro Carvalho Chehab1-8/+18
If something bad happens while an USB control message is transfered, return an error code. Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] dtt200u: don't do DMA on stackMauro Carvalho Chehab1-29/+75
The USB control messages require DMA to work. We cannot pass a stack-allocated buffer, as it is not warranted that the stack would be into a DMA enabled area. Reviewed-by: Patrick Boettcher <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2016-10-14[media] dtt200u-fe: handle errors on USB control messagesMauro Carvalho Chehab1-9/+31
If something goes wrong, return an error code, instead of assuming that everything went fine. Signed-off-by: Mauro Carvalho Chehab <[email protected]>