mtd: plat-ram: Remove casting the return value which is a void pointer
PATCH 1/1 mtd: plat-ram: Remove casting the return value which is a void pointer
Casting the return value which is a void pointer is redundant. The conversion from void pointer to any other pointer type is guaranteed by the C programming language.
Signed-off-by Jingoo Han <[email protected]>
--- drivers/mtd/maps/plat-ram.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/mtd/maps/plat-ram.c +1 -1
@@ -55,7 +55,7 @@ struct platram_info {static inline struct platram_info *to_platram_info (struct platform_device *dev) { -return (struct platram_info *)platform_get_drvdata (dev); +return platform_get_drvdata (dev); }/* platram_setrw
Signature · 1 line
1.7.10.4
Brian Norris
AppliedQuoted 14 lines · Jingoo Han
Casting the return value which is a void pointer is redundant. The conversion from void pointer to any other pointer type is guaranteed by the C programming language.
Signed-off-by Jingoo Han <[email protected]>--- drivers/mtd/maps/plat-ram.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/mtd/maps/plat-ram.c +0
-0
drivers/mtd/maps/plat-ram.c struct platram_info { · line 61
Quoted 8 lines
drivers/mtd/maps/plat-ram.c +1
-1@@ -55,7 +55,7 @@ struct platram_info {static inline struct platram_info *to_platram_info (struct platform_device *dev) { -return (struct platram_info *)platform_get_drvdata (dev); +return platform_get_drvdata (dev); }/* platram_setrw
Pushed to l2-mtd.git. Thanks!
Brian