]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/mtd/mtdblock.c
[MTD] generic: propagate oobavail to MTD partitions
[linux-2.6-omap-h63xx.git] / drivers / mtd / mtdblock.c
index 2cef280e388c76aaf455fe49f3232596f8d40308..8e50170137e003f3ff35504dc0634646d36bcb52 100644 (file)
@@ -288,8 +288,7 @@ static int mtdblock_open(struct mtd_blktrans_dev *mbd)
 
        mutex_init(&mtdblk->cache_mutex);
        mtdblk->cache_state = STATE_EMPTY;
-       if ((mtdblk->mtd->flags & MTD_CAP_RAM) != MTD_CAP_RAM &&
-           mtdblk->mtd->erasesize) {
+       if (mtdblk->mtd->type != MTD_RAM && mtdblk->mtd->erasesize) {
                mtdblk->cache_size = mtdblk->mtd->erasesize;
                mtdblk->cache_data = NULL;
        }