Lines Matching full:act
3059 struct tc_action *act; in tcf_exts_validate() local
3068 act = tcf_action_init_1(net, tp, tb[exts->police], in tcf_exts_validate()
3073 if (IS_ERR(act)) in tcf_exts_validate()
3074 return PTR_ERR(act); in tcf_exts_validate()
3076 act->type = exts->type = TCA_OLD_COMPAT; in tcf_exts_validate()
3077 exts->actions[0] = act; in tcf_exts_validate()
3146 struct tc_action *act = tcf_exts_first_act(exts); in tcf_exts_dump() local
3148 if (nest == NULL || !act) in tcf_exts_dump()
3150 if (tcf_action_dump_old(skb, act, 0, 0) < 0) in tcf_exts_dump()
3463 const struct tc_action *act) in tcf_act_get_cookie() argument
3469 cookie = rcu_dereference(act->act_cookie); in tcf_act_get_cookie()
3500 const struct tc_action *act) in tcf_mirred_get_dev() argument
3503 entry->dev = act->ops->get_dev(act, &entry->destructor); in tcf_mirred_get_dev()
3518 const struct tc_action *act) in tcf_tunnel_encap_get_tunnel() argument
3520 entry->tunnel = tcf_tunnel_info_copy(act); in tcf_tunnel_encap_get_tunnel()
3529 const struct tc_action *act) in tcf_sample_get_group() argument
3533 act->ops->get_psample_group(act, &entry->destructor); in tcf_sample_get_group()
3546 const struct tc_action *act) in tcf_gate_get_entries() argument
3548 entry->gate.entries = tcf_gate_get_list(act); in tcf_gate_get_entries()
3572 struct tc_action *act; in tc_setup_flow_action() local
3583 tcf_exts_for_each_action(i, act, exts) { in tc_setup_flow_action()
3587 spin_lock_bh(&act->tcfa_lock); in tc_setup_flow_action()
3588 err = tcf_act_get_cookie(entry, act); in tc_setup_flow_action()
3592 entry->hw_stats = tc_act_hw_stats(act->hw_stats); in tc_setup_flow_action()
3594 if (is_tcf_gact_ok(act)) { in tc_setup_flow_action()
3596 } else if (is_tcf_gact_shot(act)) { in tc_setup_flow_action()
3598 } else if (is_tcf_gact_trap(act)) { in tc_setup_flow_action()
3600 } else if (is_tcf_gact_goto_chain(act)) { in tc_setup_flow_action()
3602 entry->chain_index = tcf_gact_goto_chain_index(act); in tc_setup_flow_action()
3603 } else if (is_tcf_mirred_egress_redirect(act)) { in tc_setup_flow_action()
3605 tcf_mirred_get_dev(entry, act); in tc_setup_flow_action()
3606 } else if (is_tcf_mirred_egress_mirror(act)) { in tc_setup_flow_action()
3608 tcf_mirred_get_dev(entry, act); in tc_setup_flow_action()
3609 } else if (is_tcf_mirred_ingress_redirect(act)) { in tc_setup_flow_action()
3611 tcf_mirred_get_dev(entry, act); in tc_setup_flow_action()
3612 } else if (is_tcf_mirred_ingress_mirror(act)) { in tc_setup_flow_action()
3614 tcf_mirred_get_dev(entry, act); in tc_setup_flow_action()
3615 } else if (is_tcf_vlan(act)) { in tc_setup_flow_action()
3616 switch (tcf_vlan_action(act)) { in tc_setup_flow_action()
3619 entry->vlan.vid = tcf_vlan_push_vid(act); in tc_setup_flow_action()
3620 entry->vlan.proto = tcf_vlan_push_proto(act); in tc_setup_flow_action()
3621 entry->vlan.prio = tcf_vlan_push_prio(act); in tc_setup_flow_action()
3628 entry->vlan.vid = tcf_vlan_push_vid(act); in tc_setup_flow_action()
3629 entry->vlan.proto = tcf_vlan_push_proto(act); in tc_setup_flow_action()
3630 entry->vlan.prio = tcf_vlan_push_prio(act); in tc_setup_flow_action()
3636 } else if (is_tcf_tunnel_set(act)) { in tc_setup_flow_action()
3638 err = tcf_tunnel_encap_get_tunnel(entry, act); in tc_setup_flow_action()
3641 } else if (is_tcf_tunnel_release(act)) { in tc_setup_flow_action()
3643 } else if (is_tcf_pedit(act)) { in tc_setup_flow_action()
3644 for (k = 0; k < tcf_pedit_nkeys(act); k++) { in tc_setup_flow_action()
3645 switch (tcf_pedit_cmd(act, k)) { in tc_setup_flow_action()
3656 entry->mangle.htype = tcf_pedit_htype(act, k); in tc_setup_flow_action()
3657 entry->mangle.mask = tcf_pedit_mask(act, k); in tc_setup_flow_action()
3658 entry->mangle.val = tcf_pedit_val(act, k); in tc_setup_flow_action()
3659 entry->mangle.offset = tcf_pedit_offset(act, k); in tc_setup_flow_action()
3660 entry->hw_stats = tc_act_hw_stats(act->hw_stats); in tc_setup_flow_action()
3663 } else if (is_tcf_csum(act)) { in tc_setup_flow_action()
3665 entry->csum_flags = tcf_csum_update_flags(act); in tc_setup_flow_action()
3666 } else if (is_tcf_skbedit_mark(act)) { in tc_setup_flow_action()
3668 entry->mark = tcf_skbedit_mark(act); in tc_setup_flow_action()
3669 } else if (is_tcf_sample(act)) { in tc_setup_flow_action()
3671 entry->sample.trunc_size = tcf_sample_trunc_size(act); in tc_setup_flow_action()
3672 entry->sample.truncate = tcf_sample_truncate(act); in tc_setup_flow_action()
3673 entry->sample.rate = tcf_sample_rate(act); in tc_setup_flow_action()
3674 tcf_sample_get_group(entry, act); in tc_setup_flow_action()
3675 } else if (is_tcf_police(act)) { in tc_setup_flow_action()
3677 entry->police.burst = tcf_police_burst(act); in tc_setup_flow_action()
3679 tcf_police_rate_bytes_ps(act); in tc_setup_flow_action()
3680 entry->police.mtu = tcf_police_tcfp_mtu(act); in tc_setup_flow_action()
3681 entry->police.index = act->tcfa_index; in tc_setup_flow_action()
3682 } else if (is_tcf_ct(act)) { in tc_setup_flow_action()
3684 entry->ct.action = tcf_ct_action(act); in tc_setup_flow_action()
3685 entry->ct.zone = tcf_ct_zone(act); in tc_setup_flow_action()
3686 entry->ct.flow_table = tcf_ct_ft(act); in tc_setup_flow_action()
3687 } else if (is_tcf_mpls(act)) { in tc_setup_flow_action()
3688 switch (tcf_mpls_action(act)) { in tc_setup_flow_action()
3691 entry->mpls_push.proto = tcf_mpls_proto(act); in tc_setup_flow_action()
3692 entry->mpls_push.label = tcf_mpls_label(act); in tc_setup_flow_action()
3693 entry->mpls_push.tc = tcf_mpls_tc(act); in tc_setup_flow_action()
3694 entry->mpls_push.bos = tcf_mpls_bos(act); in tc_setup_flow_action()
3695 entry->mpls_push.ttl = tcf_mpls_ttl(act); in tc_setup_flow_action()
3699 entry->mpls_pop.proto = tcf_mpls_proto(act); in tc_setup_flow_action()
3703 entry->mpls_mangle.label = tcf_mpls_label(act); in tc_setup_flow_action()
3704 entry->mpls_mangle.tc = tcf_mpls_tc(act); in tc_setup_flow_action()
3705 entry->mpls_mangle.bos = tcf_mpls_bos(act); in tc_setup_flow_action()
3706 entry->mpls_mangle.ttl = tcf_mpls_ttl(act); in tc_setup_flow_action()
3712 } else if (is_tcf_skbedit_ptype(act)) { in tc_setup_flow_action()
3714 entry->ptype = tcf_skbedit_ptype(act); in tc_setup_flow_action()
3715 } else if (is_tcf_skbedit_priority(act)) { in tc_setup_flow_action()
3717 entry->priority = tcf_skbedit_priority(act); in tc_setup_flow_action()
3718 } else if (is_tcf_gate(act)) { in tc_setup_flow_action()
3720 entry->gate.index = tcf_gate_index(act); in tc_setup_flow_action()
3721 entry->gate.prio = tcf_gate_prio(act); in tc_setup_flow_action()
3722 entry->gate.basetime = tcf_gate_basetime(act); in tc_setup_flow_action()
3723 entry->gate.cycletime = tcf_gate_cycletime(act); in tc_setup_flow_action()
3724 entry->gate.cycletimeext = tcf_gate_cycletimeext(act); in tc_setup_flow_action()
3725 entry->gate.num_entries = tcf_gate_num_entries(act); in tc_setup_flow_action()
3726 err = tcf_gate_get_entries(entry, act); in tc_setup_flow_action()
3733 spin_unlock_bh(&act->tcfa_lock); in tc_setup_flow_action()
3735 if (!is_tcf_pedit(act)) in tc_setup_flow_action()
3745 spin_unlock_bh(&act->tcfa_lock); in tc_setup_flow_action()
3753 struct tc_action *act; in tcf_exts_num_actions() local
3756 tcf_exts_for_each_action(i, act, exts) { in tcf_exts_num_actions()
3757 if (is_tcf_pedit(act)) in tcf_exts_num_actions()
3758 num_acts += tcf_pedit_nkeys(act); in tcf_exts_num_actions()