Commit 76d6a479 authored by Wolfram Sang's avatar Wolfram Sang Committed by David Woodhouse

mtd: plat-ram: use resource_size

Signed-off-by: default avatarWolfram Sang <w.sang@pengutronix.de>
Signed-off-by: default avatarArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Signed-off-by: default avatarDavid Woodhouse <David.Woodhouse@intel.com>
parent 2763c508
...@@ -175,7 +175,7 @@ static int platram_probe(struct platform_device *pdev) ...@@ -175,7 +175,7 @@ static int platram_probe(struct platform_device *pdev)
/* setup map parameters */ /* setup map parameters */
info->map.phys = res->start; info->map.phys = res->start;
info->map.size = (res->end - res->start) + 1; info->map.size = resource_size(res);
info->map.name = pdata->mapname != NULL ? info->map.name = pdata->mapname != NULL ?
(char *)pdata->mapname : (char *)pdev->name; (char *)pdata->mapname : (char *)pdev->name;
info->map.bankwidth = pdata->bankwidth; info->map.bankwidth = pdata->bankwidth;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment