Lines Matching refs:mtime
291 unsigned long long mtime = 0; in get_cb_cost() local
299 mtime += get_seg_entry(sbi, start + i)->mtime; in get_cb_cost()
302 mtime = div_u64(mtime, usable_segs_per_sec); in get_cb_cost()
308 if (mtime < sit_i->min_mtime) in get_cb_cost()
309 sit_i->min_mtime = mtime; in get_cb_cost()
310 if (mtime > sit_i->max_mtime) in get_cb_cost()
311 sit_i->max_mtime = mtime; in get_cb_cost()
313 age = 100 - div64_u64(100 * (mtime - sit_i->min_mtime), in get_cb_cost()
348 unsigned long long mtime, unsigned int segno, in attach_victim_entry() argument
357 ve->mtime = mtime; in attach_victim_entry()
371 unsigned long long mtime, unsigned int segno) in insert_victim_entry() argument
378 p = f2fs_lookup_rb_tree_ext(sbi, &am->root, &parent, mtime, &left_most); in insert_victim_entry()
379 attach_victim_entry(sbi, mtime, segno, parent, p, left_most); in insert_victim_entry()
388 unsigned long long mtime = 0; in add_victim_entry() local
402 mtime += get_seg_entry(sbi, start + i)->mtime; in add_victim_entry()
403 mtime = div_u64(mtime, sbi->segs_per_sec); in add_victim_entry()
406 if (mtime < sit_i->min_mtime) in add_victim_entry()
407 sit_i->min_mtime = mtime; in add_victim_entry()
408 if (mtime > sit_i->max_mtime) in add_victim_entry()
409 sit_i->max_mtime = mtime; in add_victim_entry()
410 if (mtime < sit_i->dirty_min_mtime) in add_victim_entry()
411 sit_i->dirty_min_mtime = mtime; in add_victim_entry()
412 if (mtime > sit_i->dirty_max_mtime) in add_victim_entry()
413 sit_i->dirty_max_mtime = mtime; in add_victim_entry()
416 if (sit_i->dirty_max_mtime - mtime < p->age_threshold) in add_victim_entry()
419 insert_victim_entry(sbi, mtime, segno); in add_victim_entry()
474 if (ve->mtime >= max_mtime || ve->mtime < min_mtime) in atgc_lookup_victim()
478 age = div64_u64(accu * (max_mtime - ve->mtime), total_time) * in atgc_lookup_victim()
545 if (ve->mtime >= max_mtime || ve->mtime < min_mtime) in atssr_lookup_victim()
548 age = max_mtime - ve->mtime; in atssr_lookup_victim()