Lines Matching refs:entry
176 static int fill_gate_entry(struct nlattr **tb, struct tcfg_gate_entry *entry, in fill_gate_entry() argument
181 entry->gate_state = nla_get_flag(tb[TCA_GATE_ENTRY_GATE]); in fill_gate_entry()
191 entry->interval = interval; in fill_gate_entry()
193 entry->ipv = nla_get_s32_default(tb[TCA_GATE_ENTRY_IPV], -1); in fill_gate_entry()
195 entry->maxoctets = nla_get_s32_default(tb[TCA_GATE_ENTRY_MAX_OCTETS], in fill_gate_entry()
201 static int parse_gate_entry(struct nlattr *n, struct tcfg_gate_entry *entry, in parse_gate_entry() argument
213 entry->index = index; in parse_gate_entry()
215 return fill_gate_entry(tb, entry, extack); in parse_gate_entry()
220 struct tcfg_gate_entry *entry, *e; in release_entry_list() local
222 list_for_each_entry_safe(entry, e, entries, list) { in release_entry_list()
223 list_del(&entry->list); in release_entry_list()
224 kfree(entry); in release_entry_list()
232 struct tcfg_gate_entry *entry; in parse_gate_list() local
246 entry = kzalloc(sizeof(*entry), GFP_ATOMIC); in parse_gate_list()
247 if (!entry) { in parse_gate_list()
253 err = parse_gate_entry(n, entry, i, extack); in parse_gate_list()
255 kfree(entry); in parse_gate_list()
259 list_add_tail(&entry->list, &sched->entries); in parse_gate_list()
399 struct tcfg_gate_entry *entry; in tcf_gate_init() local
402 list_for_each_entry(entry, &p->entries, list) in tcf_gate_init()
403 cycle = ktime_add_ns(cycle, entry->interval); in tcf_gate_init()
467 struct tcfg_gate_entry *entry) in dumping_entry() argument
475 if (nla_put_u32(skb, TCA_GATE_ENTRY_INDEX, entry->index)) in dumping_entry()
478 if (entry->gate_state && nla_put_flag(skb, TCA_GATE_ENTRY_GATE)) in dumping_entry()
481 if (nla_put_u32(skb, TCA_GATE_ENTRY_INTERVAL, entry->interval)) in dumping_entry()
484 if (nla_put_s32(skb, TCA_GATE_ENTRY_MAX_OCTETS, entry->maxoctets)) in dumping_entry()
487 if (nla_put_s32(skb, TCA_GATE_ENTRY_IPV, entry->ipv)) in dumping_entry()
507 struct tcfg_gate_entry *entry; in tcf_gate_dump() local
545 list_for_each_entry(entry, &p->entries, list) { in tcf_gate_dump()
546 if (dumping_entry(skb, entry) < 0) in tcf_gate_dump()
587 static int tcf_gate_get_entries(struct flow_action_entry *entry, in tcf_gate_get_entries() argument
590 entry->gate.entries = tcf_gate_get_list(act); in tcf_gate_get_entries()
592 if (!entry->gate.entries) in tcf_gate_get_entries()
595 entry->destructor = tcf_gate_entry_destructor; in tcf_gate_get_entries()
596 entry->destructor_priv = entry->gate.entries; in tcf_gate_get_entries()
608 struct flow_action_entry *entry = entry_data; in tcf_gate_offload_act_setup() local
610 entry->id = FLOW_ACTION_GATE; in tcf_gate_offload_act_setup()
611 entry->gate.prio = tcf_gate_prio(act); in tcf_gate_offload_act_setup()
612 entry->gate.basetime = tcf_gate_basetime(act); in tcf_gate_offload_act_setup()
613 entry->gate.cycletime = tcf_gate_cycletime(act); in tcf_gate_offload_act_setup()
614 entry->gate.cycletimeext = tcf_gate_cycletimeext(act); in tcf_gate_offload_act_setup()
615 entry->gate.num_entries = tcf_gate_num_entries(act); in tcf_gate_offload_act_setup()
616 err = tcf_gate_get_entries(entry, act); in tcf_gate_offload_act_setup()