aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/keyboard/gpio_keys_polled.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2015-03-04gpio: add parameter to allow the use named gpiosOlliver Schinagl1-1/+1
The gpio binding document says that new code should always use named gpios. Patch 40b73183 added support to parse a list of gpios from child nodes, but does not make it possible to use named gpios. This patch adds the con_id property and implements it is done in gpiolib.c, where the old-style of using unnamed gpios still works. Signed-off-by: Olliver Schinagl <oliver@schinagl.nl> Acked-by: Bryan Wu <cooloney@gmail.com> Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Reviewed-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2014-12-14Merge tag 'driver-core-3.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-coreLinus Torvalds1-1/+0
Pull driver core update from Greg KH: "Here's the set of driver core patches for 3.19-rc1. They are dominated by the removal of the .owner field in platform drivers. They touch a lot of files, but they are "simple" changes, just removing a line in a structure. Other than that, a few minor driver core and debugfs changes. There are some ath9k patches coming in through this tree that have been acked by the wireless maintainers as they relied on the debugfs changes. Everything has been in linux-next for a while" * tag 'driver-core-3.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (324 commits) Revert "ath: ath9k: use debugfs_create_devm_seqfile() helper for seq_file entries" fs: debugfs: add forward declaration for struct device type firmware class: Deletion of an unnecessary check before the function call "vunmap" firmware loader: fix hung task warning dump devcoredump: provide a one-way disable function device: Add dev_<level>_once variants ath: ath9k: use debugfs_create_devm_seqfile() helper for seq_file entries ath: use seq_file api for ath9k debugfs files debugfs: add helper function to create device related seq_file drivers/base: cacheinfo: remove noisy error boot message Revert "core: platform: add warning if driver has no owner" drivers: base: support cpu cache information interface to userspace via sysfs drivers: base: add cpu_device_create to support per-cpu devices topology: replace custom attribute macros with standard DEVICE_ATTR* cpumask: factor out show_cpumap into separate helper function driver core: Fix unbalanced device reference in drivers_probe driver core: fix race with userland in device_add() sysfs/kernfs: make read requests on pre-alloc files use the buffer. sysfs/kernfs: allow attributes to request write buffer be pre-allocated. fs: sysfs: return EGBIG on write if offset is larger than file size ...
2014-11-04input: gpio_keys_polled: Make use of device property APIAaron Lu1-49/+24
Make use of device property API in this driver so that both OF based system and ACPI based system can use this driver. Signed-off-by: Aaron Lu <aaron.lu@intel.com> Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com> Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Acked-by: Grant Likely <grant.likely@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2014-11-04input: gpio_keys_polled: Add support for GPIO descriptorsAaron Lu1-12/+27
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. Signed-off-by: Aaron Lu <aaron.lu@intel.com> Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com> Acked-by: Alexandre Courbot <acourbot@nvidia.com> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Acked-by: Grant Likely <grant.likely@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2014-10-20input: keyboard: drop owner assignment from platform_driversWolfram Sang1-1/+0
A platform_driver does not need to set an owner, it will be populated by the driver core. Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
2014-05-14Input: gpio_keys_polled - convert to devm-* APIAlexander Shiyan1-77/+21
Replace existing resource handling in the driver with managed device resources, this ensures more consistent error values and simplifies error handling paths: kzalloc -> devm_kzalloc gpio_request_one -> devm_gpio_request_one input_allocate_polled_device -> devm_input_allocate_polled_device Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2014-05-14Input: gpio_keys_polled - make of_device_id array constJingoo Han1-1/+1
Make of_device_id array const, because all OF functions handle it as const. Signed-off-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2014-01-06Input: delete non-required instances of include <linux/init.h>Paul Gortmaker1-1/+0
None of these files are actually using any __init type directives and hence don't need to include <linux/init.h>. Most are just a left over from __devinit and __cpuinit removal, or simply due to code getting copied from one driver to the next. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2013-10-06Input: gpio_keys_polled - include linux/of.h headerSachin Kamat1-0/+1
'of_match_ptr' is defined in linux/of.h. Include it explicitly. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2013-05-08Input: gpio_keys_polled - remove redundant platform_set_drvdata()Sachin Kamat1-2/+0
Commit 0998d06310 (device-core: Ensure drvdata = NULL when no driver is bound) removes the need to set driver data field to NULL. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2012-12-24Input: gpio_keys_polled - defer probing if GPIO probing is deferredGabor Juhos1-1/+12
If GPIO probing is deferred, the driver tries to claim an invalid GPIO line which leads to an error message like this: gpio-keys-polled buttons.2: unable to claim gpio 4294966779, err=-22 gpio-keys-polled: probe of buttons.2 failed with error -22 We should make sure that error code returned by of_get_gpio_flags (including -EPROBE_DEFER) is propagated up the stack. Cc: stable@vger.kernel.org Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2012-12-03Input: gpio_keys_polled - switch to using gpio_request_one()Dmitry Torokhov1-10/+2
This saves us a few lines of code. Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2012-11-29Input: gpio-keys-polled - honor 'autorepeat' setting in platform dataAlexander Shiyan1-1/+4
Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2012-11-24Input: remove use of __devexitBill Pemberton1-1/+1
CONFIG_HOTPLUG is going away as an option so __devexit is no longer needed. Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2012-11-24Input: remove use of __devinitBill Pemberton1-3/+2
CONFIG_HOTPLUG is going away as an option so __devinit is no longer needed. Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Javier Martinez Canillas <javier@dowhile0.org> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2012-11-24Input: remove use of __devexit_pBill Pemberton1-1/+1
CONFIG_HOTPLUG is going away as an option so __devexit_p is no longer needed. Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Acked-by: Russell King <rmk+kernel@arm.linux.org.uk> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2012-09-12Input: gpio_keys_polled - fix dt pdata->nbuttonsAlexandre Pereira da Silva1-0/+1
pdata->nbuttons should be updated by the dt code. Signed-off-by: Alexandre Pereira da Silva <aletes.xgr@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2012-08-21Input: gpio_keys_polled - convert to dtAlexandre Pereira da Silva1-5/+127
Signed-off-by: Alexandre Pereira da Silva <aletes.xgr@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2012-08-21Input: gpio-keys-polled - constify pointers to platform dataDmitry Torokhov1-7/+7
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2011-11-30Input: keyboard - use macro module_platform_driver()JJ Ding1-13/+1
Commit 940ab88962bc1aff3273a8356d64577a6e386736 introduced a new macro to save some platform_driver boilerplate code. Use it. Signed-off-by: JJ Ding <dgdunix@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-12-06Input: add input driver for polled GPIO buttonsGabor Juhos1-0/+261
The existing gpio-keys driver can be usable only for GPIO lines with interrupt support. Several devices have buttons connected to a GPIO line which is not capable to generate interrupts. This patch adds a new input driver using the generic GPIO layer and the input-polldev to support such buttons. [Ben Gardiner <bengardiner@nanometrics.ca: fold code to use more of the original gpio_keys infrastructure; cleanups and other improvements.] Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: Ben Gardiner <bengardiner@nanometrics.ca> Tested-by: Ben Gardiner <bengardiner@nanometrics.ca> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>