Lines Matching full:mtd
2 /* MTD-based superblock management
11 #include <linux/mtd/super.h>
23 * - they are if the underlying MTD device is the same
27 struct mtd_info *mtd = fc->sget_key; in mtd_test_super() local
31 mtd->index, mtd->name); in mtd_test_super()
36 sb->s_mtd->index, sb->s_mtd->name, mtd->index, mtd->name); in mtd_test_super()
41 * mark the superblock by the MTD device it is using
42 * - set the device number to be the correct MTD block device for pesuperstence
54 * get a superblock on an MTD-backed filesystem
57 struct mtd_info *mtd, in mtd_get_sb() argument
64 fc->sget_key = mtd; in mtd_get_sb()
72 mtd->index, mtd->name); in mtd_get_sb()
73 put_mtd_device(mtd); in mtd_get_sb()
77 mtd->index, mtd->name); in mtd_get_sb()
96 * get a superblock on an MTD-backed filesystem by MTD device number
102 struct mtd_info *mtd; in mtd_get_sb_by_nr() local
104 mtd = get_mtd_device(NULL, mtdnr); in mtd_get_sb_by_nr()
105 if (IS_ERR(mtd)) { in mtd_get_sb_by_nr()
107 return PTR_ERR(mtd); in mtd_get_sb_by_nr()
110 return mtd_get_sb(fc, mtd, fill_super); in mtd_get_sb_by_nr()
114 * get_tree_mtd - Get a superblock based on a single MTD device
134 * CONFIG_BLOCK=n - we specify the underlying MTD device by number or in get_tree_mtd()
142 struct mtd_info *mtd; in get_tree_mtd() local
144 /* mount by MTD device name */ in get_tree_mtd()
145 pr_debug("MTDSB: mtd:%%s, name \"%s\"\n", in get_tree_mtd()
148 mtd = get_mtd_device_nm(fc->source + 4); in get_tree_mtd()
149 if (!IS_ERR(mtd)) in get_tree_mtd()
150 return mtd_get_sb(fc, mtd, fill_super); in get_tree_mtd()
152 errorf(fc, "MTD: MTD device with name \"%s\" not found", in get_tree_mtd()
156 /* mount by MTD device number name */ in get_tree_mtd()
162 pr_debug("MTDSB: mtd%%d, mtdnr %d\n", mtdnr); in get_tree_mtd()
175 errorf(fc, "MTD: Couldn't look up '%s': %d", fc->source, ret); in get_tree_mtd()
190 errorf(fc, "MTD: Attempt to mount non-MTD device \"%s\"", in get_tree_mtd()
197 * destroy an MTD-based superblock