1616 * @vf: pointer to VF struct
1717 *
1818 * This function adds advanced rule that forwards packets with
19- * VF's VSI index to the corresponding switchdev ctrl VSI queue.
19+ * VF's VSI index to the corresponding eswitch ctrl VSI queue.
2020 */
2121static int
2222ice_eswitch_add_vf_sp_rule (struct ice_pf * pf , struct ice_vf * vf )
2323{
24- struct ice_vsi * ctrl_vsi = pf -> switchdev .control_vsi ;
24+ struct ice_vsi * ctrl_vsi = pf -> eswitch .control_vsi ;
2525 struct ice_adv_rule_info rule_info = { 0 };
2626 struct ice_adv_lkup_elem * list ;
2727 struct ice_hw * hw = & pf -> hw ;
@@ -59,7 +59,7 @@ ice_eswitch_add_vf_sp_rule(struct ice_pf *pf, struct ice_vf *vf)
5959 * @vf: pointer to the VF struct
6060 *
6161 * Delete the advanced rule that was used to forward packets with the VF's VSI
62- * index to the corresponding switchdev ctrl VSI queue.
62+ * index to the corresponding eswitch ctrl VSI queue.
6363 */
6464static void ice_eswitch_del_vf_sp_rule (struct ice_vf * vf )
6565{
@@ -70,26 +70,26 @@ static void ice_eswitch_del_vf_sp_rule(struct ice_vf *vf)
7070}
7171
7272/**
73- * ice_eswitch_setup_env - configure switchdev HW filters
73+ * ice_eswitch_setup_env - configure eswitch HW filters
7474 * @pf: pointer to PF struct
7575 *
7676 * This function adds HW filters configuration specific for switchdev
7777 * mode.
7878 */
7979static int ice_eswitch_setup_env (struct ice_pf * pf )
8080{
81- struct ice_vsi * uplink_vsi = pf -> switchdev .uplink_vsi ;
82- struct net_device * uplink_netdev = uplink_vsi -> netdev ;
83- struct ice_vsi * ctrl_vsi = pf -> switchdev . control_vsi ;
81+ struct ice_vsi * uplink_vsi = pf -> eswitch .uplink_vsi ;
82+ struct ice_vsi * ctrl_vsi = pf -> eswitch . control_vsi ;
83+ struct net_device * netdev = uplink_vsi -> netdev ;
8484 struct ice_vsi_vlan_ops * vlan_ops ;
8585 bool rule_added = false;
8686
8787 ice_remove_vsi_fltr (& pf -> hw , uplink_vsi -> idx );
8888
89- netif_addr_lock_bh (uplink_netdev );
90- __dev_uc_unsync (uplink_netdev , NULL );
91- __dev_mc_unsync (uplink_netdev , NULL );
92- netif_addr_unlock_bh (uplink_netdev );
89+ netif_addr_lock_bh (netdev );
90+ __dev_uc_unsync (netdev , NULL );
91+ __dev_mc_unsync (netdev , NULL );
92+ netif_addr_unlock_bh (netdev );
9393
9494 if (ice_vsi_add_vlan_zero (uplink_vsi ))
9595 goto err_def_rx ;
@@ -132,10 +132,10 @@ static int ice_eswitch_setup_env(struct ice_pf *pf)
132132}
133133
134134/**
135- * ice_eswitch_remap_rings_to_vectors - reconfigure rings of switchdev ctrl VSI
135+ * ice_eswitch_remap_rings_to_vectors - reconfigure rings of eswitch ctrl VSI
136136 * @pf: pointer to PF struct
137137 *
138- * In switchdev number of allocated Tx/Rx rings is equal.
138+ * In eswitch number of allocated Tx/Rx rings is equal.
139139 *
140140 * This function fills q_vectors structures associated with representor and
141141 * move each ring pairs to port representor netdevs. Each port representor
@@ -144,7 +144,7 @@ static int ice_eswitch_setup_env(struct ice_pf *pf)
144144 */
145145static void ice_eswitch_remap_rings_to_vectors (struct ice_pf * pf )
146146{
147- struct ice_vsi * vsi = pf -> switchdev .control_vsi ;
147+ struct ice_vsi * vsi = pf -> eswitch .control_vsi ;
148148 int q_id ;
149149
150150 ice_for_each_txq (vsi , q_id ) {
@@ -189,7 +189,7 @@ static void ice_eswitch_remap_rings_to_vectors(struct ice_pf *pf)
189189/**
190190 * ice_eswitch_release_reprs - clear PR VSIs configuration
191191 * @pf: poiner to PF struct
192- * @ctrl_vsi: pointer to switchdev control VSI
192+ * @ctrl_vsi: pointer to eswitch control VSI
193193 */
194194static void
195195ice_eswitch_release_reprs (struct ice_pf * pf , struct ice_vsi * ctrl_vsi )
@@ -223,7 +223,7 @@ ice_eswitch_release_reprs(struct ice_pf *pf, struct ice_vsi *ctrl_vsi)
223223 */
224224static int ice_eswitch_setup_reprs (struct ice_pf * pf )
225225{
226- struct ice_vsi * ctrl_vsi = pf -> switchdev .control_vsi ;
226+ struct ice_vsi * ctrl_vsi = pf -> eswitch .control_vsi ;
227227 int max_vsi_num = 0 ;
228228 struct ice_vf * vf ;
229229 unsigned int bkt ;
@@ -359,7 +359,7 @@ ice_eswitch_port_start_xmit(struct sk_buff *skb, struct net_device *netdev)
359359}
360360
361361/**
362- * ice_eswitch_set_target_vsi - set switchdev context in Tx context descriptor
362+ * ice_eswitch_set_target_vsi - set eswitch context in Tx context descriptor
363363 * @skb: pointer to send buffer
364364 * @off: pointer to offload struct
365365 */
@@ -382,16 +382,16 @@ ice_eswitch_set_target_vsi(struct sk_buff *skb,
382382}
383383
384384/**
385- * ice_eswitch_release_env - clear switchdev HW filters
385+ * ice_eswitch_release_env - clear eswitch HW filters
386386 * @pf: pointer to PF struct
387387 *
388388 * This function removes HW filters configuration specific for switchdev
389389 * mode and restores default legacy mode settings.
390390 */
391391static void ice_eswitch_release_env (struct ice_pf * pf )
392392{
393- struct ice_vsi * uplink_vsi = pf -> switchdev .uplink_vsi ;
394- struct ice_vsi * ctrl_vsi = pf -> switchdev .control_vsi ;
393+ struct ice_vsi * uplink_vsi = pf -> eswitch .uplink_vsi ;
394+ struct ice_vsi * ctrl_vsi = pf -> eswitch .control_vsi ;
395395 struct ice_vsi_vlan_ops * vlan_ops ;
396396
397397 vlan_ops = ice_get_compat_vsi_vlan_ops (uplink_vsi );
@@ -407,7 +407,7 @@ static void ice_eswitch_release_env(struct ice_pf *pf)
407407}
408408
409409/**
410- * ice_eswitch_vsi_setup - configure switchdev control VSI
410+ * ice_eswitch_vsi_setup - configure eswitch control VSI
411411 * @pf: pointer to PF structure
412412 * @pi: pointer to port_info structure
413413 */
@@ -486,12 +486,12 @@ static int ice_eswitch_enable_switchdev(struct ice_pf *pf)
486486 return - EINVAL ;
487487 }
488488
489- pf -> switchdev .control_vsi = ice_eswitch_vsi_setup (pf , pf -> hw .port_info );
490- if (!pf -> switchdev .control_vsi )
489+ pf -> eswitch .control_vsi = ice_eswitch_vsi_setup (pf , pf -> hw .port_info );
490+ if (!pf -> eswitch .control_vsi )
491491 return - ENODEV ;
492492
493- ctrl_vsi = pf -> switchdev .control_vsi ;
494- pf -> switchdev .uplink_vsi = uplink_vsi ;
493+ ctrl_vsi = pf -> eswitch .control_vsi ;
494+ pf -> eswitch .uplink_vsi = uplink_vsi ;
495495
496496 if (ice_eswitch_setup_env (pf ))
497497 goto err_vsi ;
@@ -526,12 +526,12 @@ static int ice_eswitch_enable_switchdev(struct ice_pf *pf)
526526}
527527
528528/**
529- * ice_eswitch_disable_switchdev - disable switchdev resources
529+ * ice_eswitch_disable_switchdev - disable eswitch resources
530530 * @pf: pointer to PF structure
531531 */
532532static void ice_eswitch_disable_switchdev (struct ice_pf * pf )
533533{
534- struct ice_vsi * ctrl_vsi = pf -> switchdev .control_vsi ;
534+ struct ice_vsi * ctrl_vsi = pf -> eswitch .control_vsi ;
535535
536536 ice_eswitch_napi_disable (pf );
537537 ice_eswitch_br_offloads_deinit (pf );
@@ -625,7 +625,7 @@ void ice_eswitch_release(struct ice_pf *pf)
625625 return ;
626626
627627 ice_eswitch_disable_switchdev (pf );
628- pf -> switchdev .is_running = false;
628+ pf -> eswitch .is_running = false;
629629}
630630
631631/**
@@ -636,14 +636,15 @@ int ice_eswitch_configure(struct ice_pf *pf)
636636{
637637 int status ;
638638
639- if (pf -> eswitch_mode == DEVLINK_ESWITCH_MODE_LEGACY || pf -> switchdev .is_running )
639+ if (pf -> eswitch_mode == DEVLINK_ESWITCH_MODE_LEGACY ||
640+ pf -> eswitch .is_running )
640641 return 0 ;
641642
642643 status = ice_eswitch_enable_switchdev (pf );
643644 if (status )
644645 return status ;
645646
646- pf -> switchdev .is_running = true;
647+ pf -> eswitch .is_running = true;
647648 return 0 ;
648649}
649650
@@ -693,7 +694,7 @@ void ice_eswitch_stop_all_tx_queues(struct ice_pf *pf)
693694 */
694695int ice_eswitch_rebuild (struct ice_pf * pf )
695696{
696- struct ice_vsi * ctrl_vsi = pf -> switchdev .control_vsi ;
697+ struct ice_vsi * ctrl_vsi = pf -> eswitch .control_vsi ;
697698 int status ;
698699
699700 ice_eswitch_napi_disable (pf );
0 commit comments