aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd/devices/block2mtd.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@woody.linux-foundation.org>2007-01-22 22:32:13 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-01-22 22:32:13 -0500
commitebcccd14b73831fa7fbc197e1d2b9c710a65731e (patch)
tree88af3e74135bdb3d0af7bc9ef48de0c2f879fcbb /drivers/mtd/devices/block2mtd.c
parente00154891137e3b0659556b877d45a16cabd700c (diff)
parent9cdf083f981b8d37b3212400a359368661385099 (diff)
Merge git://git.infradead.org/mtd-2.6
* git://git.infradead.org/mtd-2.6: (84 commits) [JFFS2] debug.h: include <linux/sched.h> for current->pid [MTD] OneNAND: Handle DDP chip boundary during read-while-load [MTD] OneNAND: return ecc error code only when 2-bit ecc occurs [MTD] OneNAND: Implement read-while-load [MTD] OneNAND: fix onenand_wait bug in read ecc error [MTD] OneNAND: release CPU in cycles [MTD] OneNAND: add subpage write support [MTD] OneNAND: fix onenand_wait bug [JFFS2] use the ref_offset macro [JFFS2] Reschedule in loops [JFFS2] Fix error-path leak in summary scan [JFFS2] add cond_resched() when garbage collecting deletion dirent [MTD] Nuke IVR leftovers [MTD] OneNAND: fix oob handling in recent oob patch [MTD] Fix ssfdc blksize typo [JFFS2] replace kmalloc+memset with kzalloc [MTD] Fix SSFDC build for variable blocksize. [MTD] ESB2ROM uses PCI [MTD] of_device-based physmap driver [MTD] Support combined RedBoot FIS directory and configuration area ...
Diffstat (limited to 'drivers/mtd/devices/block2mtd.c')
-rw-r--r--drivers/mtd/devices/block2mtd.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/mtd/devices/block2mtd.c b/drivers/mtd/devices/block2mtd.c
index 401c6a294baa..6d917a4daa9d 100644
--- a/drivers/mtd/devices/block2mtd.c
+++ b/drivers/mtd/devices/block2mtd.c
@@ -295,10 +295,9 @@ static struct block2mtd_dev *add_device(char *devname, int erase_size)
295 if (!devname) 295 if (!devname)
296 return NULL; 296 return NULL;
297 297
298 dev = kmalloc(sizeof(struct block2mtd_dev), GFP_KERNEL); 298 dev = kzalloc(sizeof(struct block2mtd_dev), GFP_KERNEL);
299 if (!dev) 299 if (!dev)
300 return NULL; 300 return NULL;
301 memset(dev, 0, sizeof(*dev));
302 301
303 /* Get a handle on the device */ 302 /* Get a handle on the device */
304 bdev = open_bdev_excl(devname, O_RDWR, NULL); 303 bdev = open_bdev_excl(devname, O_RDWR, NULL);