Lines Matching refs:sector_size

62 static inline uint32_t EMPTY_SCAN_SIZE(uint32_t sector_size) {  in EMPTY_SCAN_SIZE()  argument
63 if (sector_size < DEFAULT_EMPTY_SCAN_SIZE) in EMPTY_SCAN_SIZE()
64 return sector_size; in EMPTY_SCAN_SIZE()
117 try_size = c->sector_size; in jffs2_scan_medium()
232 c->bad_size += c->sector_size; in jffs2_scan_medium()
233 c->free_size -= c->sector_size; in jffs2_scan_medium()
315 else if (!ISDIRTY(c->sector_size - (jeb->used_size + jeb->unchecked_size))) { in jffs2_scan_classify_jeb()
490 sm = (void *)buf + c->sector_size - sizeof(*sm); in jffs2_scan_eraseblock()
493 sumlen = c->sector_size - je32_to_cpu(sm->offset); in jffs2_scan_eraseblock()
504 jeb->offset + c->sector_size - buf_len, in jffs2_scan_eraseblock()
511 sumlen = c->sector_size - je32_to_cpu(sm->offset); in jffs2_scan_eraseblock()
515 if (sumlen > c->sector_size) in jffs2_scan_eraseblock()
529 jeb->offset + c->sector_size - sumlen, in jffs2_scan_eraseblock()
560 buf_len = c->sector_size; in jffs2_scan_eraseblock()
562 buf_len = EMPTY_SCAN_SIZE(c->sector_size); in jffs2_scan_eraseblock()
570 max_ofs = EMPTY_SCAN_SIZE(c->sector_size); in jffs2_scan_eraseblock()
613 while(ofs < jeb->offset + c->sector_size) { in jffs2_scan_eraseblock()
639 if (jeb->offset + c->sector_size < ofs + sizeof(*node)) { in jffs2_scan_eraseblock()
642 jeb->offset, c->sector_size, ofs, in jffs2_scan_eraseblock()
644 if ((err = jffs2_scan_dirty_space(c, jeb, (jeb->offset + c->sector_size)-ofs))) in jffs2_scan_eraseblock()
650 buf_len = min_t(uint32_t, buf_size, jeb->offset + c->sector_size - ofs); in jffs2_scan_eraseblock()
668 scan_end = min_t(uint32_t, EMPTY_SCAN_SIZE(c->sector_size)/8, buf_len); in jffs2_scan_eraseblock()
694 EMPTY_SCAN_SIZE(c->sector_size)); in jffs2_scan_eraseblock()
703 buf_len = min_t(uint32_t, buf_size, jeb->offset + c->sector_size - ofs); in jffs2_scan_eraseblock()
776 if (ofs + je32_to_cpu(node->totlen) > jeb->offset + c->sector_size) { in jffs2_scan_eraseblock()
800 buf_len = min_t(uint32_t, buf_size, jeb->offset + c->sector_size - ofs); in jffs2_scan_eraseblock()
817 buf_len = min_t(uint32_t, buf_size, jeb->offset + c->sector_size - ofs); in jffs2_scan_eraseblock()
835 buf_len = min_t(uint32_t, buf_size, jeb->offset + c->sector_size - ofs); in jffs2_scan_eraseblock()
852 buf_len = min_t(uint32_t, buf_size, jeb->offset + c->sector_size - ofs); in jffs2_scan_eraseblock()