From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Fri, 20 Dec 2013 09:52:22 +0500 From: "Zubair Lutfullah :" To: Sebastian Andrzej Siewior Cc: Zubair Lutfullah: zubair.lutfullah@gmail.com, Lee Jones , Samuel Ortiz , Jonathan Cameron , Dmitry Torokhov , Felipe Balbi , linux-iio@vger.kernel.org, linux-input@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 5/5] mfd: input: iio: ti_amm335x: Rework TSC/ADC synchronization Message-ID: <20131220045216.GA3853@gmail.com> References: <1387466911-3732-1-git-send-email-bigeasy@linutronix.de> <1387466911-3732-6-git-send-email-bigeasy@linutronix.de> <20131219190126.GA5123@gmail.com> <52B3FC6C.1070105@linutronix.de> <20131220033634.GB2596@gmail.com> <52B405E9.2020304@linutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii In-Reply-To: <52B405E9.2020304@linutronix.de> List-ID: On Fri, Dec 20, 2013 at 09:55:05AM +0100, Sebastian Andrzej Siewior wrote: > On 12/20/2013 04:36 AM, Zubair Lutfullah : wrote: > > Indeed, due to the separation of TSC/ADC drivers, getting > > them both to work simultaneously without fault is tricky. > > The race window which leads to the lockup is (as I believe) when the > hardware is finishing its work for the TSC (pre interrupt) and the ADC > parts writes to the SE register. As long as you allow both parts to > write to the register bad things can happen (as it seems). So it does > not matter if you have two drivers or one :) > Hmm. That makes sense. At the moment, the ADC/TSC handshake is when the ADC wants to read samples. Would it be wiser to have a handshake and wait for whenever ADC/TSC wants to write to the SE register? Thanks Zubair