Lines Matching refs:victim
244 int i, victim; in cache_valid_mem() local
245 victim = lga_victim; in cache_valid_mem()
247 if (last_good_addr[victim] == 0) { in cache_valid_mem()
248 last_good_addr[victim] = addr; in cache_valid_mem()
251 victim = (victim + 1) % NLGA; in cache_valid_mem()
255 last_good_addr[victim] = addr; in cache_valid_mem()
256 victim = (victim + 1) % NLGA; in cache_valid_mem()
257 lga_victim = victim; in cache_valid_mem()
280 int i, victim; in cache_valid_mem() local
281 victim = atomic_load(&lga_victim); in cache_valid_mem()
284 if (atomic_compare_exchange_strong(&last_good_addr[victim], &zero, addr)) { in cache_valid_mem()
287 victim = (victim + 1) % NLGA; in cache_valid_mem()
291 atomic_store(&last_good_addr[victim], addr); in cache_valid_mem()
292 victim = (victim + 1) % NLGA; in cache_valid_mem()
293 atomic_store(&lga_victim, victim); in cache_valid_mem()