zone_num 459 drivers/mtd/sm_ftl.c static int sm_erase_block(struct sm_ftl *ftl, int zone_num, uint16_t block, zone_num 462 drivers/mtd/sm_ftl.c struct ftl_zone *zone = &ftl->zones[zone_num]; zone_num 466 drivers/mtd/sm_ftl.c erase.addr = sm_mkoffset(ftl, zone_num, block, 0); zone_num 474 drivers/mtd/sm_ftl.c if (zone_num == 0 && (block == ftl->cis_block || block == 0)) { zone_num 481 drivers/mtd/sm_ftl.c block, zone_num); zone_num 491 drivers/mtd/sm_ftl.c sm_mark_block_bad(ftl, zone_num, block); zone_num 744 drivers/mtd/sm_ftl.c static int sm_init_zone(struct sm_ftl *ftl, int zone_num) zone_num 746 drivers/mtd/sm_ftl.c struct ftl_zone *zone = &ftl->zones[zone_num]; zone_num 753 drivers/mtd/sm_ftl.c dbg("initializing zone %d", zone_num); zone_num 773 drivers/mtd/sm_ftl.c if (zone_num == 0 && block <= ftl->cis_block) zone_num 777 drivers/mtd/sm_ftl.c if (sm_read_sector(ftl, zone_num, block, 0, NULL, &oob)) { zone_num 822 drivers/mtd/sm_ftl.c lba, zone->lba_to_phys_table[lba], block, zone_num); zone_num 825 drivers/mtd/sm_ftl.c if (sm_check_block(ftl, zone_num, block)) zone_num 829 drivers/mtd/sm_ftl.c if (sm_check_block(ftl, zone_num, zone_num 840 drivers/mtd/sm_ftl.c sm_erase_block(ftl, zone_num, block, 1); zone_num 849 drivers/mtd/sm_ftl.c sm_printk("no free blocks in zone %d", zone_num); zone_num 867 drivers/mtd/sm_ftl.c static struct ftl_zone *sm_get_zone(struct sm_ftl *ftl, int zone_num) zone_num 872 drivers/mtd/sm_ftl.c BUG_ON(zone_num >= ftl->zone_count); zone_num 873 drivers/mtd/sm_ftl.c zone = &ftl->zones[zone_num]; zone_num 876 drivers/mtd/sm_ftl.c error = sm_init_zone(ftl, zone_num); zone_num 923 drivers/mtd/sm_ftl.c int zone_num = ftl->cache_zone; zone_num 932 drivers/mtd/sm_ftl.c BUG_ON(zone_num < 0); zone_num 933 drivers/mtd/sm_ftl.c zone = &ftl->zones[zone_num]; zone_num 942 drivers/mtd/sm_ftl.c zone_num, block_num, sector_num * SM_SECTOR_SIZE, zone_num 963 drivers/mtd/sm_ftl.c if (sm_write_block(ftl, ftl->cache_data, zone_num, write_sector, zone_num 972 drivers/mtd/sm_ftl.c sm_erase_block(ftl, zone_num, block_num, 1); zone_num 1005 drivers/mtd/sm_ftl.c int zone_num, block, boffset; zone_num 1007 drivers/mtd/sm_ftl.c sm_break_offset(ftl, sect_no << 9, &zone_num, &block, &boffset); zone_num 1011 drivers/mtd/sm_ftl.c zone = sm_get_zone(ftl, zone_num); zone_num 1018 drivers/mtd/sm_ftl.c if (ftl->cache_zone == zone_num && ftl->cache_block == block) { zone_num 1032 drivers/mtd/sm_ftl.c if (sm_read_sector(ftl, zone_num, block, boffset, buf, NULL)) { zone_num 1050 drivers/mtd/sm_ftl.c int error = 0, zone_num, block, boffset; zone_num 1053 drivers/mtd/sm_ftl.c sm_break_offset(ftl, sec_no << 9, &zone_num, &block, &boffset); zone_num 1059 drivers/mtd/sm_ftl.c zone = sm_get_zone(ftl, zone_num); zone_num 1066 drivers/mtd/sm_ftl.c if (ftl->cache_block != block || ftl->cache_zone != zone_num) { zone_num 1073 drivers/mtd/sm_ftl.c ftl->cache_zone = zone_num; zone_num 83 drivers/mtd/sm_ftl.h static int sm_erase_block(struct sm_ftl *ftl, int zone_num, uint16_t block, zone_num 85 drivers/mtd/sm_ftl.h static void sm_mark_block_bad(struct sm_ftl *ftl, int zone_num, int block);