All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christophe TORDEUX <christophe@tordeux.net>
To: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Cc: Henrik Rydberg <rydberg@euromail.se>,
	Tai-hwa Liang <avatar@sentelic.com>,
	Oskari Saarenmaa <os@ohmu.fi>, Paul Fox <pgf@laptop.org>,
	linux-input@vger.kernel.org, linux-kernel@vger.kernel.org,
	torvalds@linux-foundation.org
Subject: Re: [PATCH 01/01] Input multitouch: fix horizontal two-finger-scrolling on Sentelic touchpads
Date: Thu, 20 Dec 2012 00:09:45 +0100	[thread overview]
Message-ID: <20121219230945.GA25106@sherka.no-ip.biz> (raw)
In-Reply-To: <20121212012135.GA9043@sherka.no-ip.biz>

[-- Attachment #1: Type: text/plain, Size: 1685 bytes --]

From: Christophe TORDEUX <christophe@tordeux.net>

Apply the following change to the Sentelic touchpad driver:
report only the position of the first finger as absolute non-MT 
coordinates, instead of reporting both fingers alternatively. Actual MT 
events are unaffected.

Signed-off-by: Christophe TORDEUX <christophe@tordeux.net>
----

This is a much simpler version of my patch. Basically, it makes little 
sense to report both fingers alternatively, as long as it's non-MT 
events. With this approach, storing coordinates of the previously 
reported touch is not necessary. This patch is against kernel version 
3.7. Works with a touchpad version STL3888_C0, very probably works on 
all later version, and very probably does not impact any earlier 
version. This patch has two effects:
1) fix horizontal and improve vertical scrolling, though maybe in a
coincidental way and 2) work towards making the non-MT absolute events
a purely legacy single finger fallback mode, without breaking anything.

diff -uprN -X vanilla/linux-3.7-rc8/Documentation/dontdiff vanilla/linux-3.7/drivers/input/mouse/sentelic.c linux-3.7/drivers/input/mouse/sentelic.c
--- vanilla/linux-3.7/drivers/input/mouse/sentelic.c	2012-12-15 13:51:58.768136524 +0100
+++ linux-3.7/drivers/input/mouse/sentelic.c	2012-12-19 23:26:49.289517251 +0100
@@ -791,7 +791,7 @@ static psmouse_ret_t fsp_process_byte(st
 			fsp_set_slot(dev, 0, fgrs > 0, abs_x, abs_y);
 			fsp_set_slot(dev, 1, false, 0, 0);
 		}
-		if (fgrs > 0) {
+		if (fgrs ==1 || (fgrs == 2 && !(packet[0] & FSP_PB0_MFMC_FGR2))) {
 			input_report_abs(dev, ABS_X, abs_x);
 			input_report_abs(dev, ABS_Y, abs_y);
 		}

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

  parent reply	other threads:[~2012-12-19 23:17 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-12-12  1:21 Christophe TORDEUX
2012-12-12  1:27 ` Christophe TORDEUX
2012-12-19  8:41 ` Henrik Rydberg
2012-12-19 21:42   ` Christophe TORDEUX
2012-12-19 23:09 ` Christophe TORDEUX [this message]
2012-12-20  0:37   ` Dmitry Torokhov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20121219230945.GA25106@sherka.no-ip.biz \
    --to=christophe@tordeux.net \
    --cc=avatar@sentelic.com \
    --cc=dmitry.torokhov@gmail.com \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=os@ohmu.fi \
    --cc=pgf@laptop.org \
    --cc=rydberg@euromail.se \
    --cc=torvalds@linux-foundation.org \
    --subject='Re: [PATCH 01/01] Input multitouch: fix horizontal two-finger-scrolling on Sentelic touchpads' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.