Lines Matching refs:s_rule

2483 		 struct ice_sw_rule_lkup_rx_tx *s_rule,  in ice_fill_sw_rule()  argument
2496 s_rule->act = 0; in ice_fill_sw_rule()
2497 s_rule->index = cpu_to_le16(f_info->fltr_rule_id); in ice_fill_sw_rule()
2498 s_rule->hdr_len = 0; in ice_fill_sw_rule()
2503 eth_hdr = s_rule->hdr_data; in ice_fill_sw_rule()
2588 s_rule->hdr.type = (f_info->flag & ICE_FLTR_RX) ? in ice_fill_sw_rule()
2593 s_rule->recipe_id = cpu_to_le16(f_info->lkup_type); in ice_fill_sw_rule()
2594 s_rule->src = cpu_to_le16(f_info->src); in ice_fill_sw_rule()
2595 s_rule->act = cpu_to_le32(act); in ice_fill_sw_rule()
2609 s_rule->hdr_len = cpu_to_le16(eth_hdr_sz); in ice_fill_sw_rule()
2764 struct ice_sw_rule_vsi_list *s_rule; in ice_update_vsi_list_rule() local
2789 s_rule_size = (u16)ICE_SW_RULE_VSI_LIST_SIZE(s_rule, num_vsi); in ice_update_vsi_list_rule()
2790 s_rule = devm_kzalloc(ice_hw_to_dev(hw), s_rule_size, GFP_KERNEL); in ice_update_vsi_list_rule()
2791 if (!s_rule) in ice_update_vsi_list_rule()
2799 s_rule->vsi[i] = in ice_update_vsi_list_rule()
2803 s_rule->hdr.type = cpu_to_le16(rule_type); in ice_update_vsi_list_rule()
2804 s_rule->number_vsi = cpu_to_le16(num_vsi); in ice_update_vsi_list_rule()
2805 s_rule->index = cpu_to_le16(vsi_list_id); in ice_update_vsi_list_rule()
2807 status = ice_aq_sw_rules(hw, s_rule, s_rule_size, 1, opc, NULL); in ice_update_vsi_list_rule()
2810 devm_kfree(ice_hw_to_dev(hw), s_rule); in ice_update_vsi_list_rule()
2853 struct ice_sw_rule_lkup_rx_tx *s_rule; in ice_create_pkt_fwd_rule() local
2858 s_rule = devm_kzalloc(ice_hw_to_dev(hw), in ice_create_pkt_fwd_rule()
2859 ICE_SW_RULE_RX_TX_ETH_HDR_SIZE(s_rule), in ice_create_pkt_fwd_rule()
2861 if (!s_rule) in ice_create_pkt_fwd_rule()
2878 ice_fill_sw_rule(hw, &fm_entry->fltr_info, s_rule, in ice_create_pkt_fwd_rule()
2881 status = ice_aq_sw_rules(hw, s_rule, in ice_create_pkt_fwd_rule()
2882 ICE_SW_RULE_RX_TX_ETH_HDR_SIZE(s_rule), 1, in ice_create_pkt_fwd_rule()
2889 f_entry->fltr_info.fltr_rule_id = le16_to_cpu(s_rule->index); in ice_create_pkt_fwd_rule()
2890 fm_entry->fltr_info.fltr_rule_id = le16_to_cpu(s_rule->index); in ice_create_pkt_fwd_rule()
2900 devm_kfree(ice_hw_to_dev(hw), s_rule); in ice_create_pkt_fwd_rule()
2915 struct ice_sw_rule_lkup_rx_tx *s_rule; in ice_update_pkt_fwd_rule() local
2918 s_rule = devm_kzalloc(ice_hw_to_dev(hw), in ice_update_pkt_fwd_rule()
2919 ICE_SW_RULE_RX_TX_ETH_HDR_SIZE(s_rule), in ice_update_pkt_fwd_rule()
2921 if (!s_rule) in ice_update_pkt_fwd_rule()
2924 ice_fill_sw_rule(hw, f_info, s_rule, ice_aqc_opc_update_sw_rules); in ice_update_pkt_fwd_rule()
2926 s_rule->index = cpu_to_le16(f_info->fltr_rule_id); in ice_update_pkt_fwd_rule()
2929 status = ice_aq_sw_rules(hw, s_rule, in ice_update_pkt_fwd_rule()
2930 ICE_SW_RULE_RX_TX_ETH_HDR_SIZE(s_rule), 1, in ice_update_pkt_fwd_rule()
2933 devm_kfree(ice_hw_to_dev(hw), s_rule); in ice_update_pkt_fwd_rule()
3214 struct ice_sw_rule_vsi_list *s_rule; in ice_remove_vsi_list_rule() local
3218 s_rule_size = (u16)ICE_SW_RULE_VSI_LIST_SIZE(s_rule, 0); in ice_remove_vsi_list_rule()
3219 s_rule = devm_kzalloc(ice_hw_to_dev(hw), s_rule_size, GFP_KERNEL); in ice_remove_vsi_list_rule()
3220 if (!s_rule) in ice_remove_vsi_list_rule()
3223 s_rule->hdr.type = cpu_to_le16(ICE_AQC_SW_RULES_T_VSI_LIST_CLEAR); in ice_remove_vsi_list_rule()
3224 s_rule->index = cpu_to_le16(vsi_list_id); in ice_remove_vsi_list_rule()
3232 devm_kfree(ice_hw_to_dev(hw), s_rule); in ice_remove_vsi_list_rule()
3384 struct ice_sw_rule_lkup_rx_tx *s_rule; in ice_remove_rule_internal() local
3386 s_rule = devm_kzalloc(ice_hw_to_dev(hw), in ice_remove_rule_internal()
3387 ICE_SW_RULE_RX_TX_NO_HDR_SIZE(s_rule), in ice_remove_rule_internal()
3389 if (!s_rule) { in ice_remove_rule_internal()
3394 ice_fill_sw_rule(hw, &list_elem->fltr_info, s_rule, in ice_remove_rule_internal()
3397 status = ice_aq_sw_rules(hw, s_rule, in ice_remove_rule_internal()
3398 ICE_SW_RULE_RX_TX_NO_HDR_SIZE(s_rule), in ice_remove_rule_internal()
3402 devm_kfree(ice_hw_to_dev(hw), s_rule); in ice_remove_rule_internal()
5659 struct ice_sw_rule_lkup_rx_tx *s_rule, in ice_fill_adv_dummy_packet() argument
5668 pkt = s_rule->hdr_data; in ice_fill_adv_dummy_packet()
5770 s_rule->hdr_len = cpu_to_le16(profile->pkt_len); in ice_fill_adv_dummy_packet()
6065 struct ice_sw_rule_lkup_rx_tx *s_rule = NULL; in ice_add_adv_rule() local
6153 rule_buf_sz = ICE_SW_RULE_RX_TX_HDR_SIZE(s_rule, profile->pkt_len); in ice_add_adv_rule()
6154 s_rule = kzalloc(rule_buf_sz, GFP_KERNEL); in ice_add_adv_rule()
6155 if (!s_rule) { in ice_add_adv_rule()
6210 s_rule->hdr.type = cpu_to_le16(ICE_AQC_SW_RULES_T_LKUP_TX); in ice_add_adv_rule()
6211 s_rule->src = cpu_to_le16(rinfo->sw_act.src); in ice_add_adv_rule()
6213 s_rule->hdr.type = cpu_to_le16(ICE_AQC_SW_RULES_T_LKUP_RX); in ice_add_adv_rule()
6214 s_rule->src = cpu_to_le16(hw->port_info->lport); in ice_add_adv_rule()
6217 s_rule->recipe_id = cpu_to_le16(rid); in ice_add_adv_rule()
6218 s_rule->act = cpu_to_le32(act); in ice_add_adv_rule()
6220 status = ice_fill_adv_dummy_packet(lkups, lkups_cnt, s_rule, profile); in ice_add_adv_rule()
6224 status = ice_fill_adv_packet_tun(hw, rinfo->tun_type, s_rule->hdr_data, in ice_add_adv_rule()
6230 s_rule->hdr_data, in ice_add_adv_rule()
6235 status = ice_aq_sw_rules(hw, (struct ice_aqc_sw_rules *)s_rule, in ice_add_adv_rule()
6257 adv_fltr->rule_info.fltr_rule_id = le16_to_cpu(s_rule->index); in ice_add_adv_rule()
6278 kfree(s_rule); in ice_add_adv_rule()
6503 struct ice_sw_rule_lkup_rx_tx *s_rule; in ice_rem_adv_rule() local
6506 rule_buf_sz = ICE_SW_RULE_RX_TX_NO_HDR_SIZE(s_rule); in ice_rem_adv_rule()
6507 s_rule = kzalloc(rule_buf_sz, GFP_KERNEL); in ice_rem_adv_rule()
6508 if (!s_rule) in ice_rem_adv_rule()
6510 s_rule->act = 0; in ice_rem_adv_rule()
6511 s_rule->index = cpu_to_le16(list_elem->rule_info.fltr_rule_id); in ice_rem_adv_rule()
6512 s_rule->hdr_len = 0; in ice_rem_adv_rule()
6513 status = ice_aq_sw_rules(hw, (struct ice_aqc_sw_rules *)s_rule, in ice_rem_adv_rule()
6527 kfree(s_rule); in ice_rem_adv_rule()