Lines Matching refs:mtdswap_dev

100 struct mtdswap_dev {  struct
165 #define MTDSWAP_MBD_TO_MTDSWAP(dev) ((struct mtdswap_dev *)dev->priv)
182 static int mtdswap_gc(struct mtdswap_dev *d, unsigned int background);
184 static loff_t mtdswap_eb_offset(struct mtdswap_dev *d, struct swap_eb *eb) in mtdswap_eb_offset()
189 static void mtdswap_eb_detach(struct mtdswap_dev *d, struct swap_eb *eb) in mtdswap_eb_detach()
222 static void mtdswap_rb_add(struct mtdswap_dev *d, struct swap_eb *eb, int idx) in mtdswap_rb_add()
251 static int mtdswap_handle_badblock(struct mtdswap_dev *d, struct swap_eb *eb) in mtdswap_handle_badblock()
279 static int mtdswap_handle_write_error(struct mtdswap_dev *d, struct swap_eb *eb) in mtdswap_handle_write_error()
297 static int mtdswap_read_oob(struct mtdswap_dev *d, loff_t from, in mtdswap_read_oob()
321 static int mtdswap_read_markers(struct mtdswap_dev *d, struct swap_eb *eb) in mtdswap_read_markers()
367 static int mtdswap_write_marker(struct mtdswap_dev *d, struct swap_eb *eb, in mtdswap_write_marker()
416 static void mtdswap_check_counts(struct mtdswap_dev *d) in mtdswap_check_counts()
455 static void mtdswap_scan_eblks(struct mtdswap_dev *d) in mtdswap_scan_eblks()
504 static void mtdswap_store_eb(struct mtdswap_dev *d, struct swap_eb *eb) in mtdswap_store_eb()
526 static int mtdswap_erase_block(struct mtdswap_dev *d, struct swap_eb *eb) in mtdswap_erase_block()
562 static int mtdswap_map_free_block(struct mtdswap_dev *d, unsigned int page, in mtdswap_map_free_block()
603 static unsigned int mtdswap_free_page_cnt(struct mtdswap_dev *d) in mtdswap_free_page_cnt()
609 static unsigned int mtdswap_enough_free_pages(struct mtdswap_dev *d) in mtdswap_enough_free_pages()
614 static int mtdswap_write_block(struct mtdswap_dev *d, char *buf, in mtdswap_write_block()
675 static int mtdswap_move_block(struct mtdswap_dev *d, unsigned int oldblock, in mtdswap_move_block()
732 static int mtdswap_gc_eblock(struct mtdswap_dev *d, struct swap_eb *eb) in mtdswap_gc_eblock()
756 static int __mtdswap_choose_gc_tree(struct mtdswap_dev *d) in __mtdswap_choose_gc_tree()
800 static int mtdswap_choose_wl_tree(struct mtdswap_dev *d) in mtdswap_choose_wl_tree()
828 static int mtdswap_choose_gc_tree(struct mtdswap_dev *d, in mtdswap_choose_gc_tree()
844 static struct swap_eb *mtdswap_pick_gc_eblk(struct mtdswap_dev *d, in mtdswap_pick_gc_eblk()
873 static unsigned int mtdswap_eblk_passes(struct mtdswap_dev *d, in mtdswap_eblk_passes()
937 static int mtdswap_gc(struct mtdswap_dev *d, unsigned int background) in mtdswap_gc()
977 struct mtdswap_dev *d = MTDSWAP_MBD_TO_MTDSWAP(dev); in mtdswap_background()
987 static void mtdswap_cleanup(struct mtdswap_dev *d) in mtdswap_cleanup()
998 struct mtdswap_dev *d = MTDSWAP_MBD_TO_MTDSWAP(dev); in mtdswap_flush()
1022 struct mtdswap_dev *d = MTDSWAP_MBD_TO_MTDSWAP(dev); in mtdswap_writesect()
1061 static int mtdswap_auto_header(struct mtdswap_dev *d, char *buf) in mtdswap_auto_header()
1079 struct mtdswap_dev *d = MTDSWAP_MBD_TO_MTDSWAP(dev); in mtdswap_readsect()
1143 struct mtdswap_dev *d = MTDSWAP_MBD_TO_MTDSWAP(dev); in mtdswap_discard()
1170 struct mtdswap_dev *d = (struct mtdswap_dev *) s->private; in mtdswap_show()
1255 static int mtdswap_add_debugfs(struct mtdswap_dev *d) in mtdswap_add_debugfs()
1270 static int mtdswap_init(struct mtdswap_dev *d, unsigned int eblocks, in mtdswap_init()
1334 struct mtdswap_dev *d; in mtdswap_add_mtd()
1416 d = kzalloc(sizeof(struct mtdswap_dev), GFP_KERNEL); in mtdswap_add_mtd()
1464 struct mtdswap_dev *d = MTDSWAP_MBD_TO_MTDSWAP(dev); in mtdswap_remove_dev()