From patchwork Fri Jul 8 15:59:47 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Aisheng Dong X-Patchwork-Id: 956772 Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by demeter2.kernel.org (8.14.4/8.14.4) with ESMTP id p68FfLaP029844 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Fri, 8 Jul 2011 15:41:43 GMT Received: from canuck.infradead.org ([2001:4978:20e::1]) by merlin.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1QfDAz-0000SK-Bt; Fri, 08 Jul 2011 15:41:10 +0000 Received: from localhost ([127.0.0.1] helo=canuck.infradead.org) by canuck.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1QfDAy-0001yo-Lf; Fri, 08 Jul 2011 15:41:08 +0000 Received: from tx2ehsobe001.messaging.microsoft.com ([65.55.88.11] helo=TX2EHSOBE001.bigfish.com) by canuck.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1QfDA9-0001gs-Al for linux-arm-kernel@lists.infradead.org; Fri, 08 Jul 2011 15:40:18 +0000 Received: from mail139-tx2-R.bigfish.com (10.9.14.237) by TX2EHSOBE001.bigfish.com (10.9.40.21) with Microsoft SMTP Server id 14.1.225.22; Fri, 8 Jul 2011 15:40:16 +0000 Received: from mail139-tx2 (localhost.localdomain [127.0.0.1]) by mail139-tx2-R.bigfish.com (Postfix) with ESMTP id 0431915D8275; Fri, 8 Jul 2011 15:40:16 +0000 (UTC) X-SpamScore: 3 X-BigFish: VS3(zzzz1202h1082kzz8275bhz2dh2a8h668h839h61h) X-Spam-TCS-SCL: 0:0 X-Forefront-Antispam-Report: CIP:70.37.183.190; KIP:(null); UIP:(null); IPVD:NLI; H:mail.freescale.net; RD:none; EFVD:NLI Received: from mail139-tx2 (localhost.localdomain [127.0.0.1]) by mail139-tx2 (MessageSwitch) id 1310139577255157_7724; Fri, 8 Jul 2011 15:39:37 +0000 (UTC) Received: from TX2EHSMHS012.bigfish.com (unknown [10.9.14.244]) by mail139-tx2.bigfish.com (Postfix) with ESMTP id EE69D8180AE; Fri, 8 Jul 2011 15:37:33 +0000 (UTC) Received: from mail.freescale.net (70.37.183.190) by TX2EHSMHS012.bigfish.com (10.9.99.112) with Microsoft SMTP Server (TLS) id 14.1.225.22; Fri, 8 Jul 2011 15:37:31 +0000 Received: from az33smr01.freescale.net (10.64.34.199) by 039-SN1MMR1-002.039d.mgd.msft.net (10.84.1.15) with Microsoft SMTP Server id 14.1.289.8; Fri, 8 Jul 2011 10:37:30 -0500 Received: from localhost.localdomain (shlinux2.ap.freescale.net [10.192.224.44]) by az33smr01.freescale.net (8.13.1/8.13.0) with ESMTP id p68FbDOT001162; Fri, 8 Jul 2011 10:37:29 -0500 (CDT) From: Dong Aisheng To: Subject: [PATCH 07/10] ARM: mxs: add sgtl5000 i2c device Date: Fri, 8 Jul 2011 23:59:47 +0800 Message-ID: <1310140790-2132-8-git-send-email-b29396@freescale.com> X-Mailer: git-send-email 1.7.0.4 In-Reply-To: <1310140790-2132-1-git-send-email-b29396@freescale.com> References: <1310140790-2132-1-git-send-email-b29396@freescale.com> MIME-Version: 1.0 X-OriginatorOrg: freescale.com X-CRM114-Version: 20090807-BlameThorstenAndJenny ( TRE 0.7.6 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20110708_114017_530650_10CB0A72 X-CRM114-Status: GOOD ( 15.08 ) X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.3.1 on canuck.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, medium trust [65.55.88.11 listed in list.dnswl.org] Cc: s.hauer@pengutronix.de, lrg@ti.com, linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter2.kernel.org [140.211.167.43]); Fri, 08 Jul 2011 15:41:43 +0000 (UTC) Signed-off-by: Dong Aisheng --- arch/arm/mach-mxs/mach-mx28evk.c | 16 ++++++++++++++++ 1 files changed, 16 insertions(+), 0 deletions(-) diff --git a/arch/arm/mach-mxs/mach-mx28evk.c b/arch/arm/mach-mxs/mach-mx28evk.c index 7837a87..c8b154a 100644 --- a/arch/arm/mach-mxs/mach-mx28evk.c +++ b/arch/arm/mach-mxs/mach-mx28evk.c @@ -186,6 +186,12 @@ static const iomux_cfg_t mx28evk_pads[] __initconst = { /* led */ MX28_PAD_AUART1_TX__GPIO_3_5 | MXS_PAD_CTRL, + /* I2C */ + MX28_PAD_I2C0_SCL__I2C0_SCL | + (MXS_PAD_8MA | MXS_PAD_3V3 | MXS_PAD_PULLUP), + MX28_PAD_I2C0_SDA__I2C0_SDA | + (MXS_PAD_8MA | MXS_PAD_3V3 | MXS_PAD_PULLUP), + /* saif0 & saif1 */ MX28_PAD_SAIF0_MCLK__SAIF0_MCLK | (MXS_PAD_12MA | MXS_PAD_3V3 | MXS_PAD_PULLUP), @@ -366,6 +372,12 @@ static struct mxs_mmc_platform_data mx28evk_mmc_pdata[] __initdata = { }, }; +static struct i2c_board_info mxs_i2c0_board_info[] __initdata = { + { + I2C_BOARD_INFO("sgtl5000", 0x0a), + }, +}; + static void __init mx28evk_init(void) { int ret; @@ -409,6 +421,10 @@ static void __init mx28evk_init(void) mx28_add_saif(0); mx28_add_saif(1); + mx28_add_mxs_i2c(0); + i2c_register_board_info(0, mxs_i2c0_board_info, + ARRAY_SIZE(mxs_i2c0_board_info)); + /*set the saif clk mux, both saif0/saif1 use saif0 clk*/ __raw_writel(0x2 << 10, DIGCTRL_BASE_ADDR);