Lines Matching refs:new_cfg

65 	struct ice_dcbx_cfg *new_cfg;  in ice_dcbnl_setets()  local
78 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_setets()
82 new_cfg->etscfg.willing = ets->willing; in ice_dcbnl_setets()
83 new_cfg->etscfg.cbs = ets->cbs; in ice_dcbnl_setets()
85 new_cfg->etscfg.tcbwtable[i] = ets->tc_tx_bw[i]; in ice_dcbnl_setets()
87 new_cfg->etscfg.tsatable[i] = ets->tc_tsa[i]; in ice_dcbnl_setets()
88 if (new_cfg->pfc_mode == ICE_QOS_MODE_VLAN) { in ice_dcbnl_setets()
90 new_cfg->etscfg.prio_table[i] = ets->prio_tc[i]; in ice_dcbnl_setets()
91 new_cfg->etsrec.prio_table[i] = ets->reco_prio_tc[i]; in ice_dcbnl_setets()
93 new_cfg->etsrec.tcbwtable[i] = ets->tc_reco_bw[i]; in ice_dcbnl_setets()
95 new_cfg->etsrec.tsatable[i] = ets->tc_reco_tsa[i]; in ice_dcbnl_setets()
98 if (ice_dcb_bwchk(pf, new_cfg)) { in ice_dcbnl_setets()
103 new_cfg->etscfg.maxtcs = pf->hw.func_caps.common_cap.maxtc; in ice_dcbnl_setets()
106 new_cfg->etscfg.tcbwtable[0] = 100; in ice_dcbnl_setets()
109 new_cfg->etsrec.tcbwtable[0] = 100; in ice_dcbnl_setets()
111 err = ice_pf_dcb_cfg(pf, new_cfg, true); in ice_dcbnl_setets()
267 struct ice_dcbx_cfg *new_cfg; in ice_dcbnl_setpfc() local
281 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_setpfc()
284 new_cfg->pfc.pfccap = pfc->pfc_cap; in ice_dcbnl_setpfc()
286 new_cfg->pfc.pfccap = pf->hw.func_caps.common_cap.maxtc; in ice_dcbnl_setpfc()
288 new_cfg->pfc.pfcena = pfc->pfc_en; in ice_dcbnl_setpfc()
290 err = ice_pf_dcb_cfg(pf, new_cfg, true); in ice_dcbnl_setpfc()
332 struct ice_dcbx_cfg *new_cfg; in ice_dcbnl_set_pfc_cfg() local
346 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_set_pfc_cfg()
348 new_cfg->pfc.pfccap = pf->hw.func_caps.common_cap.maxtc; in ice_dcbnl_set_pfc_cfg()
350 new_cfg->pfc.pfcena |= BIT(prio); in ice_dcbnl_set_pfc_cfg()
352 new_cfg->pfc.pfcena &= ~BIT(prio); in ice_dcbnl_set_pfc_cfg()
355 prio, set, new_cfg->pfc.pfcena); in ice_dcbnl_set_pfc_cfg()
469 struct ice_dcbx_cfg *new_cfg; in ice_dcbnl_set_pg_tc_cfg_tx() local
484 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_set_pg_tc_cfg_tx()
490 new_cfg->etscfg.prio_table[i] = tc; in ice_dcbnl_set_pg_tc_cfg_tx()
492 new_cfg->etscfg.tsatable[tc] = ICE_IEEE_TSA_ETS; in ice_dcbnl_set_pg_tc_cfg_tx()
529 struct ice_dcbx_cfg *new_cfg; in ice_dcbnl_set_pg_bwg_cfg_tx() local
543 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_set_pg_bwg_cfg_tx()
545 new_cfg->etscfg.tcbwtable[pgid] = bw_pct; in ice_dcbnl_set_pg_bwg_cfg_tx()
737 struct ice_dcbx_cfg *old_cfg, *new_cfg; in ice_dcbnl_setapp() local
778 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_setapp()
785 if (test_and_set_bit(app->protocol, new_cfg->dscp_mapped)) { in ice_dcbnl_setapp()
813 new_cfg->pfc_mode = ICE_QOS_MODE_DSCP; in ice_dcbnl_setapp()
816 new_cfg->etscfg.willing = 0; in ice_dcbnl_setapp()
817 new_cfg->pfc.pfccap = max_tc; in ice_dcbnl_setapp()
818 new_cfg->pfc.willing = 0; in ice_dcbnl_setapp()
827 new_cfg->dscp_map[dscp] = i; in ice_dcbnl_setapp()
830 new_cfg->dscp_map[dscp + offset] = i; in ice_dcbnl_setapp()
833 new_cfg->etscfg.tcbwtable[0] = 100; in ice_dcbnl_setapp()
834 new_cfg->etscfg.tsatable[0] = ICE_IEEE_TSA_ETS; in ice_dcbnl_setapp()
835 new_cfg->etscfg.prio_table[0] = 0; in ice_dcbnl_setapp()
838 new_cfg->etscfg.tcbwtable[i] = 0; in ice_dcbnl_setapp()
839 new_cfg->etscfg.tsatable[i] = ICE_IEEE_TSA_ETS; in ice_dcbnl_setapp()
840 new_cfg->etscfg.prio_table[i] = i; in ice_dcbnl_setapp()
845 new_cfg->dscp_map[app->protocol] = app->priority; in ice_dcbnl_setapp()
846 new_cfg->app[new_cfg->numapps++] = new_app; in ice_dcbnl_setapp()
848 ret = ice_pf_dcb_cfg(pf, new_cfg, true); in ice_dcbnl_setapp()
870 struct ice_dcbx_cfg *old_cfg, *new_cfg; in ice_dcbnl_delapp() local
891 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_delapp()
893 for (i = 0; i < new_cfg->numapps; i++) { in ice_dcbnl_delapp()
894 if (app->selector == new_cfg->app[i].selector && in ice_dcbnl_delapp()
895 app->protocol == new_cfg->app[i].prot_id && in ice_dcbnl_delapp()
896 app->priority == new_cfg->app[i].priority) { in ice_dcbnl_delapp()
897 new_cfg->app[i].selector = 0; in ice_dcbnl_delapp()
898 new_cfg->app[i].prot_id = 0; in ice_dcbnl_delapp()
899 new_cfg->app[i].priority = 0; in ice_dcbnl_delapp()
905 if (i == new_cfg->numapps) { in ice_dcbnl_delapp()
910 new_cfg->numapps--; in ice_dcbnl_delapp()
912 for (j = i; j < new_cfg->numapps; j++) { in ice_dcbnl_delapp()
913 new_cfg->app[j].selector = old_cfg->app[j + 1].selector; in ice_dcbnl_delapp()
914 new_cfg->app[j].prot_id = old_cfg->app[j + 1].prot_id; in ice_dcbnl_delapp()
915 new_cfg->app[j].priority = old_cfg->app[j + 1].priority; in ice_dcbnl_delapp()
926 clear_bit(app->protocol, new_cfg->dscp_mapped); in ice_dcbnl_delapp()
928 new_cfg->dscp_map[app->protocol] = app->protocol % in ice_dcbnl_delapp()
934 if (bitmap_empty(new_cfg->dscp_mapped, ICE_DSCP_NUM_VAL) && in ice_dcbnl_delapp()
935 new_cfg->pfc_mode == ICE_QOS_MODE_DSCP) { in ice_dcbnl_delapp()
946 new_cfg->pfc_mode = ICE_QOS_MODE_VLAN; in ice_dcbnl_delapp()
950 ret = ice_pf_dcb_cfg(pf, new_cfg, true); in ice_dcbnl_delapp()
978 struct ice_dcbx_cfg *new_cfg; in ice_dcbnl_cee_set_all() local
990 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_cee_set_all()
994 err = ice_pf_dcb_cfg(pf, new_cfg, true); in ice_dcbnl_cee_set_all()
1114 struct ice_dcbx_cfg *new_cfg) in ice_dcbnl_flush_apps() argument
1126 if (!ice_dcbnl_find_app(new_cfg, &app)) in ice_dcbnl_flush_apps()