From patchwork Tue May 1 12:23:20 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mohammed Afzal X-Patchwork-Id: 156122 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from merlin.infradead.org (merlin.infradead.org [IPv6:2001:4978:20e::2]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id BF246B6FA7 for ; Tue, 1 May 2012 23:26:44 +1000 (EST) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1SPD2k-0001IY-KR; Tue, 01 May 2012 13:23:03 +0000 Received: from comal.ext.ti.com ([198.47.26.152]) by merlin.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1SPCNQ-00017B-9C; Tue, 01 May 2012 12:40:22 +0000 Received: from dlelxv30.itg.ti.com ([172.17.2.17]) by comal.ext.ti.com (8.13.7/8.13.7) with ESMTP id q41CeA2f027848; Tue, 1 May 2012 07:40:10 -0500 Received: from DFLE71.ent.ti.com (dfle71.ent.ti.com [128.247.5.62]) by dlelxv30.itg.ti.com (8.13.8/8.13.8) with ESMTP id q41CeAq2028335; Tue, 1 May 2012 07:40:10 -0500 Received: from dlelxv24.itg.ti.com (172.17.1.199) by dfle71.ent.ti.com (128.247.5.62) with Microsoft SMTP Server id 14.1.323.3; Tue, 1 May 2012 07:40:09 -0500 Received: from ucmsshproxy.india.ext.ti.com (dbdp20.itg.ti.com [172.24.170.38]) by dlelxv24.itg.ti.com (8.13.8/8.13.8) with SMTP id q41Ce3kG020200; Tue, 1 May 2012 07:40:04 -0500 Received: from symphony.india.ext.ti.com (unknown [192.168.247.13]) by ucmsshproxy.india.ext.ti.com (Postfix) with ESMTP id 4CA08158002; Tue, 1 May 2012 18:10:03 +0530 (IST) Received: from linux-psp-server.india.ext.ti.com (linux-psp-server [192.168.247.76]) by symphony.india.ext.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id q41Ce2I18724; Tue, 1 May 2012 18:10:02 +0530 (IST) From: Afzal Mohammed To: , , , , , , , , , , , , , , , , Subject: [PATCH v4 33/39] ARM: OMAP2+: board omap4pcm049: gpmc driver adaptation Date: Tue, 1 May 2012 17:53:20 +0530 Message-ID: <5defad2fdc7a94ccb4275b544a8396c18aa46093.1335874494.git.afzal@ti.com> X-Mailer: git-send-email 1.7.10 In-Reply-To: References: MIME-Version: 1.0 X-Spam-Note: CRM114 invocation failed X-Spam-Score: -6.9 (------) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-6.9 points) pts rule name description ---- ---------------------- -------------------------------------------------- -5.0 RCVD_IN_DNSWL_HI RBL: Sender listed at http://www.dnswl.org/, high trust [198.47.26.152 listed in list.dnswl.org] -0.0 T_RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: Afzal Mohammed X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-mtd-bounces@lists.infradead.org Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org gpmc code has been converted to driver. Modify the board code to provide gpmc driver with required information. Signed-off-by: Afzal Mohammed --- arch/arm/mach-omap2/board-omap4pcm049.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/arch/arm/mach-omap2/board-omap4pcm049.c b/arch/arm/mach-omap2/board-omap4pcm049.c index 81de7d5..b4ead86 100644 --- a/arch/arm/mach-omap2/board-omap4pcm049.c +++ b/arch/arm/mach-omap2/board-omap4pcm049.c @@ -130,6 +130,12 @@ static struct omap2_hsmmc_info mmc[] = { }, {} /* Terminator */ }; +static struct gpmc_device_pdata *gpmc_device_data[1]; + +static struct gpmc_pdata gpmc_data = { + .device_pdata = gpmc_device_data, +}; + #if defined(CONFIG_SMSC911X) || defined(CONFIG_SMSC911X_MODULE) static struct regulator_consumer_supply dummy_supplies[] = { REGULATOR_SUPPLY("vddvario", "smsc911x.0"), @@ -147,7 +153,11 @@ static inline void __init pcm049_init_smsc911x(void) { omap_mux_init_gpio(OMAP4_PCM049_ETH_GPIO_IRQ, OMAP_PIN_INPUT); regulator_register_fixed(0, dummy_supplies, ARRAY_SIZE(dummy_supplies)); - gpmc_smsc911x_init(&board_smsc911x_data); + *gpmc_device_data = gpmc_smsc911x_init(&board_smsc911x_data); + if (*gpmc_device_data) + gpmc_data.num_device++; + else + pr_err("error: unable to initilaize gpmc smsc911x\n"); } #else static inline void __init pcm049_init_smsc911x(void) { return; } @@ -562,6 +572,7 @@ static void __init pcm049_init(void) pm_power_off = pcm049_power_off; omap4_mux_init(board_mux, NULL, OMAP_PACKAGE_CBS); pcm049_init_smsc911x(); + omap_init_gpmc(&gpmc_data); pcm049_i2c_init(); platform_add_devices(pcm049_devices, ARRAY_SIZE(pcm049_devices)); board_serial_init();