Add support for the keypad controller in the Scroll Key Encoder (SKE)
module on the Nomadik family and the DB8500 SoC.
Acked-by: Linus Walleij <[email protected]>
Signed-off-by: Sundar Iyer <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
We should not try to call free_irq() when request_irq() failed.
Reported-by: G, Manjunath Kondaiah <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Currently the pressure range in Cintiq 21UX2 is limited to half of the
supported. This patch fixes the problem.
Signed-off-by: Aristeu Rozanski <[email protected]>
Acked-by: Ping Cheng <[email protected]>
CC: [email protected]
Signed-off-by: Dmitry Torokhov <[email protected]>
mach-mmp needs to clear wake event in order to clear the keypad interrupt
Signed-off-by: Mark F. Brown <[email protected]>
Signed-off-by: Eric Miao <[email protected]>
mach-mmp utilizes pxa27x_keypad code so we need to move header to
platform pxa directory.
Signed-off-by: Mark F. Brown <[email protected]>
Signed-off-by: Eric Miao <[email protected]>
All these files use the big kernel lock in a trivial
way to serialize their private file operations,
typically resulting from an earlier semi-automatic
pushdown from VFS.
None of these drivers appears to want to lock against
other code, and they all use the BKL as the top-level
lock in their file operations, meaning that there
is no lock-order inversion problem.
Consequently, we can remove the BKL completely,
replacing it with a per-file mutex in every case.
Using a scripted approach means we can avoid
typos.
These drivers do not seem to be under active
maintainance from my brief investigation. Apologies
to those maintainers that I have missed.
file=$1
name=$2
if grep -q lock_kernel ${file} ; then
if grep -q 'include.*linux.mutex.h' ${file} ; then
sed -i '/include.*<linux\/smp_lock.h>/d' ${file}
else
sed -i 's/include.*<linux\/smp_lock.h>.*$/include <linux\/mutex.h>/g' ${file}
fi
sed -i ${file} \
-e "/^#include.*linux.mutex.h/,$ {
1,/^\(static\|int\|long\)/ {
/^\(static\|int\|long\)/istatic DEFINE_MUTEX(${name}_mutex);
} }" \
-e "s/\(un\)*lock_kernel\>[ ]*()/mutex_\1lock(\&${name}_mutex)/g" \
-e '/[ ]*cycle_kernel_lock();/d'
else
sed -i -e '/include.*\<smp_lock.h\>/d' ${file} \
-e '/cycle_kernel_lock()/d'
fi
Signed-off-by: Arnd Bergmann <[email protected]>
When runtime PM is enabled by default for input devices, X hangs in
wacom open:
[<ffffffff814a00ea>] mutex_lock+0x1a/0x40
[<ffffffffa02bc94b>] wacom_resume+0x3b/0x90 [wacom]
[<ffffffff81327a32>] usb_resume_interface+0xd2/0x190
[<ffffffff81327b5d>] usb_resume_both+0x6d/0x110
[<ffffffff81327c24>] usb_runtime_resume+0x24/0x40
[<ffffffff8130a2cf>] __pm_runtime_resume+0x26f/0x450
[<ffffffff8130a23a>] __pm_runtime_resume+0x1da/0x450
[<ffffffff8130a53a>] pm_runtime_resume+0x2a/0x50
[<ffffffff81328176>] usb_autopm_get_interface+0x26/0x60
[<ffffffffa02bc626>] wacom_open+0x36/0x90 [wacom]
wacom_open() takes wacom->lock and calls usb_autopm_get_interface(),
which in turn calls wacom_resume() which tries to acquire the lock
again.
The fix is to call usb_autopm_get_interface() first, before we take
the lock.
Since we do not do usb_autopm_put_interface() until wacom_close()
is called runtime PM is effectively disabled for the driver, however
changing it now would risk regressions so the complete fix will
have to wait till the next merge window.
Reported-by: Jiri Slaby <[email protected]>
Acked-by: Oliver Neukum <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Keep the file consistent and make clear that we mean 144 instead of -112.
Signed-off-by: Christoph Fritz <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
pci_disable_device() is called for following 2 cases
- error path in emu_probe()
- in emu_remove()
Signed-off-by: Rahul Ruikar <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
This adds support for hanwang Art Master HD 5012 electromagnetic tablet.
Signed-off-by: Xing Wei <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Fixed JSIOCSAXMAP ioctl to update absmap, the map from hardware axis to
event axis in addition to abspam. This fixes a regression introduced
by 999b874f.
Signed-off-by: Kenneth Waters <[email protected]>
Cc: [email protected]
Signed-off-by: Dmitry Torokhov <[email protected]>
The input devices created by uinput do not currently handle multitouch
properly. All events will appear as if they came from slot zero, and
the input event buffers are not adjusted. This patch creates the MT
slots during setup, and sets the number of events per packet based
on the MT usage.
Signed-off-by: Henrik Rydberg <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Switch the code to use new style of getkeycode and setkeycode
methods to allow retrieving and setting keycodes not only by
their scancodes but also by index.
Acked-by: Ville Syrjälä <[email protected]>
Tested-by: Jarod Wilson <[email protected]>
Tested-by: Ville Syrjälä <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Commit ea486e6811 changed kseriod thread
to become not freezable so we do not need this include anymore.
Signed-off-by: Dmitry Torokhov <[email protected]>
Add necessary events so that Hanwang Art Master III tablet can be handled
by the stock xf86-input-wacom driver.
Signed-off-by: Xing Wei <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
This adds support for Pen on Bamboo Pen and Bamboo Pen&Touch devices.
Touchpad is handled by previous Bamboo Touch logic.
Signed-off-by: Chris Bagwell <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Bamboo P&T need to use second form of usb_set_report() to
ask to report tablet data.
With previous addition of Bamboo Touch, BTN_TOOL_TRIPLETAP is now used
for both TABLETPC2FG and BAMBOO_PT types. So reduced check to
match type=TABLETPC2FG.
This change shows redundant check for !TABLETPC2FG in else statement.
Signed-off-by: Chris Bagwell <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Switch sparse keymap library to use new style of getkeycode and
setkeycode methods to allow retrieving and setting keycodes not
only by their scancodes but also by index.
Acked-by: Mauro Carvalho Chehab <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Several devices use a high number of bits for scancodes. One important
group is the Remote Controllers. Some new protocols like RC-6 define a
scancode space of 64 bits.
The current EVIO[CS]GKEYCODE ioctls allow replace the scancode/keycode
translation tables, but it is limited to up to 32 bits for scancode.
Also, if userspace wants to clean the existing table, replacing it by
a new one, it needs to run a loop calling the ioctls over the entire
sparse scancode space.
To solve those problems, this patch extends the ioctls to allow drivers
handle scancodes up to 32 bytes long (the length could be extended in
the future should such need arise) and allow userspace to query and set
scancode to keycode mappings not only by scancode but also by index.
Compatibility code were also added to handle the old format of
EVIO[CS]GKEYCODE ioctls.
Folded fixes by:
- Dan Carpenter: locking fixes for the original implementation
- Jarod Wilson: fix crash when setting keycode and wiring up get/set
handlers in original implementation.
- Dmitry Torokhov: rework to consolidate old and new scancode handling,
provide options to act either by index or scancode.
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
Signed-off-by: Dan Carpenter <[email protected]>
Signed-off-by: Jarod Wilson <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Without this the jitter on the touchscreen makes it hard to use for
most GUI toolkits.
Signed-off-by: James Ketrenos<[email protected]>
Signed-off-by: Alan Cox <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
The Bamboo Touch reports a sub-screen resolution of 480x320. The
signal-to-noise ratio is only about 100, so filtering is needed in
order to reduce the jitter to a usable level. However, the low
resolution leads to round-off errors in the EWMA filter, resulting in
extremely jerky pointer motion. This patch explicitly sets a higher
resolution for those devices, and tells this to the completion handler
via a low-resolution quirk.
Signed-off-by: Henrik Rydberg <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Add support for the Bamboo Touch trackpad, and make it work with
both the Synaptics X Driver and the Multitouch X Driver. The device
uses MT slots internally, so the choice of protocol is a given.
Signed-off-by: Henrik Rydberg <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Collect device-specific code into a single function, and use quirks to
flag specific behavior instead.
Signed-off-by: Henrik Rydberg <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
The Bamboo devices have multiple interfaces which need to be setup
separately. Use the HID parsing mechanism to achieve that.
Signed-off-by: Ping Cheng <[email protected]>
Signed-off-by: Henrik Rydberg <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
The signal-to-noise ratio varies between devices, but currently all
devices are treated the same way. Add fuzz parameters to the feature
struct, allowing for tailored treatment of devices.
Signed-off-by: Henrik Rydberg <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Add logic to wm97xx_read_aux_adc() to retry reading the adc if the
sample failed. This could occur if the previous sample was still in
the return register or the sample timed-out. Also avoid a pathologic
failure mode by disabling the digitizer and returning -EBUSY after 5
retries.
Signed-off-by: Eric Millbrandt <[email protected]>
Acked-by: Mark Brown <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
It is forbidden to call input_free_device() after input_unregister_device().
Signed-off-by: Axel Lin <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Once device is registered we should call input_unregister_device()
instead of input_free_device().
Signed-off-by: Axel Lin <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
We call platform_get_drvdata() in tps6507x_ts_remove(),
thus we should call platform_set_drvdata() in tps6507x_ts_probe().
Signed-off-by: Axel Lin <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Use input_free_device() to free devices that have not been registered.
Signed-off-by: Axel Lin <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>