From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Sender: rtc-linux@googlegroups.com Received: from mail.free-electrons.com (down.free-electrons.com. [37.187.137.238]) by gmr-mx.google.com with ESMTP id o85si178772wme.0.2016.07.21.04.10.30 for ; Thu, 21 Jul 2016 04:10:30 -0700 (PDT) Date: Thu, 21 Jul 2016 13:10:08 +0200 From: Alexandre Belloni To: =?iso-8859-1?Q?Beno=EEt_Th=E9baudeau?= Cc: rtc-linux@googlegroups.com, linux-kernel@vger.kernel.org, Alessandro Zummo Subject: =?UTF-8?Q?=5Brtc=2Dlinux=5D_Re=3A_=5BPATCH_4=2F6=5D_rtc=3A_rv8803=3A_Always_appl?= =?UTF-8?Q?y_the_I=C2=B2C_workaround?= Message-ID: <20160721111008.GE4446@piout.net> References: <1469097692-103146-1-git-send-email-benoit@wsystem.com> <1469097692-103146-4-git-send-email-benoit@wsystem.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 In-Reply-To: <1469097692-103146-4-git-send-email-benoit@wsystem.com> Reply-To: rtc-linux@googlegroups.com List-ID: List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , On 21/07/2016 at 12:41:30 +0200, Beno=C3=AEt Th=C3=A9baudeau wrote : > The I=C2=B2C NACK issue of the RV-8803 may occur after any I=C2=B2C START > condition, depending on the timings. Consequently, the workaround must > be applied for all the I=C2=B2C transfers. >=20 > This commit abstracts the I=C2=B2C transfer code into register access > functions. This avoids duplicating the I=C2=B2C workaround everywhere. Th= is > also avoids the duplication of the code handling the return value of > i2c_smbus_read_i2c_block_data(). Error messages are issued in case of > definitive register access failures (if the workaround fails). This > change also makes the I=C2=B2C transfer return value checks consistent. >=20 Well, my initial idea was that the workaround is actually needed only for operations that are not restartable from userspace. Did you it that bug? On which RTC? --=20 Alexandre Belloni, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com --=20 You received this message because you are subscribed to "rtc-linux". Membership options at http://groups.google.com/group/rtc-linux . Please read http://groups.google.com/group/rtc-linux/web/checklist before submitting a driver. ---=20 You received this message because you are subscribed to the Google Groups "= rtc-linux" group. To unsubscribe from this group and stop receiving emails from it, send an e= mail to rtc-linux+unsubscribe@googlegroups.com. For more options, visit https://groups.google.com/d/optout. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752504AbcGULKh (ORCPT ); Thu, 21 Jul 2016 07:10:37 -0400 Received: from down.free-electrons.com ([37.187.137.238]:46795 "EHLO mail.free-electrons.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752327AbcGULKc (ORCPT ); Thu, 21 Jul 2016 07:10:32 -0400 Date: Thu, 21 Jul 2016 13:10:08 +0200 From: Alexandre Belloni To: =?iso-8859-1?Q?Beno=EEt_Th=E9baudeau?= Cc: rtc-linux@googlegroups.com, linux-kernel@vger.kernel.org, Alessandro Zummo Subject: Re: [PATCH 4/6] rtc: =?iso-8859-1?Q?rv8803?= =?iso-8859-1?Q?=3A_Always_apply_the_I=B2C?= workaround Message-ID: <20160721111008.GE4446@piout.net> References: <1469097692-103146-1-git-send-email-benoit@wsystem.com> <1469097692-103146-4-git-send-email-benoit@wsystem.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <1469097692-103146-4-git-send-email-benoit@wsystem.com> User-Agent: Mutt/1.6.0 (2016-04-01) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 21/07/2016 at 12:41:30 +0200, Benoît Thébaudeau wrote : > The I²C NACK issue of the RV-8803 may occur after any I²C START > condition, depending on the timings. Consequently, the workaround must > be applied for all the I²C transfers. > > This commit abstracts the I²C transfer code into register access > functions. This avoids duplicating the I²C workaround everywhere. This > also avoids the duplication of the code handling the return value of > i2c_smbus_read_i2c_block_data(). Error messages are issued in case of > definitive register access failures (if the workaround fails). This > change also makes the I²C transfer return value checks consistent. > Well, my initial idea was that the workaround is actually needed only for operations that are not restartable from userspace. Did you it that bug? On which RTC? -- Alexandre Belloni, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com