Skip to content

Commit

Permalink
ARM: OMAP: debug-leds: Use resource_size instead of hard coded macro
Browse files Browse the repository at this point in the history
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 <b-cousson@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
  • Loading branch information
Benoit Cousson authored and Tony Lindgren committed Nov 12, 2012
1 parent edf8dde commit 8de7e37
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/arm/plat-omap/debug-leds.c
Original file line number Diff line number Diff line change
Expand Up @@ -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++) {
Expand Down

0 comments on commit 8de7e37

Please sign in to comment.