summaryrefslogtreecommitdiffstats
path: root/drivers/mtd/nand/mpc5121_nfc.c
diff options
context:
space:
mode:
authorJoe Perches2011-06-09 18:13:32 +0200
committerJiri Kosina2011-06-10 14:55:36 +0200
commit28f65c11f2ffb3957259dece647a24f8ad2e241b (patch)
tree6b7621d09d10df89eedd908d4506fb9f457a909f /drivers/mtd/nand/mpc5121_nfc.c
parentmm Kconfig typo: cleancacne -> cleancache (diff)
downloadkernel-qcow2-linux-28f65c11f2ffb3957259dece647a24f8ad2e241b.tar.gz
kernel-qcow2-linux-28f65c11f2ffb3957259dece647a24f8ad2e241b.tar.xz
kernel-qcow2-linux-28f65c11f2ffb3957259dece647a24f8ad2e241b.zip
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>
Diffstat (limited to 'drivers/mtd/nand/mpc5121_nfc.c')
-rw-r--r--drivers/mtd/nand/mpc5121_nfc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mtd/nand/mpc5121_nfc.c b/drivers/mtd/nand/mpc5121_nfc.c
index 2f7c930872f9..eb1fbac63eb6 100644
--- a/drivers/mtd/nand/mpc5121_nfc.c
+++ b/drivers/mtd/nand/mpc5121_nfc.c
@@ -713,7 +713,7 @@ static int __devinit mpc5121_nfc_probe(struct platform_device *op)
}
regs_paddr = res.start;
- regs_size = res.end - res.start + 1;
+ regs_size = resource_size(&res);
if (!devm_request_mem_region(dev, regs_paddr, regs_size, DRV_NAME)) {
dev_err(dev, "Error requesting memory region!\n");