Lines Matching refs:mtd
15 #include <linux/mtd/mtd.h>
16 #include <linux/mtd/rawnand.h>
17 #include <linux/mtd/nand.h>
236 static int ebu_nand_ooblayout_ecc(struct mtd_info *mtd, int section,
239 struct nand_chip *chip = mtd_to_nand(mtd);
250 static int ebu_nand_ooblayout_free(struct mtd_info *mtd, int section,
253 struct nand_chip *chip = mtd_to_nand(mtd);
259 oobregion->length = mtd->oobsize - oobregion->offset;
388 struct mtd_info *mtd = nand_to_mtd(chip);
394 ret = ebu_dma_start(ebu_host, DMA_DEV_TO_MEM, buf, mtd->writesize);
411 struct mtd_info *mtd = nand_to_mtd(chip);
419 ret = ebu_dma_start(ebu_host, DMA_MEM_TO_DEV, buf, mtd->writesize);
447 struct mtd_info *mtd = nand_to_mtd(chip);
452 u32 writesize = mtd->writesize;
453 u32 blocksize = mtd->erasesize;
491 if ((ecc_total + 8) > mtd->oobsize)
507 mtd_set_ooblayout(mtd, &ebu_nand_ooblayout_ops);
582 struct mtd_info *mtd;
673 mtd = nand_to_mtd(&ebu_host->chip);
674 if (!mtd->name) {
680 mtd->dev.parent = dev;
695 ret = mtd_device_register(mtd, NULL, 0);