diff options
Diffstat (limited to 'drivers/mtd/maps/integrator-flash.c')
-rw-r--r-- | drivers/mtd/maps/integrator-flash.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/mtd/maps/integrator-flash.c b/drivers/mtd/maps/integrator-flash.c index c8db01b3e45f..6946d802e6f6 100644 --- a/drivers/mtd/maps/integrator-flash.c +++ b/drivers/mtd/maps/integrator-flash.c | |||
@@ -75,14 +75,12 @@ static int armflash_probe(struct platform_device *dev) | |||
75 | int err; | 75 | int err; |
76 | void __iomem *base; | 76 | void __iomem *base; |
77 | 77 | ||
78 | info = kmalloc(sizeof(struct armflash_info), GFP_KERNEL); | 78 | info = kzalloc(sizeof(struct armflash_info), GFP_KERNEL); |
79 | if (!info) { | 79 | if (!info) { |
80 | err = -ENOMEM; | 80 | err = -ENOMEM; |
81 | goto out; | 81 | goto out; |
82 | } | 82 | } |
83 | 83 | ||
84 | memset(info, 0, sizeof(struct armflash_info)); | ||
85 | |||
86 | info->plat = plat; | 84 | info->plat = plat; |
87 | if (plat && plat->init) { | 85 | if (plat && plat->init) { |
88 | err = plat->init(); | 86 | err = plat->init(); |