Lines Matching refs:s_rule

2608 		 struct ice_sw_rule_lkup_rx_tx *s_rule,  in ice_fill_sw_rule()  argument
2621 s_rule->act = 0; in ice_fill_sw_rule()
2622 s_rule->index = cpu_to_le16(f_info->fltr_rule_id); in ice_fill_sw_rule()
2623 s_rule->hdr_len = 0; in ice_fill_sw_rule()
2628 eth_hdr = s_rule->hdr_data; in ice_fill_sw_rule()
2711 s_rule->hdr.type = (f_info->flag & ICE_FLTR_RX) ? in ice_fill_sw_rule()
2716 s_rule->recipe_id = cpu_to_le16(f_info->lkup_type); in ice_fill_sw_rule()
2717 s_rule->src = cpu_to_le16(f_info->src); in ice_fill_sw_rule()
2718 s_rule->act = cpu_to_le32(act); in ice_fill_sw_rule()
2732 s_rule->hdr_len = cpu_to_le16(eth_hdr_sz); in ice_fill_sw_rule()
2886 struct ice_sw_rule_vsi_list *s_rule; in ice_update_vsi_list_rule() local
2911 s_rule_size = (u16)ICE_SW_RULE_VSI_LIST_SIZE(s_rule, num_vsi); in ice_update_vsi_list_rule()
2912 s_rule = devm_kzalloc(ice_hw_to_dev(hw), s_rule_size, GFP_KERNEL); in ice_update_vsi_list_rule()
2913 if (!s_rule) in ice_update_vsi_list_rule()
2921 s_rule->vsi[i] = in ice_update_vsi_list_rule()
2925 s_rule->hdr.type = cpu_to_le16(rule_type); in ice_update_vsi_list_rule()
2926 s_rule->number_vsi = cpu_to_le16(num_vsi); in ice_update_vsi_list_rule()
2927 s_rule->index = cpu_to_le16(vsi_list_id); in ice_update_vsi_list_rule()
2929 status = ice_aq_sw_rules(hw, s_rule, s_rule_size, 1, opc, NULL); in ice_update_vsi_list_rule()
2932 devm_kfree(ice_hw_to_dev(hw), s_rule); in ice_update_vsi_list_rule()
2975 struct ice_sw_rule_lkup_rx_tx *s_rule; in ice_create_pkt_fwd_rule() local
2980 s_rule = devm_kzalloc(ice_hw_to_dev(hw), in ice_create_pkt_fwd_rule()
2981 ICE_SW_RULE_RX_TX_ETH_HDR_SIZE(s_rule), in ice_create_pkt_fwd_rule()
2983 if (!s_rule) in ice_create_pkt_fwd_rule()
3000 ice_fill_sw_rule(hw, &fm_entry->fltr_info, s_rule, in ice_create_pkt_fwd_rule()
3003 status = ice_aq_sw_rules(hw, s_rule, in ice_create_pkt_fwd_rule()
3004 ICE_SW_RULE_RX_TX_ETH_HDR_SIZE(s_rule), 1, in ice_create_pkt_fwd_rule()
3011 f_entry->fltr_info.fltr_rule_id = le16_to_cpu(s_rule->index); in ice_create_pkt_fwd_rule()
3012 fm_entry->fltr_info.fltr_rule_id = le16_to_cpu(s_rule->index); in ice_create_pkt_fwd_rule()
3022 devm_kfree(ice_hw_to_dev(hw), s_rule); in ice_create_pkt_fwd_rule()
3037 struct ice_sw_rule_lkup_rx_tx *s_rule; in ice_update_pkt_fwd_rule() local
3040 s_rule = devm_kzalloc(ice_hw_to_dev(hw), in ice_update_pkt_fwd_rule()
3041 ICE_SW_RULE_RX_TX_ETH_HDR_SIZE(s_rule), in ice_update_pkt_fwd_rule()
3043 if (!s_rule) in ice_update_pkt_fwd_rule()
3046 ice_fill_sw_rule(hw, f_info, s_rule, ice_aqc_opc_update_sw_rules); in ice_update_pkt_fwd_rule()
3048 s_rule->index = cpu_to_le16(f_info->fltr_rule_id); in ice_update_pkt_fwd_rule()
3051 status = ice_aq_sw_rules(hw, s_rule, in ice_update_pkt_fwd_rule()
3052 ICE_SW_RULE_RX_TX_ETH_HDR_SIZE(s_rule), 1, in ice_update_pkt_fwd_rule()
3055 devm_kfree(ice_hw_to_dev(hw), s_rule); in ice_update_pkt_fwd_rule()
3336 struct ice_sw_rule_vsi_list *s_rule; in ice_remove_vsi_list_rule() local
3340 s_rule_size = (u16)ICE_SW_RULE_VSI_LIST_SIZE(s_rule, 0); in ice_remove_vsi_list_rule()
3341 s_rule = devm_kzalloc(ice_hw_to_dev(hw), s_rule_size, GFP_KERNEL); in ice_remove_vsi_list_rule()
3342 if (!s_rule) in ice_remove_vsi_list_rule()
3345 s_rule->hdr.type = cpu_to_le16(ICE_AQC_SW_RULES_T_VSI_LIST_CLEAR); in ice_remove_vsi_list_rule()
3346 s_rule->index = cpu_to_le16(vsi_list_id); in ice_remove_vsi_list_rule()
3354 devm_kfree(ice_hw_to_dev(hw), s_rule); in ice_remove_vsi_list_rule()
3506 struct ice_sw_rule_lkup_rx_tx *s_rule; in ice_remove_rule_internal() local
3508 s_rule = devm_kzalloc(ice_hw_to_dev(hw), in ice_remove_rule_internal()
3509 ICE_SW_RULE_RX_TX_NO_HDR_SIZE(s_rule), in ice_remove_rule_internal()
3511 if (!s_rule) { in ice_remove_rule_internal()
3516 ice_fill_sw_rule(hw, &list_elem->fltr_info, s_rule, in ice_remove_rule_internal()
3519 status = ice_aq_sw_rules(hw, s_rule, in ice_remove_rule_internal()
3520 ICE_SW_RULE_RX_TX_NO_HDR_SIZE(s_rule), in ice_remove_rule_internal()
3524 devm_kfree(ice_hw_to_dev(hw), s_rule); in ice_remove_rule_internal()
5642 struct ice_sw_rule_lkup_rx_tx *s_rule, in ice_fill_adv_dummy_packet() argument
5651 pkt = s_rule->hdr_data; in ice_fill_adv_dummy_packet()
5756 s_rule->hdr_len = cpu_to_le16(profile->pkt_len); in ice_fill_adv_dummy_packet()
6051 struct ice_sw_rule_lkup_rx_tx *s_rule = NULL; in ice_add_adv_rule() local
6142 rule_buf_sz = ICE_SW_RULE_RX_TX_HDR_SIZE(s_rule, profile->pkt_len); in ice_add_adv_rule()
6143 s_rule = kzalloc(rule_buf_sz, GFP_KERNEL); in ice_add_adv_rule()
6144 if (!s_rule) { in ice_add_adv_rule()
6206 s_rule->hdr.type = cpu_to_le16(ICE_AQC_SW_RULES_T_LKUP_TX); in ice_add_adv_rule()
6207 s_rule->src = cpu_to_le16(rinfo->sw_act.src); in ice_add_adv_rule()
6209 s_rule->hdr.type = cpu_to_le16(ICE_AQC_SW_RULES_T_LKUP_RX); in ice_add_adv_rule()
6210 s_rule->src = cpu_to_le16(hw->port_info->lport); in ice_add_adv_rule()
6213 s_rule->recipe_id = cpu_to_le16(rid); in ice_add_adv_rule()
6214 s_rule->act = cpu_to_le32(act); in ice_add_adv_rule()
6216 status = ice_fill_adv_dummy_packet(lkups, lkups_cnt, s_rule, profile); in ice_add_adv_rule()
6220 status = ice_fill_adv_packet_tun(hw, rinfo->tun_type, s_rule->hdr_data, in ice_add_adv_rule()
6226 s_rule->hdr_data, in ice_add_adv_rule()
6231 status = ice_aq_sw_rules(hw, (struct ice_aqc_sw_rules *)s_rule, in ice_add_adv_rule()
6253 adv_fltr->rule_info.fltr_rule_id = le16_to_cpu(s_rule->index); in ice_add_adv_rule()
6274 kfree(s_rule); in ice_add_adv_rule()
6499 struct ice_sw_rule_lkup_rx_tx *s_rule; in ice_rem_adv_rule() local
6502 rule_buf_sz = ICE_SW_RULE_RX_TX_NO_HDR_SIZE(s_rule); in ice_rem_adv_rule()
6503 s_rule = kzalloc(rule_buf_sz, GFP_KERNEL); in ice_rem_adv_rule()
6504 if (!s_rule) in ice_rem_adv_rule()
6506 s_rule->act = 0; in ice_rem_adv_rule()
6507 s_rule->index = cpu_to_le16(list_elem->rule_info.fltr_rule_id); in ice_rem_adv_rule()
6508 s_rule->hdr_len = 0; in ice_rem_adv_rule()
6509 status = ice_aq_sw_rules(hw, (struct ice_aqc_sw_rules *)s_rule, in ice_rem_adv_rule()
6530 kfree(s_rule); in ice_rem_adv_rule()