From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel Kurtz Subject: Re: [PATCH 4/8 v7] drm/i915/intel_i2c: use WAIT cycle, not STOP Date: Tue, 10 Apr 2012 18:56:15 +0800 Message-ID: References: <1333108003-6341-1-git-send-email-djkurtz@chromium.org> <1333108003-6341-5-git-send-email-djkurtz@chromium.org> <20120410103746.GH4115@phenom.ffwll.local> <20120410104147.GI4115@phenom.ffwll.local> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: QUOTED-PRINTABLE Return-path: In-Reply-To: <20120410104147.GI4115@phenom.ffwll.local> Sender: linux-kernel-owner@vger.kernel.org To: Daniel Kurtz , Keith Packard , David Airlie , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Chris Wilson , Benson Leung , Yufeng Shen List-Id: dri-devel@lists.freedesktop.org On Tue, Apr 10, 2012 at 6:41 PM, Daniel Vetter wrote: > On Tue, Apr 10, 2012 at 12:37:46PM +0200, Daniel Vetter wrote: >> On Fri, Mar 30, 2012 at 07:46:39PM +0800, Daniel Kurtz wrote: >> > The i915 is only able to generate a STOP cycle (i.e. finalize an i= 2c >> > transaction) during a DATA or WAIT phase. =A0In other words, the >> > controller rejects a STOP requested as part of the first transacti= on in a >> > sequence. >> > >> > Thus, for the first transaction we must always use a WAIT cycle, d= etect >> > when the device has finished (and is in a WAIT phase), and then ei= ther >> > start the next transaction, or, if there are no more transactions, >> > generate a STOP cycle. >> > >> > Note: Theoretically, the last transaction of a multi-transaction s= equence >> > could initiate a STOP cycle. =A0However, this slight optimization = is left >> > for another patch. =A0We return -ETIMEDOUT if the hardware doesn't >> > deactivate after the STOP cycle. >> > >> > Signed-off-by: Daniel Kurtz >> >> I've re-read gmbus register spec and STOP seems to be allowed even i= n the >> first cycle. Does this patch solve an issue for you? If not, I prefe= r we >> just drop it. STOP does not work in the first cycle, hence the patch. -Daniel > > Actually I'd like to keep the -ETIMEDOUT return value, so maybe we sh= ould > keeep that hunk. I've picked up the previous 3 patches of this series= , the > once after this one here conflict (without this patch here). > -Daniel > -- > Daniel Vetter > Mail: daniel@ffwll.ch > Mobile: +41 (0)79 365 57 48