Lines Matching defs:ops

130 	const struct tcf_proto_ops *ops;
132 ops = __tcf_proto_lookup_ops(kind);
133 if (ops)
134 return ops;
141 ops = __tcf_proto_lookup_ops(kind);
147 if (ops) {
148 module_put(ops->owner);
158 int register_tcf_proto_ops(struct tcf_proto_ops *ops)
165 if (!strcmp(ops->kind, t->kind))
168 list_add_tail(&ops->head, &tcf_proto_base);
178 int unregister_tcf_proto_ops(struct tcf_proto_ops *ops)
191 if (t == ops) {
231 const struct tcf_proto_ops *ops;
237 ops = tcf_proto_lookup_ops(kind, false, NULL);
241 if (IS_ERR(ops))
244 ret = !!(ops->flags & TCF_PROTO_OPS_DOIT_UNLOCKED);
245 module_put(ops->owner);
261 tp->ops = tcf_proto_lookup_ops(kind, rtnl_held, extack);
262 if (IS_ERR(tp->ops)) {
263 err = PTR_ERR(tp->ops);
266 tp->classify = tp->ops->classify;
273 err = tp->ops->init(tp);
275 module_put(tp->ops->owner);
295 tp->ops->destroy(tp, rtnl_held, extack);
299 module_put(tp->ops->owner);
312 if (tp->ops->delete_empty)
313 return tp->ops->delete_empty(tp);
1067 cops = (*q)->ops->cl_ops;
1109 const struct Qdisc_class_ops *cops = q->ops->cl_ops;
1135 const struct Qdisc_class_ops *cops = q->ops->cl_ops;
1420 if (tp->ops->reoffload) {
1421 err = tp->ops->reoffload(tp, add, cb, cb_priv,
1824 if (nla_put_string(skb, TCA_KIND, tp->ops->kind))
1831 if (tp->ops->terse_dump) {
1832 if (tp->ops->terse_dump(net, tp, fh, skb, tcm,
1839 if (tp->ops->dump &&
1840 tp->ops->dump(net, tp, fh, skb, tcm, rtnl_held) < 0)
1907 err = tp->ops->delete(tp, fh, last, rtnl_held, extack);
1942 if (tp->ops->put && fh)
1943 tp->ops->put(tp, fh);
2021 (q && !(q->ops->cl_ops->flags & QDISC_CLASS_OPS_DOIT_UNLOCKED)) ||
2106 if (tca[TCA_KIND] && nla_strcmp(tca[TCA_KIND], tp->ops->kind)) {
2112 fh = tp->ops->get(tp, t->tcm_handle);
2127 if (chain->tmplt_ops && chain->tmplt_ops != tp->ops) {
2134 err = tp->ops->change(net, skb, tp, cl, t->tcm_handle, tca, &fh,
2231 (q && !(q->ops->cl_ops->flags & QDISC_CLASS_OPS_DOIT_UNLOCKED)) ||
2283 } else if (tca[TCA_KIND] && nla_strcmp(tca[TCA_KIND], tp->ops->kind)) {
2300 fh = tp->ops->get(tp, t->tcm_handle);
2387 if ((q && !(q->ops->cl_ops->flags & QDISC_CLASS_OPS_DOIT_UNLOCKED)) ||
2425 } else if (tca[TCA_KIND] && nla_strcmp(tca[TCA_KIND], tp->ops->kind)) {
2431 fh = tp->ops->get(tp, t->tcm_handle);
2514 if (!tp->ops->walk)
2527 tp->ops->walk(tp, &arg.w, true);
2601 cops = q->ops->cl_ops;
2656 const struct tcf_proto_ops *ops;
2661 ops = tmplt_ops;
2683 if (ops) {
2684 if (nla_put_string(skb, TCA_KIND, ops->kind))
2686 if (ops->tmplt_dump(skb, net, priv) < 0)
2759 const struct tcf_proto_ops *ops;
2772 ops = tcf_proto_lookup_ops(name, true, extack);
2773 if (IS_ERR(ops))
2774 return PTR_ERR(ops);
2775 if (!ops->tmplt_create || !ops->tmplt_destroy || !ops->tmplt_dump) {
2777 module_put(ops->owner);
2781 tmplt_priv = ops->tmplt_create(net, chain, tca, extack);
2783 module_put(ops->owner);
2786 chain->tmplt_ops = ops;
2794 /* If template ops are set, no work to do for us. */
2990 cops = q->ops->cl_ops;
3339 if (tp->ops->hw_add)
3340 tp->ops->hw_add(tp, type_data);
3388 if (tp->ops->hw_del)
3389 tp->ops->hw_del(tp, type_data);
3395 if (tp->ops->hw_add)
3396 tp->ops->hw_add(tp, type_data);
3436 if (tp->ops->hw_del)
3437 tp->ops->hw_del(tp, type_data);
3506 entry->dev = act->ops->get_dev(act, &entry->destructor);
3536 act->ops->get_psample_group(act, &entry->destructor);