Searched refs:credit (Results 1 – 6 of 6) sorted by relevance
/net/netfilter/ |
D | xt_limit.c | 22 uint32_t credit; member 76 priv->credit += (now - xchg(&priv->prev, now)) * CREDITS_PER_JIFFY; in limit_mt() 77 if (priv->credit > r->credit_cap) in limit_mt() 78 priv->credit = r->credit_cap; in limit_mt() 80 if (priv->credit >= r->cost) { in limit_mt() 82 priv->credit -= r->cost; in limit_mt() 124 priv->credit = user2credits(r->avg * r->burst); /* Credits full. */ in limit_mt_check() 126 r->credit_cap = priv->credit; /* Credits full. */ in limit_mt_check() 145 u_int32_t credit; member 160 .credit = cm->credit, in limit_mt_compat_from_user() [all …]
|
D | xt_hashlimit.c | 89 u_int32_t credit; member 456 u32 tmp = dh->rateinfo.credit; in rateinfo_recalc() 457 dh->rateinfo.credit += CREDITS_PER_JIFFY_BYTES * delta; in rateinfo_recalc() 459 if (tmp >= dh->rateinfo.credit) {/* overflow */ in rateinfo_recalc() 460 dh->rateinfo.credit = cap; in rateinfo_recalc() 464 dh->rateinfo.credit += delta * CREDITS_PER_JIFFY; in rateinfo_recalc() 467 if (dh->rateinfo.credit > cap) in rateinfo_recalc() 468 dh->rateinfo.credit = cap; in rateinfo_recalc() 476 dh->rateinfo.credit = CREDITS_PER_JIFFY_BYTES * HZ; in rateinfo_init() 480 dh->rateinfo.credit = user2credits(hinfo->cfg.avg * in rateinfo_init() [all …]
|
/net/bridge/netfilter/ |
D | ebt_limit.c | 41 info->credit += (now - xchg(&info->prev, now)) * CREDITS_PER_JIFFY; in ebt_limit_mt() 42 if (info->credit > info->credit_cap) in ebt_limit_mt() 43 info->credit = info->credit_cap; in ebt_limit_mt() 45 if (info->credit >= info->cost) { in ebt_limit_mt() 47 info->credit -= info->cost; in ebt_limit_mt() 82 info->credit = user2credits(info->avg * info->burst); in ebt_limit_mt_check() 97 compat_uint_t credit, credit_cap, cost; member
|
/net/sched/ |
D | sch_fq.c | 68 int credit; member 252 f->credit = q->initial_quantum; in fq_classify() 273 f->credit = q->initial_quantum; in fq_classify() 378 f->credit = max_t(u32, f->credit, q->quantum); in fq_enqueue() 441 if (f->credit <= 0) { in fq_dequeue() 442 f->credit += q->quantum; in fq_dequeue() 468 f->credit -= qdisc_pkt_len(skb); in fq_dequeue() 470 if (f->credit > 0 || !q->rate_enable) in fq_dequeue()
|
/net/ipv4/ |
D | icmp.c | 239 u32 credit; member 254 u32 credit, delta, incr = 0, now = (u32)jiffies; in icmp_global_allow() local 260 if (!icmp_global.credit) { in icmp_global_allow() 273 credit = min_t(u32, icmp_global.credit + incr, sysctl_icmp_msgs_burst); in icmp_global_allow() 274 if (credit) { in icmp_global_allow() 275 credit--; in icmp_global_allow() 278 icmp_global.credit = credit; in icmp_global_allow()
|
/net/irda/ |
D | irttp.c | 392 struct tsap_cb *irttp_open_tsap(__u8 stsap_sel, int credit, notify_t *notify) in irttp_open_tsap() argument 461 if (credit > TTP_RX_MAX_CREDIT) in irttp_open_tsap() 464 self->initial_credit = credit; in irttp_open_tsap()
|