Lines Matching refs:lrugen
166 unsigned long max_seq = lruvec->lrugen.max_seq; in lru_gen_is_active()
181 struct lru_gen_folio *lrugen = &lruvec->lrugen; in lru_gen_update_size() local
188 WRITE_ONCE(lrugen->nr_pages[old_gen][type][zone], in lru_gen_update_size()
189 lrugen->nr_pages[old_gen][type][zone] - delta); in lru_gen_update_size()
191 WRITE_ONCE(lrugen->nr_pages[new_gen][type][zone], in lru_gen_update_size()
192 lrugen->nr_pages[new_gen][type][zone] + delta); in lru_gen_update_size()
227 struct lru_gen_folio *lrugen = &lruvec->lrugen; in lru_gen_add_folio() local
231 if (folio_test_unevictable(folio) || !lrugen->enabled) in lru_gen_add_folio()
246 seq = lrugen->max_seq; in lru_gen_add_folio()
250 seq = lrugen->max_seq - 1; in lru_gen_add_folio()
251 else if (reclaiming || lrugen->min_seq[type] + MIN_NR_GENS >= lrugen->max_seq) in lru_gen_add_folio()
252 seq = lrugen->min_seq[type]; in lru_gen_add_folio()
254 seq = lrugen->min_seq[type] + 1; in lru_gen_add_folio()
264 list_add_tail(&folio->lru, &lrugen->folios[gen][type][zone]); in lru_gen_add_folio()
266 list_add(&folio->lru, &lrugen->folios[gen][type][zone]); in lru_gen_add_folio()