Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'for-linus-20120706' of git://git.infradead.org/linux-mtd

Pull two MTD fixes from David Woodhouse:
- Fix a logic error in OLPC CAFÉ NAND ready() function.
- Fix regression due to bitflip handling changes.

* tag 'for-linus-20120706' of git://git.infradead.org/linux-mtd:
mtd: cafe_nand: fix an & vs | mistake
mtd: nand: initialize bitflip_threshold prior to BBT scanning

+8 -1
+1 -1
drivers/mtd/nand/cafe_nand.c
··· 102 102 static int cafe_device_ready(struct mtd_info *mtd) 103 103 { 104 104 struct cafe_priv *cafe = mtd->priv; 105 - int result = !!(cafe_readl(cafe, NAND_STATUS) | 0x40000000); 105 + int result = !!(cafe_readl(cafe, NAND_STATUS) & 0x40000000); 106 106 uint32_t irqs = cafe_readl(cafe, NAND_IRQ); 107 107 108 108 cafe_writel(cafe, irqs, NAND_IRQ);
+7
drivers/mtd/nand/nand_base.c
··· 3501 3501 /* propagate ecc info to mtd_info */ 3502 3502 mtd->ecclayout = chip->ecc.layout; 3503 3503 mtd->ecc_strength = chip->ecc.strength; 3504 + /* 3505 + * Initialize bitflip_threshold to its default prior scan_bbt() call. 3506 + * scan_bbt() might invoke mtd_read(), thus bitflip_threshold must be 3507 + * properly set. 3508 + */ 3509 + if (!mtd->bitflip_threshold) 3510 + mtd->bitflip_threshold = mtd->ecc_strength; 3504 3511 3505 3512 /* Check, if we should skip the bad block table scan */ 3506 3513 if (chip->options & NAND_SKIP_BBTSCAN)