From: Qi Zhang Date: Mon, 15 Jun 2020 02:04:56 +0000 (+0800) Subject: net/ice/base: update VSI handle to remaining VSI X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=1b651a2a1d177ff18e2bae5ffaa2ff59b69ba4b5;p=dpdk.git net/ice/base: update VSI handle to remaining VSI When removing VSI from VSI list, if only one VSI left, we need to downgrade a switch rule's action from "to VSI LIST" to "to VSI", So, needs to update the VSI handle to the last remaining VSI for the new action but not the first VSI be added to the list. Signed-off-by: Haiyue Wang Signed-off-by: Paul M Stillwell Jr Signed-off-by: Qi Zhang Acked-by: Qiming Yang --- diff --git a/drivers/net/ice/base/ice_switch.c b/drivers/net/ice/base/ice_switch.c index f379a5f5dd..01dcace557 100644 --- a/drivers/net/ice/base/ice_switch.c +++ b/drivers/net/ice/base/ice_switch.c @@ -7491,6 +7491,7 @@ ice_adv_rem_update_vsi_list(struct ice_hw *hw, u16 vsi_handle, ice_get_hw_vsi_num(hw, rem_vsi_handle); fm_list->rule_info.sw_act.fwd_id.hw_vsi_id = ice_get_hw_vsi_num(hw, rem_vsi_handle); + fm_list->rule_info.sw_act.vsi_handle = rem_vsi_handle; /* Update the previous switch rule of "MAC forward to VSI" to * "MAC fwd to VSI list"