treewide: Convert uses of struct resource to resource_size(ptr)
Several fixes as well where the +1 was missing. Done via coccinelle scripts like: @@ struct resource *ptr; @@ - ptr->end - ptr->start + 1 + resource_size(ptr) and some grep and typing. Mostly uncompiled, no cross-compilers. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
This commit is contained in:
@@ -491,7 +491,7 @@ static int gianfar_ptp_probe(struct platform_device *dev)
|
||||
spin_lock_init(&etsects->lock);
|
||||
|
||||
etsects->regs = ioremap(etsects->rsrc->start,
|
||||
1 + etsects->rsrc->end - etsects->rsrc->start);
|
||||
resource_size(etsects->rsrc));
|
||||
if (!etsects->regs) {
|
||||
pr_err("ioremap ptp registers failed\n");
|
||||
goto no_ioremap;
|
||||
|
Reference in New Issue
Block a user