[<prev] [next>] [day] [month] [year] [list]
Message-ID: <BD79186B4FD85F4B8E60E381CAEE190901FB10D8@mi8nycmail19.Mi8.com>
Date: Fri, 11 Dec 2009 16:50:58 -0500
From: "H Hartley Sweeten" <hartleys@...ionengravers.com>
To: "kernel list" <linux-kernel@...r.kernel.org>
Cc: <rpurdie@...ys.net>, <gregkh@...e.de>
Subject: [PATCH] leds-cobalt-qube.c: use resource_size()
Use resource_size() for ioremap.
Signed-off-by: H Hartley Sweeten <hsweeten@...ionengravers.com>
Cc: Richard Purdie <rpurdie@...ys.net>
Cc: Greg Kroah-Hartman <gregkh@...e.de>
---
diff --git a/drivers/leds/leds-cobalt-qube.c b/drivers/leds/leds-cobalt-qube.c
index 8816806..de19753 100644
--- a/drivers/leds/leds-cobalt-qube.c
+++ b/drivers/leds/leds-cobalt-qube.c
@@ -43,7 +43,7 @@ static int __devinit cobalt_qube_led_probe(struct platform_device *pdev)
if (!res)
return -EBUSY;
- led_port = ioremap(res->start, res->end - res->start + 1);
+ led_port = ioremap(res->start, resource_size(res));
if (!led_port)
return -ENOMEM;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists