Commit Graph

17 Commits (48b954881f8483740f61c8054f906e4575fab6fd)

Author SHA1 Message Date
Felix Fietkau 85b845cbbc gpio-button-hotplug: remove #ifdef CONFIG_HOTPLUG, it is gone in newer kernels (fixes #16413)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@40838 3c298f89-4303-0410-b956-a3cf2f4a3e73
2014-05-23 22:13:10 +00:00
Hauke Mehrtens 656ddaba7b gpio-button-hotplug: fix (and extend) package description
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>


git-svn-id: svn://svn.openwrt.org/openwrt/trunk@40765 3c298f89-4303-0410-b956-a3cf2f4a3e73
2014-05-14 10:22:48 +00:00
Florian Fainelli 16b5c69b85 gpio-button-hotplug: don't build for 3.3 kernels
3.3 kernels do not have the required changes which would make
gpio-button-hotplug work, disallow building on those kernels for now.

Signed-off-by: Florian Fainelli <florian@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@39903 3c298f89-4303-0410-b956-a3cf2f4a3e73
2014-03-12 22:09:11 +00:00
Hauke Mehrtens 21bb75a937 gpio-button-hotplug: add wwan button
The wimax key will be used as a generic wwan key starting with Linux 
3.13. The brcm47xx target uses this key for the 3g buttons. Also remove 
the ifdef around KEY_WPS_BUTTON, this is in the kernel for a long time 
now. 

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>


git-svn-id: svn://svn.openwrt.org/openwrt/trunk@39290 3c298f89-4303-0410-b956-a3cf2f4a3e73
2014-01-14 23:11:10 +00:00
Jonas Gorski 000da82903 gpio-button-hotplug: fix crash on remove
Don't call gpio_keys_remove recursively. Setting the platform
data to NULL triggered an oops on the second iteration, so there was
no infinate loop.

Signed-off-by: Jonas Gorski <jogo@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@39124 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-12-17 19:05:03 +00:00
John Crispin b8eefa3213 gpio-button-hotplug: add irq mode to driver
Signed-off-by: John Crispin <blogic@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@39021 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-12-09 17:29:39 +00:00
John Crispin 0cfaf503c3 gpio-button-hotplug: add support for sliding switches
Signed-off-by: John Crispin <blogic@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38725 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-11-11 12:19:06 +00:00
John Crispin d5aa1055f5 gpio-button-hotplug: add support for power buttons
Signed-off-by: John Crispin <blogic@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38557 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-10-28 13:45:57 +00:00
Felix Fietkau 1ddc303962 gpio-button-hotplug: debounce the initial button state, the first reads at boot time might be wrong
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37702 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-08-05 10:32:13 +00:00
Felix Fietkau 2c425944b0 gpio-button-hotplug: cleanup, fix compiler warning
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37665 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-08-03 11:56:27 +00:00
Felix Fietkau 6d9f7bbe10 gpio-button-hotplug: fix active_low handling, possibly broken in r37643
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37664 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-08-03 11:49:50 +00:00
John Crispin 168e2d1ef0 gpio-button-hotplug: use gpio_button_get_value() to initialize last_state.
TL-WR720N-v3 has a slider switch composed of 2 GPIO buttons which can be
used to swtich between 3 positions.  At leat 1 button is in pressed state
in any of those positions.  Initialize 'last_state' as 0 (released) will
cause the device to automatically enter failsafe mode on every bootup.

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37643 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-08-01 14:31:28 +00:00
John Crispin 3616f78676 gpio-button-hotplug: use gpio_button_get_value() to fetch state.
Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37642 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-08-01 14:31:24 +00:00
John Crispin e2b775ac87 gpio-button-hotplug: add inline function gpio_button_get_value().
Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37641 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-08-01 14:31:20 +00:00
Luka Perkov 1e25a08d13 gpio-button-hotplug: add support for EV_SW
Signed-off-by: Luka Perkov <luka@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37130 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-07-02 10:45:31 +00:00
Felix Fietkau ca73ec3ee3 gpio-button-hotplug: improve gpio button debouncing, verify state changes over multiple polls. fixes spurious failsafe triggers (#13784)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37090 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-06-29 19:01:49 +00:00
John Crispin f1b4824c86 packages: clean up the package folder
Signed-off-by: John Crispin <blogic@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37007 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-06-21 16:54:37 +00:00