From patchwork Mon Feb 9 04:55:08 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Brownell X-Patchwork-Id: 6158 X-Patchwork-Delegate: tony@atomide.com Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n194tEp3006763 for ; Mon, 9 Feb 2009 04:55:15 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753928AbZBIEzM (ORCPT ); Sun, 8 Feb 2009 23:55:12 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753934AbZBIEzM (ORCPT ); Sun, 8 Feb 2009 23:55:12 -0500 Received: from smtp127.sbc.mail.sp1.yahoo.com ([69.147.65.186]:34756 "HELO smtp127.sbc.mail.sp1.yahoo.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1753928AbZBIEzL (ORCPT ); Sun, 8 Feb 2009 23:55:11 -0500 Received: (qmail 58502 invoked from network); 9 Feb 2009 04:55:10 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=pacbell.net; h=Received:X-YMail-OSG:X-Yahoo-Newman-Property:From:To:Subject:Date:User-Agent:Cc:MIME-Version:Content-Type:Content-Transfer-Encoding:Content-Disposition:Message-Id; b=F4fO/cYjN66Q4wAFLZeyofFK/BjCC+r073S7H+yWMpCRYsMuWGevpan42TRlWSCGanuoyAKNGSeHl8HEXWskg0QEj/0QzCrcgDx+0SRDQZ9+d0Am+Vti7ofrUhMz5254cAFuolzkogFNNcV12FCUu3fv9Kw667R3pLOhEPdoukg= ; Received: from unknown (HELO pogo) (david-b@69.226.224.20 with plain) by smtp127.sbc.mail.sp1.yahoo.com with SMTP; 9 Feb 2009 04:55:09 -0000 X-YMail-OSG: I8gae4AVM1mifHh5Yn4LWrH3clOIILvIOCTaZbvNyCVImsyMPHmbRZ3tckaod6ZFnpWcOHb1Zc_JqtWKlI1VsH5O2DJMSYLXP00LiaJALKHye7.BR7GJOe11A4oMYEXvfxF9g8Kb70GvkHMQj.bvCaclRZkqNEbsgkLYID.q0RHM2pKSIPH.jm7.jGPzEfU2H2lppEtPNi4AjvYagQidejep8jBRLeyzAA239g-- X-Yahoo-Newman-Property: ymail-3 From: David Brownell To: OMAP Subject: [patch 2.6.29-rc3-omap-git] omap3: gpio pin config bugfixes Date: Sun, 8 Feb 2009 20:55:08 -0800 User-Agent: KMail/1.9.10 Cc: Manikandan Pillai MIME-Version: 1.0 Content-Disposition: inline Message-Id: <200902082055.08954.david-b@pacbell.net> Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org From: David Brownell Bugfix several GPIO mux configurations which didn't enable the input drivers, but weren't named as e.g. ..._GPIO141_OUT. These bugs were added quite recently, for OMAP3 EVM support. To help avoid such bugs in the future, update the comment to clarify the rule: always use PIN_INPUT, unless the name uses that name suffix, to be crystal-clear on the signal's use as output-only. (Also adds GPIO-63, for the EVM's MMC-1 writeprotect switch. Presumably that works right...) Signed-off-by: David Brownell --- arch/arm/mach-omap2/mux.c | 13 ++++++++----- arch/arm/plat-omap/include/mach/mux.h | 1 + 2 files changed, 9 insertions(+), 5 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html --- a/arch/arm/mach-omap2/mux.c +++ b/arch/arm/mach-omap2/mux.c @@ -453,6 +453,7 @@ MUX_CFG_34XX("AC1_3430_USB3FS_PHY_MM3_TX /* 34XX GPIO - bidirectional, unless the name has an "_OUT" suffix. + * (Always specify PIN_INPUT, except for names suffixed by "_OUT".) * No internal pullup/pulldown without "_UP" or "_DOWN" suffix. */ MUX_CFG_34XX("AH8_34XX_GPIO29", 0x5fa, @@ -460,17 +461,19 @@ MUX_CFG_34XX("AH8_34XX_GPIO29", 0x5fa, MUX_CFG_34XX("J25_34XX_GPIO170", 0x1c6, OMAP34XX_MUX_MODE4 | OMAP34XX_PIN_INPUT) MUX_CFG_34XX("AF26_34XX_GPIO0", 0x1e0, - OMAP34XX_MUX_MODE4 | OMAP34XX_PIN_OUTPUT) + OMAP34XX_MUX_MODE4 | OMAP34XX_PIN_INPUT) MUX_CFG_34XX("AF22_34XX_GPIO9", 0xa18, - OMAP34XX_MUX_MODE4 | OMAP34XX_PIN_OUTPUT) + OMAP34XX_MUX_MODE4 | OMAP34XX_PIN_INPUT) +MUX_CFG_34XX("L8_34XX_GPIO63", 0x0ce, + OMAP34XX_MUX_MODE4 | OMAP34XX_PIN_INPUT) MUX_CFG_34XX("AF6_34XX_GPIO140_UP", 0x16c, OMAP34XX_MUX_MODE4 | OMAP34XX_PIN_INPUT_PULLUP) MUX_CFG_34XX("AE6_34XX_GPIO141", 0x16e, - OMAP34XX_MUX_MODE4 | OMAP34XX_PIN_OUTPUT) + OMAP34XX_MUX_MODE4 | OMAP34XX_PIN_INPUT) MUX_CFG_34XX("AF5_34XX_GPIO142", 0x170, - OMAP34XX_MUX_MODE4 | OMAP34XX_PIN_OUTPUT) + OMAP34XX_MUX_MODE4 | OMAP34XX_PIN_INPUT) MUX_CFG_34XX("AE5_34XX_GPIO143", 0x172, - OMAP34XX_MUX_MODE4 | OMAP34XX_PIN_OUTPUT) + OMAP34XX_MUX_MODE4 | OMAP34XX_PIN_INPUT) }; --- a/arch/arm/plat-omap/include/mach/mux.h +++ b/arch/arm/plat-omap/include/mach/mux.h @@ -792,6 +792,7 @@ enum omap34xx_index { J25_34XX_GPIO170, AF26_34XX_GPIO0, AF22_34XX_GPIO9, + L8_34XX_GPIO63, AF6_34XX_GPIO140_UP, AE6_34XX_GPIO141, AF5_34XX_GPIO142,