From: Benoit Cousson Date: Mon, 12 Nov 2012 10:44:03 +0000 (+0100) Subject: ARM: OMAP: debug-leds: Use resource_size instead of hard coded macro X-Git-Tag: upstream/snapshot3+hdmi~6101^2~13^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8de7e37ef0ad7b4dc39498824c48bde2f4d13828;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git ARM: OMAP: debug-leds: Use resource_size instead of hard coded macro The debug-leds driver should not rely on hard coded macro for the iomem size but use the resource size instead. Signed-off-by: Benoit Cousson Signed-off-by: Tony Lindgren --- diff --git a/arch/arm/plat-omap/debug-leds.c b/arch/arm/plat-omap/debug-leds.c index c43ea21..aa7ebc6 100644 --- a/arch/arm/plat-omap/debug-leds.c +++ b/arch/arm/plat-omap/debug-leds.c @@ -111,7 +111,7 @@ static int 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(0xff, &fpga->leds); for (i = 0; i < ARRAY_SIZE(dbg_leds); i++) {