Lines Matching refs:dvfs
122 struct gm20b_clk_dvfs dvfs; member
190 struct gm20b_clk_dvfs *dvfs) in gm20b_dvfs_calc_det_coeff() argument
201 dvfs->dfs_coeff = min_t(u32, coeff, MASK(GPCPLL_DVFS0_DFS_COEFF_WIDTH)); in gm20b_dvfs_calc_det_coeff()
203 dvfs->dfs_ext_cal = DIV_ROUND_CLOSEST(uv - clk->uvdet_offs, in gm20b_dvfs_calc_det_coeff()
206 if (abs(dvfs->dfs_ext_cal) >= BIT(DFS_DET_RANGE)) in gm20b_dvfs_calc_det_coeff()
209 dvfs->dfs_det_max = 0; in gm20b_dvfs_calc_det_coeff()
212 __func__, uv, dvfs->dfs_coeff, dvfs->dfs_ext_cal, in gm20b_dvfs_calc_det_coeff()
213 dvfs->dfs_det_max); in gm20b_dvfs_calc_det_coeff()
236 det_delta -= clk->dvfs.dfs_ext_cal; in gm20b_dvfs_calc_ndiv()
237 det_delta = min(det_delta, clk->dvfs.dfs_det_max); in gm20b_dvfs_calc_ndiv()
238 det_delta *= clk->dvfs.dfs_coeff; in gm20b_dvfs_calc_ndiv()
550 struct gm20b_clk_dvfs *dvfs) in gm20b_dvfs_program_dfs_detection() argument
561 dvfs->dfs_coeff << GPCPLL_DVFS0_DFS_COEFF_SHIFT | in gm20b_dvfs_program_dfs_detection()
562 dvfs->dfs_det_max << GPCPLL_DVFS0_DFS_DET_MAX_SHIFT); in gm20b_dvfs_program_dfs_detection()
568 gm20b_dvfs_program_ext_cal(clk, dvfs->dfs_ext_cal); in gm20b_dvfs_program_dfs_detection()
631 clk->dvfs = clk->new_dvfs; in gm20b_clk_prog()
798 gm20b_dvfs_calc_det_coeff(clk, clk->uv, &clk->dvfs); in gm20b_clk_init_dvfs()
800 gm20b_dvfs_program_ext_cal(clk, clk->dvfs.dfs_ext_cal); in gm20b_clk_init_dvfs()
801 gm20b_dvfs_program_coeff(clk, clk->dvfs.dfs_coeff); in gm20b_clk_init_dvfs()