From mboxrd@z Thu Jan 1 00:00:00 1970 From: =?utf-8?Q?Beno=C3=AEt_Th=C3=A9baudeau?= Date: Sun, 29 Sep 2013 21:45:30 +0200 (CEST) Subject: [U-Boot] [PATCH] gpio: mxc_gpio: Fix gpio_get_value() when the GPIO is an output In-Reply-To: References: <1380388964-26009-1-git-send-email-festevam@gmail.com> <20130929202643.7dbf897f@e6520eb> <465699757.2248213.1380480659931.JavaMail.zimbra@advansee.com> <213642590.2248385.1380482724389.JavaMail.zimbra@advansee.com> Message-ID: <1056648236.2248666.1380483930698.JavaMail.zimbra@advansee.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi Otavio, On Sunday, September 29, 2013 9:42:44 PM, Otavio Salvador wrote: > On Sun, Sep 29, 2013 at 4:25 PM, Beno?t Th?baudeau > wrote: > ... > > Hence, gpio_get_value() should be left unchanged (using PSR in all cases), > > and > > SION should be set for all GPIOs in the i.MX6 pin definition header files. > > I just does not follow why this preferred against Fabio's proposed > patch to read from DR? Because in case of a level conflict between the GPIO output and some other hardware on the board, one would expect gpio_get_value() to return the actual pin level, and not the level that the GPIO output tries (but possibly fails) to apply on this pin. Best regards, Beno?t