Lines Matching full:mtime
310 unsigned long long mtime = 0; in get_cb_cost() local
318 mtime += get_seg_entry(sbi, start + i)->mtime; in get_cb_cost()
321 mtime = div_u64(mtime, usable_segs_per_sec); in get_cb_cost()
327 if (mtime < sit_i->min_mtime) in get_cb_cost()
328 sit_i->min_mtime = mtime; in get_cb_cost()
329 if (mtime > sit_i->max_mtime) in get_cb_cost()
330 sit_i->max_mtime = mtime; in get_cb_cost()
332 age = 100 - div64_u64(100 * (mtime - sit_i->min_mtime), in get_cb_cost()
367 unsigned long long mtime, unsigned int segno, in attach_victim_entry() argument
376 ve->mtime = mtime; in attach_victim_entry()
390 unsigned long long mtime, unsigned int segno) in insert_victim_entry() argument
397 p = f2fs_lookup_rb_tree_ext(sbi, &am->root, &parent, mtime, &left_most); in insert_victim_entry()
398 attach_victim_entry(sbi, mtime, segno, parent, p, left_most); in insert_victim_entry()
407 unsigned long long mtime = 0; in add_victim_entry() local
417 mtime += get_seg_entry(sbi, start + i)->mtime; in add_victim_entry()
418 mtime = div_u64(mtime, sbi->segs_per_sec); in add_victim_entry()
421 if (mtime < sit_i->min_mtime) in add_victim_entry()
422 sit_i->min_mtime = mtime; in add_victim_entry()
423 if (mtime > sit_i->max_mtime) in add_victim_entry()
424 sit_i->max_mtime = mtime; in add_victim_entry()
425 if (mtime < sit_i->dirty_min_mtime) in add_victim_entry()
426 sit_i->dirty_min_mtime = mtime; in add_victim_entry()
427 if (mtime > sit_i->dirty_max_mtime) in add_victim_entry()
428 sit_i->dirty_max_mtime = mtime; in add_victim_entry()
431 if (sit_i->dirty_max_mtime - mtime < p->age_threshold) in add_victim_entry()
434 insert_victim_entry(sbi, mtime, segno); in add_victim_entry()
489 if (ve->mtime >= max_mtime || ve->mtime < min_mtime) in atgc_lookup_victim()
493 age = div64_u64(accu * (max_mtime - ve->mtime), total_time) * in atgc_lookup_victim()
560 if (ve->mtime >= max_mtime || ve->mtime < min_mtime) in atssr_lookup_victim()
563 age = max_mtime - ve->mtime; in atssr_lookup_victim()