lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <alpine.LNX.2.00.1103241244500.19969@pobox.suse.cz>
Date:	Thu, 24 Mar 2011 12:46:14 +0100 (CET)
From:	Jiri Kosina <jkosina@...e.cz>
To:	Henrik Rydberg <rydberg@...omail.se>
Cc:	Benjamin Tissoires <benjamin.tissoires@...c.fr>,
	Dmitry Torokhov <dmitry.torokhov@...il.com>,
	Stephane Chatty <chatty@...-enac.fr>,
	linux-input@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v4] hid-multitouch: migrate 3M PCT touch screens to
 hid-multitouch

On Tue, 22 Mar 2011, Henrik Rydberg wrote:

> On Tue, Mar 22, 2011 at 05:34:01PM +0100, Benjamin Tissoires wrote:
> > This patch merges the hid-3m-pct driver into hid-multitouch.
> > To keep devices working the same way they used to with hid-3m-pct,
> > we need to add two signal/noise ratios for width and height.
> > We also need to work on width/height to send proper
> > ABS_MT_ORIENTATION flag.
> > 
> > Importing 3M into hid-multitouch also solved the bug in which
> > devices handling width and height in their report descriptors
> > did not show ABS_MT_TOUCH_MAJOR and ABS_MT_TOUCH_MINOR.
> > 
> > Signed-off-by: Benjamin Tissoires <benjamin.tissoires@...c.fr>
> > Reviewed-by: Stéphane Chatty <chatty@...c.fr>
> > ---
> [...]
> > Henrik, do I still have your Reviewed-and-tested-by ?
> 
> Yep, looks good. One more thing, though:
> 
> > @@ -332,11 +351,18 @@ static void mt_emit_event(struct mt_device *td, struct input_dev *input)
> >  		input_mt_report_slot_state(input, MT_TOOL_FINGER,
> >  			s->touch_state);
> >  		if (s->touch_state) {
> > +			/* this finger is on the screen */
> > +			int wide = (s->w > s->h);
> > +			/* divided by two to match visual scale of touch */
> > +			int major = max(s->w, s->h) >> 1;
> > +			int minor = min(s->w, s->h) >> 1;
> 
> This scaling is most likely not correct for all devices. I went
> through a set of devices some time ago, running mtview on all of them,
> visually inspecting the touch size. Some were low by a factor of two,
> some were high by a factor of two. A confirmation that the other
> devices supported by this driver seem right would be good. If not, a
> quirk should probably be added here.

Okay, thanks a lot for the review. This can be handled later during 
-rc phase if needed. So please proceed with confirming with the existing 
devices, and meanwhile I have applied the patch.

> > +
> >  			input_event(input, EV_ABS, ABS_MT_POSITION_X, s->x);
> >  			input_event(input, EV_ABS, ABS_MT_POSITION_Y, s->y);
> > +			input_event(input, EV_ABS, ABS_MT_ORIENTATION, wide);
> >  			input_event(input, EV_ABS, ABS_MT_PRESSURE, s->p);
> > -			input_event(input, EV_ABS, ABS_MT_TOUCH_MAJOR, s->w);
> > -			input_event(input, EV_ABS, ABS_MT_TOUCH_MINOR, s->h);
> > +			input_event(input, EV_ABS, ABS_MT_TOUCH_MAJOR, major);
> > +			input_event(input, EV_ABS, ABS_MT_TOUCH_MINOR, minor);
> >  		}
> >  		s->seen_in_this_frame = false;

Thanks,

-- 
Jiri Kosina
SUSE Labs, Novell Inc.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ