diff options
Diffstat (limited to 'drivers/mtd/onenand')
-rw-r--r-- | drivers/mtd/onenand/onenand_bbt.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/mtd/onenand/onenand_bbt.c b/drivers/mtd/onenand/onenand_bbt.c index fc2c16a0fd1..09a7d1fb511 100644 --- a/drivers/mtd/onenand/onenand_bbt.c +++ b/drivers/mtd/onenand/onenand_bbt.c | |||
@@ -188,10 +188,8 @@ int onenand_scan_bbt(struct mtd_info *mtd, struct nand_bbt_descr *bd) | |||
188 | len = this->chipsize >> (this->erase_shift + 2); | 188 | len = this->chipsize >> (this->erase_shift + 2); |
189 | /* Allocate memory (2bit per block) and clear the memory bad block table */ | 189 | /* Allocate memory (2bit per block) and clear the memory bad block table */ |
190 | bbm->bbt = kzalloc(len, GFP_KERNEL); | 190 | bbm->bbt = kzalloc(len, GFP_KERNEL); |
191 | if (!bbm->bbt) { | 191 | if (!bbm->bbt) |
192 | printk(KERN_ERR "onenand_scan_bbt: Out of memory\n"); | ||
193 | return -ENOMEM; | 192 | return -ENOMEM; |
194 | } | ||
195 | 193 | ||
196 | /* Set the bad block position */ | 194 | /* Set the bad block position */ |
197 | bbm->badblockpos = ONENAND_BADBLOCK_POS; | 195 | bbm->badblockpos = ONENAND_BADBLOCK_POS; |