summaryrefslogtreecommitdiffstats
path: root/drivers/staging/android
diff options
context:
space:
mode:
authorThomas Meyer <thomas@m3y3r.de>2012-01-22 18:34:58 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-02-08 16:47:51 -0800
commit8d438bef6556315a23781fd673f13f7bfb94047d (patch)
tree67701c004c74dfbb676eba64b659c7ceca253704 /drivers/staging/android
parent217218f002a669905701cc0baa18a8d6ba1d5e21 (diff)
downloadlinux-8d438bef6556315a23781fd673f13f7bfb94047d.tar.bz2
Staging: android: ram_console: Use resource_size function
The semantic patch that makes this change is available in scripts/coccinelle/api/resource_size.cocci. More information about semantic patching is available at http://coccinelle.lip6.fr/ Signed-off-by: Thomas Meyer <thomas@m3y3r.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/android')
-rw-r--r--drivers/staging/android/ram_console.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/android/ram_console.c b/drivers/staging/android/ram_console.c
index 0cb3f3c227fc..fabd398ec1bc 100644
--- a/drivers/staging/android/ram_console.c
+++ b/drivers/staging/android/ram_console.c
@@ -351,7 +351,7 @@ static int ram_console_driver_probe(struct platform_device *pdev)
"%lx\n", res, pdev->num_resources, res ? res->flags : 0);
return -ENXIO;
}
- buffer_size = res->end - res->start + 1;
+ buffer_size = resource_size(res);
start = res->start;
printk(KERN_INFO "ram_console: got buffer at %zx, size %zx\n",
start, buffer_size);