From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757128AbbE2U3y (ORCPT ); Fri, 29 May 2015 16:29:54 -0400 Received: from atrey.karlin.mff.cuni.cz ([195.113.26.193]:55925 "EHLO atrey.karlin.mff.cuni.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756594AbbE2U3m (ORCPT ); Fri, 29 May 2015 16:29:42 -0400 Date: Fri, 29 May 2015 22:29:39 +0200 From: Pavel Machek To: Maxime Ripard Cc: Sebastian Reichel , kernel list , dmitry.torokhov@gmail.com, Pali =?iso-8859-1?Q?Roh=E1r?= , Ivaylo Dimitrov Subject: Re: 4.1 touchscreen regression on n900 -- pinpointed [was Re: linux-n900 v4.1-rc4] Message-ID: <20150529202939.GA22083@amd> References: <201505241444.41039@pali> <20150527132545.GA23434@amd> <20150527133311.GJ30798@pali> <20150527143722.GA28108@amd> <20150527145837.GA13223@earth> <20150529190816.GA20232@amd> <20150529192505.GA28987@amd> <20150529195740.GA17267@lukather> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20150529195740.GA17267@lukather> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri 2015-05-29 21:57:40, Maxime Ripard wrote: > On Fri, May 29, 2015 at 09:25:05PM +0200, Pavel Machek wrote: > > On Fri 2015-05-29 21:08:16, Pavel Machek wrote: > > > Hi! > > > > > > > mh I remember having problems with tsc2005 before. It helped to > > > > reset the controller (should actually happen automatically when it > > > > hangs, but I'm not sure, that it actually works). > > > > > > Ok, I did some more testing, and found out rather bogus values in > > > evtest: > > > > > > Input device name: "TSC2005 touchscreen" > > > Supported events: > > > Event type 0 (EV_SYN) > > > Event type 1 (EV_KEY) > > > Event code 330 (BTN_TOUCH) > > > Event type 3 (EV_ABS) > > > Event code 0 (ABS_X) > > > Value 2514 > > > Min 0 > > > Max 0 > > > Fuzz 4 > > > > > > Which made me go through the git logs, and these patches looked > > > suspicious. After a revert... yes, touchscreen works as well as it > > > worked before. > > > > > > 0a363a380954e10fece7cd9931b66056eeb07d56 > > > 3eea8b5d68c801fec788b411582b803463834752 > > > > > > (It is impossible to revert just 3eea..) > > > > Hmm, I see: > > > > touchscreen-max-x = <4096>; > > touchscreen-max-y = <4096>; > > ...that's n900 dts.. this should be size-x/size-y... so we have a bug > > in dts. > > > > But the 3eea8b5d68c801fec788b411582b803463834752 is buggy, it should > > not overwrite ->maximum for axis it has no devicetree data for. > > What do you mean? touchscreen-max-* _is_ device tree data for an axis. > > > Maybe replacing > > > > + if (maximum || fuzz) > > > > in 3eea to (maximum && fuzz)... would help, but it is late in the > > cycle now, so I'd suggest just reverting 3eea8b. > > No, both maximum and fuzz are optional. You can perfectly have one > without another. Yes, and after your "cleanup", you overwrite maximum with zero with fuzz is specified. ->maximum contained 4096 before, your code sees that it is not specified in the device tree, and you go ahead and replace ->maximum with 0, anyway. Pavel -- (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html