Lines Matching refs:mtime
311 unsigned long long mtime = 0; in get_cb_cost() local
319 mtime += get_seg_entry(sbi, start + i)->mtime; in get_cb_cost()
322 mtime = div_u64(mtime, usable_segs_per_sec); in get_cb_cost()
328 if (mtime < sit_i->min_mtime) in get_cb_cost()
329 sit_i->min_mtime = mtime; in get_cb_cost()
330 if (mtime > sit_i->max_mtime) in get_cb_cost()
331 sit_i->max_mtime = mtime; in get_cb_cost()
333 age = 100 - div64_u64(100 * (mtime - sit_i->min_mtime), in get_cb_cost()
368 unsigned long long mtime, unsigned int segno, in attach_victim_entry() argument
378 ve->mtime = mtime; in attach_victim_entry()
392 unsigned long long mtime, unsigned int segno) in insert_victim_entry() argument
399 p = f2fs_lookup_rb_tree_ext(sbi, &am->root, &parent, mtime, &left_most); in insert_victim_entry()
400 attach_victim_entry(sbi, mtime, segno, parent, p, left_most); in insert_victim_entry()
409 unsigned long long mtime = 0; in add_victim_entry() local
419 mtime += get_seg_entry(sbi, start + i)->mtime; in add_victim_entry()
420 mtime = div_u64(mtime, sbi->segs_per_sec); in add_victim_entry()
423 if (mtime < sit_i->min_mtime) in add_victim_entry()
424 sit_i->min_mtime = mtime; in add_victim_entry()
425 if (mtime > sit_i->max_mtime) in add_victim_entry()
426 sit_i->max_mtime = mtime; in add_victim_entry()
427 if (mtime < sit_i->dirty_min_mtime) in add_victim_entry()
428 sit_i->dirty_min_mtime = mtime; in add_victim_entry()
429 if (mtime > sit_i->dirty_max_mtime) in add_victim_entry()
430 sit_i->dirty_max_mtime = mtime; in add_victim_entry()
433 if (sit_i->dirty_max_mtime - mtime < p->age_threshold) in add_victim_entry()
436 insert_victim_entry(sbi, mtime, segno); in add_victim_entry()
491 if (ve->mtime >= max_mtime || ve->mtime < min_mtime) in atgc_lookup_victim()
495 age = div64_u64(accu * (max_mtime - ve->mtime), total_time) * in atgc_lookup_victim()
562 if (ve->mtime >= max_mtime || ve->mtime < min_mtime) in atssr_lookup_victim()
565 age = max_mtime - ve->mtime; in atssr_lookup_victim()