aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)AuthorFilesLines
2016-11-08Input: synaptics-rmi4 - add a couple of debug linesNick Dyer2-0/+4
Signed-off-by: Nick Dyer <nick@shmanahar.org> Tested-by: Chris Healy <cphealy@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-08Input: synaptics-rmi4 - factor out functions from probeNick Dyer1-53/+86
Signed-off-by: Nick Dyer <nick@shmanahar.org> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Tested-by: Chris Healy <cphealy@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <nick@shmanahar.org> [Tested successfully on S7817 and S7300 Synaptics touch controllers] Tested-by: Chris Healy <cphealy@gmail.com> Reviewed-by: Andrew Duggan <aduggan@synaptics.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-07Merge tag 'media/v4.9-3' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media into synaptics-rmi4Dmitry Torokhov851-51601/+44227
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 <geert+renesas@glider.be> Suggested-by: Mika Westerberg <mika.westerberg@linux.intel.com> Tested-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <geert+renesas@glider.be> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Tested-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <mika.westerberg@linux.intel.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <mika.westerberg@linux.intel.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <hdegoede@redhat.com> Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com> Tested-by: Mika Westerberg <mika.westerberg@linux.intel.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <mika.westerberg@linux.intel.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <javier@osg.samsung.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <javier@osg.samsung.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <arnd@arndb.de> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <jeesw@melfas.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <stwiss.opensource@diasemi.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <colin.king@canonical.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <marcos.souza.org@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <jeesw@melfas.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
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 <mchehab@s-opensource.com>
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 <fengguang.wu@intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
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 <mchehab@s-opensource.com>
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 <mchehab@osg.samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
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 <mchehab@osg.samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
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 <mchehab@osg.samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
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 <mchehab@s-opensource.com>
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 <mchehab@s-opensource.com>
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 <mchehab@s-opensource.com>
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 <patrick.boettcher@posteo.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
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 <mchehab@s-opensource.com>
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 <patrick.boettcher@posteo.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
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 <patrick.boettcher@posteo.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
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 <mchehab@s-opensource.com>
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 <mchehab@s-opensource.com>
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 <mchehab@osg.samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
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 <mchehab@s-opensource.com>
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 <patrick.boettcher@posteo.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
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 <mchehab@s-opensource.com>
2016-10-14[media] dtt200u-fe: don't do DMA on stackMauro Carvalho Chehab1-30/+65
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 <mchehab@s-opensource.com>
2016-10-14[media] dtt200u-fe: don't keep waiting for lock at set_frontend()Mauro Carvalho Chehab1-9/+0
It is up to the frontend kthread to wait for lock. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2016-10-14[media] digitv: don't do DMA on stackMauro Carvalho Chehab2-10/+15
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 <patrick.boettcher@posteo.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2016-10-14[media] dibusb: handle error code on RC queryMauro Carvalho Chehab1-2/+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 <mchehab@s-opensource.com>
2016-10-14[media] dibusb: don't do DMA on stackMauro Carvalho Chehab2-25/+85
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 <patrick.boettcher@posteo.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2016-10-14[media] dib0700_core: don't use stack on I2C readsMauro Carvalho Chehab1-1/+26
Be sure that I2C reads won't use stack by passing a pointer to the state buffer, that we know it was allocated via kmalloc, instead of relying on the buffer allocated by an I2C client. Reviewed-by: Patrick Boettcher <patrick.boettcher@posteo.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2016-10-14[media] dib0700: be sure that dib0700_ctrl_rd() users can do DMAMauro Carvalho Chehab2-13/+16
dib0700_ctrl_rd() takes a RX and a TX pointer. Be sure that both will point to a memory allocated via kmalloc(). Reviewed-by: Patrick Boettcher <patrick.boettcher@posteo.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2016-10-14[media] cxusb: don't do DMA on stackMauro Carvalho Chehab2-27/+41
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 <patrick.boettcher@posteo.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2016-10-14[media] cinergyT2-fe: don't do DMA on stackMauro Carvalho Chehab1-23/+33
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 <patrick.boettcher@posteo.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2016-10-14[media] cinergyT2-fe: cache stats at cinergyt2_fe_read_status()Mauro Carvalho Chehab1-41/+7
Instead of sending USB commands for every stats call, collect them once, when status is updated. As the frontend kthread will call it on every few seconds, the stats will still be collected. Besides reducing the amount of USB/I2C transfers, this also warrants that all stats will be collected at the same time, and makes easier to convert it to DVBv5 stats in the future. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2016-10-14[media] cinergyT2-core: handle error code on RC queryMauro Carvalho Chehab1-3/+5
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 <mchehab@s-opensource.com>
2016-10-14[media] cinergyT2-core: don't do DMA on stackMauro Carvalho Chehab1-23/+61
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 <patrick.boettcher@posteo.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>