From patchwork Mon Aug 23 15:58:08 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Senthilvadivu Guruswamy X-Patchwork-Id: 124631 X-Patchwork-Delegate: khilman@deeprootsystems.com Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.4/8.14.3) with ESMTP id o7NFwQVR016508 for ; Mon, 23 Aug 2010 15:59:06 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754261Ab0HWP62 (ORCPT ); Mon, 23 Aug 2010 11:58:28 -0400 Received: from arroyo.ext.ti.com ([192.94.94.40]:38244 "EHLO arroyo.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754239Ab0HWP6Z (ORCPT ); Mon, 23 Aug 2010 11:58:25 -0400 Received: from dbdp31.itg.ti.com ([172.24.170.98]) by arroyo.ext.ti.com (8.13.7/8.13.7) with ESMTP id o7NFwGR0028346 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 23 Aug 2010 10:58:19 -0500 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 o7NFwEE9001758; Mon, 23 Aug 2010 21:28:14 +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 o7NFwDkq011286; Mon, 23 Aug 2010 21:28:13 +0530 Received: (from a0876342@localhost) by linfarm476.india.ti.com (8.12.11/8.12.11/Submit) id o7NFwDmH011284; Mon, 23 Aug 2010 21:28:13 +0530 From: Guruswamy Senthilvadivu To: linux-omap@vger.kernel.org, tomi.valkeinen@nokia.com, paul@pwsan.com, khilman@ti.com Cc: Senthilvadivu Guruswamy Subject: [PATCH 19/20] Get RFBI baseaddr with platform device Date: Mon, 23 Aug 2010 21:28:08 +0530 Message-Id: <1282579089-10487-20-git-send-email-svadivu@ti.com> X-Mailer: git-send-email 1.5.6.6 In-Reply-To: <1282579089-10487-19-git-send-email-svadivu@ti.com> References: <1282579089-10487-1-git-send-email-svadivu@ti.com> <1282579089-10487-2-git-send-email-svadivu@ti.com> <1282579089-10487-3-git-send-email-svadivu@ti.com> <1282579089-10487-4-git-send-email-svadivu@ti.com> <1282579089-10487-5-git-send-email-svadivu@ti.com> <1282579089-10487-6-git-send-email-svadivu@ti.com> <1282579089-10487-7-git-send-email-svadivu@ti.com> <1282579089-10487-8-git-send-email-svadivu@ti.com> <1282579089-10487-9-git-send-email-svadivu@ti.com> <1282579089-10487-10-git-send-email-svadivu@ti.com> <1282579089-10487-11-git-send-email-svadivu@ti.com> <1282579089-10487-12-git-send-email-svadivu@ti.com> <1282579089-10487-13-git-send-email-svadivu@ti.com> <1282579089-10487-14-git-send-email-svadivu@ti.com> <1282579089-10487-15-git-send-email-svadivu@ti.com> <1282579089-10487-16-git-send-email-svadivu@ti.com> <1282579089-10487-17-git-send-email-svadivu@ti.com> <1282579089-10487-18-git-send-email-svadivu@ti.com> <1282579089-10487-19-git-send-email-svadivu@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.3 (demeter.kernel.org [140.211.167.41]); Mon, 23 Aug 2010 15:59:06 +0000 (UTC) diff --git a/drivers/video/omap2/dss/rfbi.c b/drivers/video/omap2/dss/rfbi.c index fe4f423..690f7bf 100644 --- a/drivers/video/omap2/dss/rfbi.c +++ b/drivers/video/omap2/dss/rfbi.c @@ -36,7 +36,6 @@ #include #include "dss.h" -#define RFBI_BASE 0x48050800 struct rfbi_reg { u16 idx; }; @@ -961,6 +960,7 @@ int rfbi_init(struct platform_device *pdev) { u32 rev; u32 l; + struct resource *rfbi_mem; spin_lock_init(&rfbi.cmd_lock); @@ -968,7 +968,8 @@ int rfbi_init(struct platform_device *pdev) atomic_set(&rfbi.cmd_fifo_full, 0); atomic_set(&rfbi.cmd_pending, 0); - rfbi.base = ioremap(RFBI_BASE, SZ_256); + rfbi_mem = platform_get_resource(pdev, IORESOURCE_MEM, 0); + rfbi.base = ioremap(rfbi_mem->start, resource_size(rfbi_mem)); if (!rfbi.base) { DSSERR("can't ioremap RFBI\n"); return -ENOMEM;