]> Pileus Git - ~andy/linux/blobdiff - drivers/input/mouse/appletouch.c
Merge branch 'perfcounters-core-for-linus' of git://git.kernel.org/pub/scm/linux...
[~andy/linux] / drivers / input / mouse / appletouch.c
index e0140fdc02a57c26a610cd8df76a4ac33b670258..908b5b44052f2e0961fcbde9a98cf19518e978c9 100644 (file)
@@ -361,7 +361,7 @@ static int atp_calculate_abs(int *xy_sensors, int nb_sensors, int fact,
                    (!is_increasing && xy_sensors[i - 1] < xy_sensors[i])) {
                        (*fingers)++;
                        is_increasing = 1;
-               } else if (i > 0 && xy_sensors[i - 1] >= xy_sensors[i]) {
+               } else if (i > 0 && (xy_sensors[i - 1] - xy_sensors[i] > threshold)) {
                        is_increasing = 0;
                }