summaryrefslogtreecommitdiffstats
path: root/drivers/input
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@woody.linux-foundation.org>2007-09-25 11:18:10 -0700
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-09-25 11:18:10 -0700
commit973ed7c49a5c2271a10ce54ac06bba5617fca3a8 (patch)
tree6b5956a0341978768b534539b7e5dc01eb43419d /drivers/input
parenta7f3941a2cecf044f3c2975aee9c2bd423018463 (diff)
parentcb560737676260ac15b68d426305ad5e755417ea (diff)
downloadop-kernel-dev-973ed7c49a5c2271a10ce54ac06bba5617fca3a8.zip
op-kernel-dev-973ed7c49a5c2271a10ce54ac06bba5617fca3a8.tar.gz
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: Input: appletouch - fix idle reset logic
Diffstat (limited to 'drivers/input')
-rw-r--r--drivers/input/mouse/appletouch.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/input/mouse/appletouch.c b/drivers/input/mouse/appletouch.c
index 2bea1b2..a1804bf 100644
--- a/drivers/input/mouse/appletouch.c
+++ b/drivers/input/mouse/appletouch.c
@@ -328,6 +328,7 @@ static void atp_complete(struct urb* urb)
{
int x, y, x_z, y_z, x_f, y_f;
int retval, i, j;
+ int key;
struct atp *dev = urb->context;
switch (urb->status) {
@@ -468,6 +469,7 @@ static void atp_complete(struct urb* urb)
ATP_XFACT, &x_z, &x_f);
y = atp_calculate_abs(dev->xy_acc + ATP_XSENSORS, ATP_YSENSORS,
ATP_YFACT, &y_z, &y_f);
+ key = dev->data[dev->datalen - 1] & 1;
if (x && y) {
if (dev->x_old != -1) {
@@ -505,7 +507,7 @@ static void atp_complete(struct urb* urb)
the first touch unless reinitialised. Do so if it's been
idle for a while in order to avoid waking the kernel up
several hundred times a second */
- if (atp_is_geyser_3(dev)) {
+ if (!key && atp_is_geyser_3(dev)) {
dev->idlecount++;
if (dev->idlecount == 10) {
dev->valid = 0;
@@ -514,7 +516,7 @@ static void atp_complete(struct urb* urb)
}
}
- input_report_key(dev->input, BTN_LEFT, dev->data[dev->datalen - 1] & 1);
+ input_report_key(dev->input, BTN_LEFT, key);
input_sync(dev->input);
exit:
OpenPOWER on IntegriCloud