提交 be088b13 编写于 作者: H H Hartley Sweeten 提交者: Wim Van Sebroeck

[WATCHDOG] rc32434_wdt.c: use resource_size()

The size value passed to ioremap_nocache() is not correct.
Use resource_size() to get the correct value.
Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Phil Sutter <n0-1@freewrt.org>
Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
上级 21278163
......@@ -276,7 +276,7 @@ static int __devinit rc32434_wdt_probe(struct platform_device *pdev)
return -ENODEV;
}
wdt_reg = ioremap_nocache(r->start, r->end - r->start);
wdt_reg = ioremap_nocache(r->start, resource_size(r));
if (!wdt_reg) {
printk(KERN_ERR PFX "failed to remap I/O resources\n");
return -ENXIO;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册