Lines Matching defs:tcm
2057 struct tcmsg *tcm;
2062 nlh = nlmsg_put(skb, portid, seq, event, sizeof(*tcm), flags);
2065 tcm = nlmsg_data(nlh);
2066 tcm->tcm_family = AF_UNSPEC;
2067 tcm->tcm__pad1 = 0;
2068 tcm->tcm__pad2 = 0;
2070 tcm->tcm_ifindex = qdisc_dev(q)->ifindex;
2071 tcm->tcm_parent = parent;
2073 tcm->tcm_ifindex = TCM_IFINDEX_MAGIC_BLOCK;
2074 tcm->tcm_block_index = block->index;
2076 tcm->tcm_info = TC_H_MAKE(tp->prio, tp->protocol);
2082 tcm->tcm_handle = 0;
2085 if (tp->ops->terse_dump(net, tp, fh, skb, tcm,
2093 tp->ops->dump(net, tp, fh, skb, tcm, rtnl_held) < 0)
2776 struct tcmsg *tcm = nlmsg_data(cb->nlh);
2788 if (TC_H_MAJ(tcm->tcm_info) &&
2789 TC_H_MAJ(tcm->tcm_info) != tp->prio)
2791 if (TC_H_MIN(tcm->tcm_info) &&
2792 TC_H_MIN(tcm->tcm_info) != tp->protocol)
2844 struct tcmsg *tcm = nlmsg_data(cb->nlh);
2851 if (nlmsg_len(cb->nlh) < sizeof(*tcm))
2854 err = nlmsg_parse_deprecated(cb->nlh, sizeof(*tcm), tca, TCA_MAX,
2866 if (tcm->tcm_ifindex == TCM_IFINDEX_MAGIC_BLOCK) {
2867 block = tcf_block_refcnt_get(net, tcm->tcm_block_index);
2882 dev = __dev_get_by_index(net, tcm->tcm_ifindex);
2886 parent = tcm->tcm_parent;
2890 q = qdisc_lookup(dev, TC_H_MAJ(tcm->tcm_parent));
2898 if (TC_H_MIN(tcm->tcm_parent)) {
2899 cl = cops->find(q, tcm->tcm_parent);
2930 if (tcm->tcm_ifindex == TCM_IFINDEX_MAGIC_BLOCK)
2951 struct tcmsg *tcm;
2957 nlh = nlmsg_put(skb, portid, seq, event, sizeof(*tcm), flags);
2960 tcm = nlmsg_data(nlh);
2961 tcm->tcm_family = AF_UNSPEC;
2962 tcm->tcm__pad1 = 0;
2963 tcm->tcm__pad2 = 0;
2964 tcm->tcm_handle = 0;
2966 tcm->tcm_ifindex = qdisc_dev(block->q)->ifindex;
2967 tcm->tcm_parent = block->q->handle;
2969 tcm->tcm_ifindex = TCM_IFINDEX_MAGIC_BLOCK;
2970 tcm->tcm_block_index = block->index;
3243 struct tcmsg *tcm = nlmsg_data(cb->nlh);
3249 if (nlmsg_len(cb->nlh) < sizeof(*tcm))
3252 err = nlmsg_parse_deprecated(cb->nlh, sizeof(*tcm), tca, TCA_MAX,
3257 if (tcm->tcm_ifindex == TCM_IFINDEX_MAGIC_BLOCK) {
3258 block = tcf_block_refcnt_get(net, tcm->tcm_block_index);
3266 dev = __dev_get_by_index(net, tcm->tcm_ifindex);
3270 if (!tcm->tcm_parent)
3273 q = qdisc_lookup(dev, TC_H_MAJ(tcm->tcm_parent));
3282 if (TC_H_MIN(tcm->tcm_parent)) {
3283 cl = cops->find(q, tcm->tcm_parent);
3319 if (tcm->tcm_ifindex == TCM_IFINDEX_MAGIC_BLOCK)