From: Dapeng Yu <dapengx...@intel.com> In original implementation, when DCF is initialized, the physical function ID of its parent adapter is not set correctly. Its initial value is always zero, even if DCF is created on 1# physical function and, further, causes ACL to initialize wrongly. Finally, the ACL flow rule cannot take effect if it is created via VF0 of physical function 1#.
This patch makes VF able to get its parent's physical function ID. Signed-off-by: Dapeng Yu <dapengx...@intel.com> --- drivers/net/ice/ice_dcf_parent.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/net/ice/ice_dcf_parent.c b/drivers/net/ice/ice_dcf_parent.c index f461318f96..9a32fde59a 100644 --- a/drivers/net/ice/ice_dcf_parent.c +++ b/drivers/net/ice/ice_dcf_parent.c @@ -317,6 +317,9 @@ ice_dcf_init_parent_hw(struct ice_hw *hw) if (status) goto err_unroll_alloc; + if (!hw->port_info->is_vf) + hw->pf_id = hw->port_info->pf_vf_num; + pcaps = (struct ice_aqc_get_phy_caps_data *) ice_malloc(hw, sizeof(*pcaps)); if (!pcaps) { -- 2.27.0