All of lore.kernel.org
 help / color / mirror / Atom feed
From: Felipe Balbi <balbi@ti.com>
To: Tony Lindgren <tony@atomide.com>
Cc: Linux OMAP Mailing List <linux-omap@vger.kernel.org>,
	Linux ARM Kernel Mailing List
	<linux-arm-kernel@lists.infradead.org>,
	Felipe Balbi <balbi@ti.com>
Subject: [PATCH 5/5] arm: omap: debug-leds: switch to resource_size()
Date: Tue, 24 Jul 2012 11:54:02 +0300	[thread overview]
Message-ID: <1343120042-16695-6-git-send-email-balbi@ti.com> (raw)
In-Reply-To: <1343120042-16695-1-git-send-email-balbi@ti.com>

instead of hardcoding the address space size, we
can calculate it using resource_size() helper.

Signed-off-by: Felipe Balbi <balbi@ti.com>
---
 arch/arm/plat-omap/debug-leds.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/plat-omap/debug-leds.c b/arch/arm/plat-omap/debug-leds.c
index 08fbb85..ebc0317 100644
--- a/arch/arm/plat-omap/debug-leds.c
+++ b/arch/arm/plat-omap/debug-leds.c
@@ -272,7 +272,7 @@ static int __devinit fpga_probe(struct platform_device *pdev)
 	if (!iomem)
 		return -ENODEV;
 
-	fpga = ioremap(iomem->start, H2P2_DBG_FPGA_SIZE);
+	fpga = ioremap(iomem->start, resource_size(iomem));
 	__raw_writew(~0, &fpga->leds);
 
 #ifdef	CONFIG_LEDS
-- 
1.7.11


WARNING: multiple messages have this Message-ID (diff)
From: balbi@ti.com (Felipe Balbi)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 5/5] arm: omap: debug-leds: switch to resource_size()
Date: Tue, 24 Jul 2012 11:54:02 +0300	[thread overview]
Message-ID: <1343120042-16695-6-git-send-email-balbi@ti.com> (raw)
In-Reply-To: <1343120042-16695-1-git-send-email-balbi@ti.com>

instead of hardcoding the address space size, we
can calculate it using resource_size() helper.

Signed-off-by: Felipe Balbi <balbi@ti.com>
---
 arch/arm/plat-omap/debug-leds.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/plat-omap/debug-leds.c b/arch/arm/plat-omap/debug-leds.c
index 08fbb85..ebc0317 100644
--- a/arch/arm/plat-omap/debug-leds.c
+++ b/arch/arm/plat-omap/debug-leds.c
@@ -272,7 +272,7 @@ static int __devinit fpga_probe(struct platform_device *pdev)
 	if (!iomem)
 		return -ENODEV;
 
-	fpga = ioremap(iomem->start, H2P2_DBG_FPGA_SIZE);
+	fpga = ioremap(iomem->start, resource_size(iomem));
 	__raw_writew(~0, &fpga->leds);
 
 #ifdef	CONFIG_LEDS
-- 
1.7.11

  parent reply	other threads:[~2012-07-24  8:57 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-24  8:53 [PATCH 0/5] arm: omap: debug-leds: few changes Felipe Balbi
2012-07-24  8:53 ` Felipe Balbi
2012-07-24  8:53 ` [PATCH 1/5] arm: omap: debug-leds: drop machine_is_* checks Felipe Balbi
2012-07-24  8:53   ` Felipe Balbi
2012-07-24  8:53 ` [PATCH 2/5] arm: omap: debug-leds: move initialization to debug-leds Felipe Balbi
2012-07-24  8:53   ` Felipe Balbi
2012-07-24  8:54 ` [PATCH 3/5] arm: omap: debug-leds: add section annotation to probe Felipe Balbi
2012-07-24  8:54   ` Felipe Balbi
2012-07-24  8:54 ` [PATCH 4/5] arm: omap: debug-leds: add a remove method Felipe Balbi
2012-07-24  8:54   ` Felipe Balbi
2012-07-24  8:54 ` Felipe Balbi [this message]
2012-07-24  8:54   ` [PATCH 5/5] arm: omap: debug-leds: switch to resource_size() Felipe Balbi
2012-09-07 22:32 ` [PATCH 0/5] arm: omap: debug-leds: few changes Tony Lindgren
2012-09-07 22:32   ` Tony Lindgren

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1343120042-16695-6-git-send-email-balbi@ti.com \
    --to=balbi@ti.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=tony@atomide.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.