Lines Matching defs:flow

151  * ice_vc_fdir_alloc_prof - allocate profile for this filter flow type
153 * @flow: filter flow type
158 ice_vc_fdir_alloc_prof(struct ice_vf *vf, enum ice_fltr_ptype flow)
171 if (!fdir->fdir_prof[flow]) {
172 fdir->fdir_prof[flow] = devm_kzalloc(ice_pf_to_dev(vf->pf),
175 if (!fdir->fdir_prof[flow])
183 * ice_vc_fdir_free_prof - free profile for this filter flow type
185 * @flow: filter flow type
188 ice_vc_fdir_free_prof(struct ice_vf *vf, enum ice_fltr_ptype flow)
195 if (!fdir->fdir_prof[flow])
198 devm_kfree(ice_pf_to_dev(vf->pf), fdir->fdir_prof[flow]);
199 fdir->fdir_prof[flow] = NULL;
209 enum ice_fltr_ptype flow;
214 for (flow = ICE_FLTR_PTYPE_NONF_NONE; flow < ICE_FLTR_PTYPE_MAX; flow++)
215 ice_vc_fdir_free_prof(vf, flow);
266 * @seg: array of one or more packet segments that describe the flow
269 * flow's packet segment field
310 * ice_vc_fdir_set_flow_hdr - config the flow's packet segment header
313 * @seg: array of one or more packet segments that describe the flow
322 enum ice_fltr_ptype flow = conf->input.flow_type;
326 switch (flow) {
389 flow, vf->vf_id);
448 dev_dbg(dev, "Invalid flow type 0x%x for VF %d failed\n",
449 flow, vf->vf_id);
457 * ice_vc_fdir_rem_prof - remove profile for this filter flow type
459 * @flow: filter flow type
463 ice_vc_fdir_rem_prof(struct ice_vf *vf, enum ice_fltr_ptype flow, int tun)
476 if (!fdir->fdir_prof || !fdir->fdir_prof[flow])
479 vf_prof = fdir->fdir_prof[flow];
488 if (!fdir->prof_entry_cnt[flow][tun])
491 for (i = 0; i < fdir->prof_entry_cnt[flow][tun]; i++)
508 fdir->prof_entry_cnt[flow][tun] = 0;
517 enum ice_fltr_ptype flow;
519 for (flow = ICE_FLTR_PTYPE_NONF_NONE;
520 flow < ICE_FLTR_PTYPE_MAX; flow++) {
521 ice_vc_fdir_rem_prof(vf, flow, 0);
522 ice_vc_fdir_rem_prof(vf, flow, 1);
532 enum ice_fltr_ptype flow;
534 for (flow = ICE_FLTR_PTYPE_NONF_NONE;
535 flow < ICE_FLTR_PTYPE_MAX; flow++) {
536 fdir->fdir_fltr_cnt[flow][0] = 0;
537 fdir->fdir_fltr_cnt[flow][1] = 0;
610 * @flow: filter flow type
611 * @seg: array of one or more packet segments that describe the flow
614 * Write the flow's profile config and packet segment into the hardware
619 ice_vc_fdir_write_flow_prof(struct ice_vf *vf, enum ice_fltr_ptype flow,
645 vf_prof = fdir->fdir_prof[flow];
654 if (fdir->fdir_fltr_cnt[flow][tun]) {
662 ice_vc_fdir_rem_prof(vf, flow, tun);
668 dev_dbg(dev, "Could not add VSI flow 0x%x for VF %d\n",
669 flow, vf->vf_id);
677 dev_dbg(dev, "Could not add flow 0x%x VSI entry for VF %d\n",
678 flow, vf->vf_id);
687 "Could not add flow 0x%x Ctrl VSI entry for VF %d\n",
688 flow, vf->vf_id);
694 fdir->prof_entry_cnt[flow][tun] = 0;
699 fdir->prof_entry_cnt[flow][tun]++;
704 fdir->prof_entry_cnt[flow][tun]++;
738 enum ice_fltr_ptype flow;
743 dev_dbg(dev, "Found flow profile conflict for VF %d\n",
748 flow = input->flow_type;
749 ret = ice_vc_fdir_alloc_prof(vf, flow);
751 dev_dbg(dev, "Alloc flow prof for VF %d failed\n", vf->vf_id);
761 dev_dbg(dev, "Set flow field for VF %d failed\n", vf->vf_id);
767 dev_dbg(dev, "Set flow hdr for VF %d failed\n", vf->vf_id);
771 ret = ice_vc_fdir_write_flow_prof(vf, flow, seg, tun);
775 dev_dbg(dev, "Write flow profile for VF %d failed\n",
1529 * Post process for flow director add command. If success, then do post process
1593 * Post process for flow director del command. If success, then do post process