summaryrefslogtreecommitdiff
path: root/arch/powerpc/sysdev/mpic_msgr.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/powerpc/sysdev/mpic_msgr.c')
-rw-r--r--arch/powerpc/sysdev/mpic_msgr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/powerpc/sysdev/mpic_msgr.c b/arch/powerpc/sysdev/mpic_msgr.c
index eb69a5186243..280e964e1aa8 100644
--- a/arch/powerpc/sysdev/mpic_msgr.c
+++ b/arch/powerpc/sysdev/mpic_msgr.c
@@ -196,7 +196,7 @@ static int mpic_msgr_probe(struct platform_device *dev)
/* IO map the message register block. */
of_address_to_resource(np, 0, &rsrc);
- msgr_block_addr = ioremap(rsrc.start, rsrc.end - rsrc.start);
+ msgr_block_addr = ioremap(rsrc.start, resource_size(&rsrc));
if (!msgr_block_addr) {
dev_err(&dev->dev, "Failed to iomap MPIC message registers");
return -EFAULT;