mtd: remove unnecessary casts of void ptr returning alloc function return values
Linux-MTD Mailing List
linux-mtd at lists.infradead.org
Fri Dec 3 11:59:03 EST 2010
Gitweb: http://git.infradead.org/?p=mtd-2.6.git;a=commit;h=ce4a37f7c93e9b12ac1452bedd823d73c43c0e63
Commit: ce4a37f7c93e9b12ac1452bedd823d73c43c0e63
Parent: 65ab220c30bc2120eaa39753cadec68616e3f906
Author: Jesper Juhl <jj at chaosbits.net>
AuthorDate: Tue Nov 9 00:09:02 2010 +0100
Committer: David Woodhouse <David.Woodhouse at intel.com>
CommitDate: Fri Dec 3 16:29:22 2010 +0000
mtd: remove unnecessary casts of void ptr returning alloc function return values
The [vk][cmz]alloc(_node) family of functions return void pointers which
it's completely unnecessary/pointless to cast to other pointer types since
that happens implicitly.
This patch removes such casts from drivers/mtd/
Signed-off-by: Jesper Juhl <jj at chaosbits.net>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy at nokia.com>
Signed-off-by: David Woodhouse <David.Woodhouse at intel.com>
---
drivers/mtd/maps/tqm8xxl.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/mtd/maps/tqm8xxl.c b/drivers/mtd/maps/tqm8xxl.c
index 6014698..c08e140 100644
--- a/drivers/mtd/maps/tqm8xxl.c
+++ b/drivers/mtd/maps/tqm8xxl.c
@@ -139,7 +139,7 @@ static int __init init_tqm_mtd(void)
goto error_mem;
}
- map_banks[idx]->name = (char *)kmalloc(16, GFP_KERNEL);
+ map_banks[idx]->name = kmalloc(16, GFP_KERNEL);
if (!map_banks[idx]->name) {
ret = -ENOMEM;
More information about the linux-mtd-cvs
mailing list