aboutsummaryrefslogtreecommitdiff
path: root/drivers/ide/mips
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ide/mips')
-rw-r--r--drivers/ide/mips/au1xxx-ide.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/ide/mips/au1xxx-ide.c b/drivers/ide/mips/au1xxx-ide.c
index f84411b6609..85c016bdfd3 100644
--- a/drivers/ide/mips/au1xxx-ide.c
+++ b/drivers/ide/mips/au1xxx-ide.c
@@ -586,13 +586,14 @@ static int au_ide_probe(struct device *dev)
goto out;
}
- if (!request_mem_region (res->start, res->end-res->start, pdev->name)) {
+ if (!request_mem_region(res->start, res->end - res->start + 1,
+ pdev->name)) {
pr_debug("%s: request_mem_region failed\n", DRV_NAME);
ret = -EBUSY;
goto out;
}
- ahwif->regbase = (u32)ioremap(res->start, res->end-res->start);
+ ahwif->regbase = (u32)ioremap(res->start, res->end - res->start + 1);
if (ahwif->regbase == 0) {
ret = -ENOMEM;
goto out;
@@ -677,7 +678,7 @@ static int au_ide_remove(struct device *dev)
iounmap((void *)ahwif->regbase);
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- release_mem_region(res->start, res->end - res->start);
+ release_mem_region(res->start, res->end - res->start + 1);
return 0;
}