diff options
author | Burman Yan <yan_952@hotmail.com> | 2006-11-15 14:10:29 -0500 |
---|---|---|
committer | David Woodhouse <dwmw2@infradead.org> | 2006-11-28 18:47:21 -0500 |
commit | 95b93a0cd46682c6d9e8eea803fda510cb6b863a (patch) | |
tree | 7e430d3fc04ed20791187d144730dd3052292c67 /drivers/mtd/maps/sa1100-flash.c | |
parent | 998a43e72d20afa7566dad66fd866fe939a89c09 (diff) |
[MTD] replace kmalloc+memset with kzalloc
Signed-off-by: Yan Burman <yan_952@hotmail.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Diffstat (limited to 'drivers/mtd/maps/sa1100-flash.c')
-rw-r--r-- | drivers/mtd/maps/sa1100-flash.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/mtd/maps/sa1100-flash.c b/drivers/mtd/maps/sa1100-flash.c index 950bf1c57841..f904e6bd02e0 100644 --- a/drivers/mtd/maps/sa1100-flash.c +++ b/drivers/mtd/maps/sa1100-flash.c | |||
@@ -273,14 +273,12 @@ sa1100_setup_mtd(struct platform_device *pdev, struct flash_platform_data *plat) | |||
273 | /* | 273 | /* |
274 | * Allocate the map_info structs in one go. | 274 | * Allocate the map_info structs in one go. |
275 | */ | 275 | */ |
276 | info = kmalloc(size, GFP_KERNEL); | 276 | info = kzalloc(size, GFP_KERNEL); |
277 | if (!info) { | 277 | if (!info) { |
278 | ret = -ENOMEM; | 278 | ret = -ENOMEM; |
279 | goto out; | 279 | goto out; |
280 | } | 280 | } |
281 | 281 | ||
282 | memset(info, 0, size); | ||
283 | |||
284 | if (plat->init) { | 282 | if (plat->init) { |
285 | ret = plat->init(); | 283 | ret = plat->init(); |
286 | if (ret) | 284 | if (ret) |