aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/intel/ice/ice_common.c
diff options
context:
space:
mode:
authorBen Shelton <[email protected]>2020-11-21 00:39:33 +0000
committerTony Nguyen <[email protected]>2021-02-09 00:27:01 +0000
commit4f8a14976aa4b3304e83ff9b4e0a466a3131df3c (patch)
tree2cedd9bfe03e46459e0aa8b5ff1396a8471e6548 /drivers/net/ethernet/intel/ice/ice_common.c
parentice: create scheduler aggregator node config and move VSIs (diff)
downloadkernel-4f8a14976aa4b3304e83ff9b4e0a466a3131df3c.tar.gz
kernel-4f8a14976aa4b3304e83ff9b4e0a466a3131df3c.zip
ice: Use PSM clock frequency to calculate RL profiles
The core clock frequency is currently hardcoded at 446 MHz for the RL profile calculations. This causes issues since not all devices use that clock frequency. Read the GLGEN_CLKSTAT_SRC register to determine which PSM clock frequency is selected. This ensures that the rate limiter profile calculations will be correct. Signed-off-by: Ben Shelton <[email protected]> Tested-by: Tony Brelinski <[email protected]> Signed-off-by: Tony Nguyen <[email protected]>
Diffstat (limited to 'drivers/net/ethernet/intel/ice/ice_common.c')
-rw-r--r--drivers/net/ethernet/intel/ice/ice_common.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/intel/ice/ice_common.c b/drivers/net/ethernet/intel/ice/ice_common.c
index 11bb59c2ecbb..e9b40cdfeb0c 100644
--- a/drivers/net/ethernet/intel/ice/ice_common.c
+++ b/drivers/net/ethernet/intel/ice/ice_common.c
@@ -907,6 +907,7 @@ enum ice_status ice_init_hw(struct ice_hw *hw)
ice_debug(hw, ICE_DBG_SCHED, "Failed to get scheduler allocated resources\n");
goto err_unroll_alloc;
}
+ ice_sched_get_psm_clk_freq(hw);
/* Initialize port_info struct with scheduler data */
status = ice_sched_init_port(hw->port_info);