Lines Matching defs:victim
394 u_int uc_nextvictim; /* points to next victim in fifo list */
471 static const char cache_set_err1[] = "victim not found";
472 static const char cache_set_err2[] = "victim alloc failed";
478 cache_ptr victim;
499 victim = uc->uc_fifo[uc->uc_nextvictim];
500 if (victim != NULL) {
501 loc = CACHE_LOC(xprt, victim->cache_xid);
503 *vicp != NULL && *vicp != victim;
511 *vicp = victim->cache_next; /* remove from cache */
512 newbuf = victim->cache_reply;
514 victim = ALLOC(struct cache_node, 1);
515 if (victim == NULL) {
523 FREE(victim, struct cache_node, 1);
543 victim->cache_replylen = replylen;
544 victim->cache_reply = rpc_buffer(xprt);
549 victim->cache_xid = su->su_xid;
550 victim->cache_proc = uc->uc_proc;
551 victim->cache_vers = uc->uc_vers;
552 victim->cache_prog = uc->uc_prog;
553 victim->cache_addr = xprt->xp_rtaddr;
554 victim->cache_addr.buf = ALLOC(char, xprt->xp_rtaddr.len);
555 (void) memcpy(victim->cache_addr.buf, xprt->xp_rtaddr.buf,
557 loc = CACHE_LOC(xprt, victim->cache_xid);
558 victim->cache_next = uc->uc_entries[loc];
559 uc->uc_entries[loc] = victim;
560 uc->uc_fifo[uc->uc_nextvictim++] = victim;