Lines Matching refs:new_cfg

65 	struct ice_dcbx_cfg *new_cfg;  in ice_dcbnl_setets()  local
73 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_setets()
77 new_cfg->etscfg.willing = ets->willing; in ice_dcbnl_setets()
78 new_cfg->etscfg.cbs = ets->cbs; in ice_dcbnl_setets()
80 new_cfg->etscfg.tcbwtable[i] = ets->tc_tx_bw[i]; in ice_dcbnl_setets()
82 new_cfg->etscfg.tsatable[i] = ets->tc_tsa[i]; in ice_dcbnl_setets()
83 if (new_cfg->pfc_mode == ICE_QOS_MODE_VLAN) { in ice_dcbnl_setets()
85 new_cfg->etscfg.prio_table[i] = ets->prio_tc[i]; in ice_dcbnl_setets()
86 new_cfg->etsrec.prio_table[i] = ets->reco_prio_tc[i]; in ice_dcbnl_setets()
88 new_cfg->etsrec.tcbwtable[i] = ets->tc_reco_bw[i]; in ice_dcbnl_setets()
90 new_cfg->etsrec.tsatable[i] = ets->tc_reco_tsa[i]; in ice_dcbnl_setets()
93 if (ice_dcb_bwchk(pf, new_cfg)) { in ice_dcbnl_setets()
98 new_cfg->etscfg.maxtcs = pf->hw.func_caps.common_cap.maxtc; in ice_dcbnl_setets()
101 new_cfg->etscfg.tcbwtable[0] = 100; in ice_dcbnl_setets()
104 new_cfg->etsrec.tcbwtable[0] = 100; in ice_dcbnl_setets()
106 err = ice_pf_dcb_cfg(pf, new_cfg, true); in ice_dcbnl_setets()
257 struct ice_dcbx_cfg *new_cfg; in ice_dcbnl_setpfc() local
266 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_setpfc()
269 new_cfg->pfc.pfccap = pfc->pfc_cap; in ice_dcbnl_setpfc()
271 new_cfg->pfc.pfccap = pf->hw.func_caps.common_cap.maxtc; in ice_dcbnl_setpfc()
273 new_cfg->pfc.pfcena = pfc->pfc_en; in ice_dcbnl_setpfc()
275 err = ice_pf_dcb_cfg(pf, new_cfg, true); in ice_dcbnl_setpfc()
317 struct ice_dcbx_cfg *new_cfg; in ice_dcbnl_set_pfc_cfg() local
326 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_set_pfc_cfg()
328 new_cfg->pfc.pfccap = pf->hw.func_caps.common_cap.maxtc; in ice_dcbnl_set_pfc_cfg()
330 new_cfg->pfc.pfcena |= BIT(prio); in ice_dcbnl_set_pfc_cfg()
332 new_cfg->pfc.pfcena &= ~BIT(prio); in ice_dcbnl_set_pfc_cfg()
335 prio, set, new_cfg->pfc.pfcena); in ice_dcbnl_set_pfc_cfg()
444 struct ice_dcbx_cfg *new_cfg; in ice_dcbnl_set_pg_tc_cfg_tx() local
454 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_set_pg_tc_cfg_tx()
460 new_cfg->etscfg.prio_table[i] = tc; in ice_dcbnl_set_pg_tc_cfg_tx()
462 new_cfg->etscfg.tsatable[tc] = ICE_IEEE_TSA_ETS; in ice_dcbnl_set_pg_tc_cfg_tx()
499 struct ice_dcbx_cfg *new_cfg; in ice_dcbnl_set_pg_bwg_cfg_tx() local
508 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_set_pg_bwg_cfg_tx()
510 new_cfg->etscfg.tcbwtable[pgid] = bw_pct; in ice_dcbnl_set_pg_bwg_cfg_tx()
702 struct ice_dcbx_cfg *old_cfg, *new_cfg; in ice_dcbnl_setapp() local
738 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_setapp()
745 if (test_and_set_bit(app->protocol, new_cfg->dscp_mapped)) { in ice_dcbnl_setapp()
773 new_cfg->pfc_mode = ICE_QOS_MODE_DSCP; in ice_dcbnl_setapp()
776 new_cfg->etscfg.willing = 0; in ice_dcbnl_setapp()
777 new_cfg->pfc.pfccap = max_tc; in ice_dcbnl_setapp()
778 new_cfg->pfc.willing = 0; in ice_dcbnl_setapp()
787 new_cfg->dscp_map[dscp] = i; in ice_dcbnl_setapp()
790 new_cfg->dscp_map[dscp + offset] = i; in ice_dcbnl_setapp()
793 new_cfg->etscfg.tcbwtable[0] = 100; in ice_dcbnl_setapp()
794 new_cfg->etscfg.tsatable[0] = ICE_IEEE_TSA_ETS; in ice_dcbnl_setapp()
795 new_cfg->etscfg.prio_table[0] = 0; in ice_dcbnl_setapp()
798 new_cfg->etscfg.tcbwtable[i] = 0; in ice_dcbnl_setapp()
799 new_cfg->etscfg.tsatable[i] = ICE_IEEE_TSA_ETS; in ice_dcbnl_setapp()
800 new_cfg->etscfg.prio_table[i] = i; in ice_dcbnl_setapp()
805 new_cfg->dscp_map[app->protocol] = app->priority; in ice_dcbnl_setapp()
806 new_cfg->app[new_cfg->numapps++] = new_app; in ice_dcbnl_setapp()
808 ret = ice_pf_dcb_cfg(pf, new_cfg, true); in ice_dcbnl_setapp()
830 struct ice_dcbx_cfg *old_cfg, *new_cfg; in ice_dcbnl_delapp() local
846 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_delapp()
848 for (i = 0; i < new_cfg->numapps; i++) { in ice_dcbnl_delapp()
849 if (app->selector == new_cfg->app[i].selector && in ice_dcbnl_delapp()
850 app->protocol == new_cfg->app[i].prot_id && in ice_dcbnl_delapp()
851 app->priority == new_cfg->app[i].priority) { in ice_dcbnl_delapp()
852 new_cfg->app[i].selector = 0; in ice_dcbnl_delapp()
853 new_cfg->app[i].prot_id = 0; in ice_dcbnl_delapp()
854 new_cfg->app[i].priority = 0; in ice_dcbnl_delapp()
860 if (i == new_cfg->numapps) { in ice_dcbnl_delapp()
865 new_cfg->numapps--; in ice_dcbnl_delapp()
867 for (j = i; j < new_cfg->numapps; j++) { in ice_dcbnl_delapp()
868 new_cfg->app[j].selector = old_cfg->app[j + 1].selector; in ice_dcbnl_delapp()
869 new_cfg->app[j].prot_id = old_cfg->app[j + 1].prot_id; in ice_dcbnl_delapp()
870 new_cfg->app[j].priority = old_cfg->app[j + 1].priority; in ice_dcbnl_delapp()
881 clear_bit(app->protocol, new_cfg->dscp_mapped); in ice_dcbnl_delapp()
883 new_cfg->dscp_map[app->protocol] = app->protocol % in ice_dcbnl_delapp()
889 if (bitmap_empty(new_cfg->dscp_mapped, ICE_DSCP_NUM_VAL) && in ice_dcbnl_delapp()
890 new_cfg->pfc_mode == ICE_QOS_MODE_DSCP) { in ice_dcbnl_delapp()
901 new_cfg->pfc_mode = ICE_QOS_MODE_VLAN; in ice_dcbnl_delapp()
905 ret = ice_pf_dcb_cfg(pf, new_cfg, true); in ice_dcbnl_delapp()
933 struct ice_dcbx_cfg *new_cfg; in ice_dcbnl_cee_set_all() local
940 new_cfg = &pf->hw.port_info->qos_cfg.desired_dcbx_cfg; in ice_dcbnl_cee_set_all()
944 err = ice_pf_dcb_cfg(pf, new_cfg, true); in ice_dcbnl_cee_set_all()
1064 struct ice_dcbx_cfg *new_cfg) in ice_dcbnl_flush_apps() argument
1076 if (!ice_dcbnl_find_app(new_cfg, &app)) in ice_dcbnl_flush_apps()