Searched refs:newval (Results 1 – 3 of 3) sorted by relevance
53 static inline u32 tfrc_ewma(const u32 avg, const u32 newval, const u8 weight) in tfrc_ewma() argument55 return avg ? (weight * avg + (10 - weight) * newval) / 10 : newval; in tfrc_ewma()
352 long oldval, newval; in rds_iw_send_grab_credits() local360 oldval = newval = atomic_read(&ic->i_credits); in rds_iw_send_grab_credits()381 newval -= IB_SET_SEND_CREDITS(got); in rds_iw_send_grab_credits()390 newval -= IB_SET_POST_CREDITS(advertise); in rds_iw_send_grab_credits()394 if (atomic_cmpxchg(&ic->i_credits, oldval, newval) != oldval) in rds_iw_send_grab_credits()
400 long oldval, newval; in rds_ib_send_grab_credits() local408 oldval = newval = atomic_read(&ic->i_credits); in rds_ib_send_grab_credits()429 newval -= IB_SET_SEND_CREDITS(got); in rds_ib_send_grab_credits()438 newval -= IB_SET_POST_CREDITS(advertise); in rds_ib_send_grab_credits()442 if (atomic_cmpxchg(&ic->i_credits, oldval, newval) != oldval) in rds_ib_send_grab_credits()