public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Henrik Rydberg" <rydberg@euromail.se>
To: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Cc: Jiri Kosina <jkosina@suse.cz>,
	Chase Douglas <chase.douglas@canonical.com>,
	Chris Bagwell <chris@cnpbagwell.com>,
	linux-input@vger.kernel.org, linux-kernel@vger.kernel.org,
	Takashi Iwai <tiwai@suse.de>
Subject: Re: [PATCH 1/4] Input: synaptics - add multitouch packet support
Date: Sun, 19 Dec 2010 10:36:07 +0100	[thread overview]
Message-ID: <20101219093607.GA6162@polaris.bitmath.org> (raw)
In-Reply-To: <20101219081648.GC10074@core.coreip.homeip.net>

> > @@ -279,6 +279,24 @@ static void synaptics_set_rate(struct psmouse *psmouse, unsigned int rate)
> >  	synaptics_mode_cmd(psmouse, priv->mode);
> >  }
> >  
> > +static int synaptics_set_multitouch_mode(struct psmouse *psmouse)
> > +{
> > +	static unsigned char param = 0xc8;
> > +	struct synaptics_data *priv = psmouse->private;
> > +
> > +	if (!SYN_CAP_MULTITOUCH(priv->ext_cap_0c))
> > +		return 0;
> > +
> > +	if (psmouse_sliced_command(psmouse, SYN_QUE_MODEL))
> > +		return -1;
> > +	if (ps2_command(&psmouse->ps2dev, &param, PSMOUSE_CMD_SETRATE))
> > +		return -1;
> > +
> > +	priv->multitouch = 1;
> 
> That should be bool/true. Also, do we need to have this variable at all
> since we seem to abort initialization if multitouch mode fails?

The logic of the all-patches-applied version does depend on the
advanced gesture flag, but sure, instead of this variable, one could
set the SYN_CAP_MULTIFINGER bit, and use SYN_CAP_MULTITOUCH explicitly
in remaining places. And, of course, another round of testing.

> 
> > +	printk(KERN_INFO "Synaptics: Multitouch mode enabled\n");
> 
> I'd rather only reported if we failed to activate multitouch mode on
> devices that ought support it.

Ok.

> > @@ -53,6 +53,7 @@
> >  #define SYN_CAP_PRODUCT_ID(ec)		(((ec) & 0xff0000) >> 16)
> >  #define SYN_CAP_CLICKPAD(ex0c)		((ex0c) & 0x100100)
> >  #define SYN_CAP_MAX_DIMENSIONS(ex0c)	((ex0c) & 0x020000)
> > +#define SYN_CAP_MULTITOUCH(ex0c)	((ex0c) & 0x080000)
> 
> Synaptics calls this bit "Advanced Gesture", I think we should do the
> same as they might produce full-MT devices in the future.
> 
> Also, how useful is this patch without the 4th one? Why aren't they
> folded together?

This first patch implements multi-finger support in the same fashion
as older hardware, thus enabling for instance hw-finger scroll in
synaptics.

Thanks,
Henrik

  reply	other threads:[~2010-12-19  9:37 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-18 14:52 [PATCH 0/4] Input: synaptics - add semi-mt support Henrik Rydberg
2010-12-18 14:52 ` [PATCH 1/4] Input: synaptics - add multitouch packet support Henrik Rydberg
2010-12-18 16:55   ` Chris Bagwell
2010-12-18 16:56     ` Chris Bagwell
2010-12-18 17:06       ` Henrik Rydberg
2010-12-18 17:54     ` Henrik Rydberg
2010-12-18 20:44       ` Chris Bagwell
2010-12-21 16:45       ` Chase Douglas
2010-12-19  8:16   ` Dmitry Torokhov
2010-12-19  9:36     ` Henrik Rydberg [this message]
2010-12-18 14:52 ` [PATCH 2/4] Input: synaptics - ignore bogus mt packet Henrik Rydberg
2010-12-18 17:05   ` Chris Bagwell
2010-12-18 14:53 ` [PATCH 3/4] Input: synaptics - report clickpad property Henrik Rydberg
2010-12-18 14:53 ` [PATCH 4/4] Input: synaptics - emit multitouch data Henrik Rydberg
2010-12-18 17:11   ` Chris Bagwell

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=20101219093607.GA6162@polaris.bitmath.org \
    --to=rydberg@euromail.se \
    --cc=chase.douglas@canonical.com \
    --cc=chris@cnpbagwell.com \
    --cc=dmitry.torokhov@gmail.com \
    --cc=jkosina@suse.cz \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tiwai@suse.de \
    /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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox