From patchwork Mon Feb 21 13:46:29 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Santosh Shilimkar X-Patchwork-Id: 577591 X-Patchwork-Delegate: khilman@deeprootsystems.com Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p1LDkcow004726 for ; Mon, 21 Feb 2011 13:46:45 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756064Ab1BUNqn (ORCPT ); Mon, 21 Feb 2011 08:46:43 -0500 Received: from devils.ext.ti.com ([198.47.26.153]:34856 "EHLO devils.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756045Ab1BUNqh (ORCPT ); Mon, 21 Feb 2011 08:46:37 -0500 Received: from dbdp31.itg.ti.com ([172.24.170.98]) by devils.ext.ti.com (8.13.7/8.13.7) with ESMTP id p1LDkXj3006454 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Mon, 21 Feb 2011 07:46:36 -0600 Received: from linfarm476.india.ti.com (localhost [127.0.0.1]) by dbdp31.itg.ti.com (8.13.8/8.13.8) with ESMTP id p1LDkV07013543; Mon, 21 Feb 2011 19:16:31 +0530 (IST) Received: from linfarm476.india.ti.com (localhost [127.0.0.1]) by linfarm476.india.ti.com (8.12.11/8.12.11) with ESMTP id p1LDkVAK001128; Mon, 21 Feb 2011 19:16:31 +0530 Received: (from a0393909@localhost) by linfarm476.india.ti.com (8.12.11/8.12.11/Submit) id p1LDkVDs001126; Mon, 21 Feb 2011 19:16:31 +0530 From: Santosh Shilimkar To: linux-omap@vger.kernel.org Cc: balbi@ti.com, b-cousson@ti.com, r.sricharan@ti.com Subject: [PATCH 5/6] omap4: Initialise the l3 device with the hwmod data. Date: Mon, 21 Feb 2011 19:16:29 +0530 Message-Id: <1298295990-1070-6-git-send-email-santosh.shilimkar@ti.com> X-Mailer: git-send-email 1.5.6.6 In-Reply-To: <1298295990-1070-1-git-send-email-santosh.shilimkar@ti.com> References: <1298295990-1070-1-git-send-email-santosh.shilimkar@ti.com> Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Mon, 21 Feb 2011 13:46:45 +0000 (UTC) diff --git a/arch/arm/mach-omap2/devices.c b/arch/arm/mach-omap2/devices.c index 2d46f55..25fa2ad 100644 --- a/arch/arm/mach-omap2/devices.c +++ b/arch/arm/mach-omap2/devices.c @@ -57,6 +57,29 @@ static int __init omap3_l3_init(void) } postcore_initcall(omap3_l3_init); +static int __init omap4_l3_init(void) +{ + int l; + struct omap_hwmod *oh; + struct omap_device *od; + char oh_name[12]; + + l = snprintf(oh_name, 12, "l3_main_1"); + + oh = omap_hwmod_lookup(oh_name); + + if (!oh) + pr_err("could not look up %s\n", oh_name); + + od = omap_device_build("omap4-l3-interconnect", 0, oh, NULL, + 0, NULL, 0, 0); + + WARN(IS_ERR(od), "could not build omap_device for %s\n", oh_name); + + return PTR_ERR(od); +} +postcore_initcall(omap4_l3_init); + #if defined(CONFIG_VIDEO_OMAP2) || defined(CONFIG_VIDEO_OMAP2_MODULE) static struct resource cam_resources[] = {