Lines Matching refs:tc
13 * @ingroup tc
19 #include <netlink-private/tc.h>
22 #include <netlink-private/route/tc-api.h>
70 struct rtnl_tc *tc = TC_CAST(act);
79 if (tc->ce_mask & TCA_ATTR_KIND)
80 NLA_PUT_STRING(msg, TCA_ACT_KIND, tc->tc_kind);
82 ops = rtnl_tc_get_ops(tc);
85 void *data = rtnl_tc_data(tc);
91 if ((err = ops->to_msg_fill(tc, data, msg)) < 0)
95 } else if ((err = ops->to_msg_fill_raw(tc, data, msg)) < 0)
172 struct rtnl_tc *tc;
174 tc = TC_CAST(nl_object_alloc(&act_obj_ops));
175 if (tc)
176 tc->tc_type = RTNL_TC_TYPE_ACT;
178 return (struct rtnl_act *) tc;
368 static void act_dump_line(struct rtnl_tc *tc, struct nl_dump_params *p)
400 struct rtnl_tc *tc;
410 tc = TC_CAST(act);
422 rtnl_tc_set_kind(tc, kind);
425 tc->tc_opts = nl_data_alloc_attr(tb2[TCA_ACT_OPTIONS]);
426 if (!tc->tc_opts) {
430 tc->ce_mask |= TCA_ATTR_OPTS;
433 ops = rtnl_tc_get_ops(tc);
435 void *data = rtnl_tc_data(tc);
442 err = ops->to_msg_parser(tc, data);
461 struct rtnl_tc *tc = TC_CAST(*act);
467 tc->ce_msgtype = n->nlmsg_type;
474 tc->tc_family = tm->tca_family;
486 if ((link = rtnl_link_get(link_cache, tc->tc_ifindex))) {
487 rtnl_tc_set_link(tc, link);