There is nothing that disallows gpio-keys to share it's IRQ line
w/ other drivers. Make it use IRQF_SHARED in request_irq().
An example of other driver with which I'd like to share IRQ line
for GPIO buttons is ledtrig-gpio.
Signed-off-by: Dmitry Eremin-Solenikov <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
OQO 01+ multimedia keys produce 6x on press, e0 6x upon release.
As a result, Linux thinks that another key has been pressed (or is
repeating), when it is actually a release of the same key. Mangle the
release scancode when running on OQO so that driver recognizes it as
such.
Since the device does not have external PS/2 ports mangling is safe
since there is no chance that an external keyboard is connected.
Signed-off-by: Jamie Lentin <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Some machines share same key list for volume up/down release key quirks,
use only one key list.
Signed-off-by: Herton Ronaldo Krzesinski <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
We need to postpone restoring LED state and typematic settings until
keyboard is finished reconnecting upon resume. Normally driver core
and PM infrastructure takes care of proper ordering and dependencies,
but or case actual reconnect is done asynchronously from kseriod.
So while driver core thinks that keyboard was resumed and it is time
to let input core run it's resume handlers in reality keyboard is not
ready yet. The solution is to keep rescheduling work that adjusts LED
and rate settings until keyboard is fully enabled.
Reported-by: Carlos R. Mafra <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Fix breakage caused by commit 9605fb48e1
While the input core indeed takes care of restoring led state and
typematic settings upon resume the driver still need to initialize
them properly when registering a new device
Reported-and-tested-by: Marin Mitov <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
After m68k's task_thread_info() doesn't refer to current,
it's possible to remove sched.h from interrupt.h and not break m68k!
Many thanks to Heiko Carstens for allowing this.
Signed-off-by: Alexey Dobriyan <[email protected]>
This version only supports individual cells (no slide support yet).
The code has been tested on proprietary development ARM board, but
should work fine on other machines.
Signed-off-by: Raphael Derosso Pereira <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
The Maxim MAX7359 is a I2C interfaced key switch controller which
provides microprocessors with management of up to 64 key switches.
This patch adds support for the MAX7359 key switch controller.
Signed-off-by: Kim Kyuwon <[email protected]>
Reviewed-by: Trilok Soni <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
* git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6: (262 commits)
sh: mach-ecovec24: Add user debug switch support
sh: Kill off unused se_skipped in alignment trap notification code.
sh: Wire up HAVE_SYSCALL_TRACEPOINTS.
video: sh_mobile_lcdcfb: use both register sets for display panning
video: sh_mobile_lcdcfb: implement display panning
sh: Fix up sh7705 flush_dcache_page() build.
sh: kfr2r09: document the PLL/FLL <-> RF relationship.
sh: mach-ecovec24: need asm/clock.h.
sh: mach-ecovec24: deassert usb irq on boot.
sh: Add KEYSC support for EcoVec24
sh: add kycr2_delay for sh_keysc
sh: cpufreq: Include CPU id in info messages.
sh: multi-evt support for SH-X3 proto CPU.
sh: clkfwk: remove bogus set_bus_parent() from SH7709.
sh: Fix the indication point of the liquid crystal of AP-325RXA(AP3300)
sh: Add EcoVec24 romImage defconfig
sh: USB disable process is needed if romImage boot for EcoVec24
sh: EcoVec24: add HIZA setting for LED
sh: EcoVec24: write MAC address in boot
sh: Add romImage support for EcoVec24
...
Now that input core takes care of restoring state of input devices
upon resume we don't need to do anything special here.
Signed-off-by: Dmitry Torokhov <[email protected]>
After KYCR2 is set, udelay might become necessary if there are only a
small number of keys attached. This patch introduces an optional delay
through the platform data to address this problem.
Signed-off-by: Kuninori Morimoto <[email protected]>
Signed-off-by: Paul Mundt <[email protected]>
There are more and more laptop requiring use of force_release quirk
for their multimedia and other specialized keys. Adding their DMI data
to the kernel is not sustainable; instead we will rely on help from
userspace (HAL) to do that for us.
This patch creates a new 'force_release' sysfs attribute (that belongs
to serio device to which keyboard is attached) which can be used to set
up force_release keymap. For example, Dell laptop owners might do:
echo 133-139,143,147 > /sys/devices/platform/i8042/serio0/force_release
Signed-off-by: Dmitry Torokhov <[email protected]>
We should first check whether platform data is NULL or not, before
dereferencing it to get the keymap.
Signed-off-by: Julia Lawall <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Add a driver for the keypad controller on TWL4030 family chips.
These support up to an 8x8 key matrix. The TWL4030 multifunction
chips are mostly used on OMAP3 (or OMAP 2430) based boards.
[[email protected]: switch to matrix-keypad framework, fix changing
keymap from userspace]
Reviewed-by: Trilok Soni <[email protected]>
Signed-off-by: David Brownell <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Direct to fail2 to gpio_free() the KEY_STROBEs as well as the KEY_SENSEs.
[[email protected]: change keymap from unsigned int to unsigned short]
Signed-off-by: Roel Kluin <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Also have the driver send MSC_SCAN events as most keyboards do to aid
in updating keymap from userspace.
Tested-by: Wan ZongShun <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Add keypad driver for the 4x4 keypad on an evaluation board based
on w90p910.
Signed-off-by: Wan ZongShun <[email protected]>
Reviewed-by: Trilok Soni <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
hil_kbd and hil_ptr look like twins so it makes sense to combine them
into a single driver.
[[email protected]: add MODULE_ALIAS() entry for mouse]
Tested-by: Helge Deller <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Rename functions and variables from [hil_]kbd to [hil_]dev in
preparation of merging hil_kbd and hil_ptr.
Tested-by: Helge Deller <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Remove assumption on the shift and size of rows/columns form
matrix_keypad driver.
Signed-off-by: Eric Miao <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
clk_disable() in remove method is not needed since we already
have clk_disable in pxa27x_keypad_close().
Also make sure the driver uses resource_size() and helpers from
include/input/matrix_keypad.h
Tested-by: Mike Rapoport <[email protected]>
Acked-by: Eric Miao <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Netbooks based on the Soltech TA12 do not send a key release
for volume keys causing Linux to think the key is constantly
being pressed forever.
Added quirk data for forced release keys.
BugLink: https://bugs.launchpad.net//bugs/397499
Signed-off-by: Jerone Young <[email protected]>
Signed-off-by: Tim Gardner <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
This patch enables forced releasing of the Fn+Volume hotkeys
on the Fujitsu Siemens Amilo Pi 3525 notebook.
Signed-off-by: Simon Davie <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Original patch by Marek Vasut, modified by Eric in:
1. use delayed work to simplify the debouncing
2. combine col_polarity/row_polarity into a single active_low field
3. use a generic bit array based XOR algorithm to detect key
press/release, which should make the column assertion time
shorter and code a bit cleaner
4. remove the ALT_FN handling, which is no way generic, the ALT_FN
key should be treated as no different from other keys, and
translation will be done by user space by commands like 'loadkeys'.
5. explicitly disable row IRQs and flush potential pending work,
and schedule an immediate scan after resuming as suggested
by Uli Luckas
6. incorporate review comments from many others
Patch tested on Littleton/PXA310 (though PXA310 has a dedicate keypad
controller, I have to configure those pins as generic GPIO to use this
driver, works quite well, though), and Sharp Zaurus model SL-C7x0
and SL-C1000.
[[email protected]: fix error unwinding path, support changing keymap
from userspace]
Signed-off-by: Marek Vasut <[email protected]>
Reviewed-by: Trilok Soni <[email protected]>
Reviewed-by: Uli Luckas <[email protected]>
Reviewed-by: Russell King <[email protected]>
Reviewed-by: Robert Jarzmik <[email protected]>
Signed-off-by: Eric Miao <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
The gpio_get_value function may sleep, so it should not be called in a
timer function. Move gpio_get_value calls to workqueue.
Signed-off-by: Jani Nikula <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>