Home
last modified time | relevance | path

Searched refs:fbdiv (Results 1 – 13 of 13) sorted by relevance

/external/u-boot/drivers/clk/rockchip/
Dclk_rk3128.c31 .fbdiv = (u32)((u64)hz * _refdiv * _postdiv1 * _postdiv2 / OSC_HZ),\
45 uint vco_hz = OSC_HZ / 1000 * div->fbdiv / div->refdiv * 1000; in rkclk_set_pll()
49 pll, div->fbdiv, div->refdiv, div->postdiv1, in rkclk_set_pll()
61 (div->postdiv1 << PLL_POSTDIV1_SHIFT) | div->fbdiv); in rkclk_set_pll()
78 u32 ref_khz = OSC_HZ / 1000, refdiv, fbdiv = 0; in pll_para_config() local
114 fbdiv = vco_khz / fref_khz; in pll_para_config()
115 if ((fbdiv >= max_fbdiv) || (fbdiv <= min_fbdiv)) in pll_para_config()
117 diff_khz = vco_khz - fbdiv * fref_khz; in pll_para_config()
118 if (fbdiv + 1 < max_fbdiv && diff_khz > fref_khz / 2) { in pll_para_config()
119 fbdiv++; in pll_para_config()
[all …]
Dclk_rk3399.c34 u32 fbdiv; member
46 .fbdiv = (u32)((u64)hz * _refdiv * _postdiv1 * _postdiv2 / OSC_HZ),\
294 u32 vco_khz = OSC_HZ / 1000 * div->fbdiv / div->refdiv; in rkclk_set_pll()
299 pll_con, div->fbdiv, div->refdiv, div->postdiv1, in rkclk_set_pll()
303 div->fbdiv >= PLL_DIV_MIN && div->fbdiv <= PLL_DIV_MAX); in rkclk_set_pll()
317 div->fbdiv << PLL_FBDIV_SHIFT); in rkclk_set_pll()
336 u32 ref_khz = OSC_HZ / KHz, refdiv, fbdiv = 0; in pll_para_config() local
372 fbdiv = vco_khz / fref_khz; in pll_para_config()
373 if ((fbdiv >= max_fbdiv) || (fbdiv <= min_fbdiv)) in pll_para_config()
375 diff_khz = vco_khz - fbdiv * fref_khz; in pll_para_config()
[all …]
Dclk_rk322x.c30 .fbdiv = (u32)((u64)hz * _refdiv * _postdiv1 * _postdiv2 / OSC_HZ), \
48 uint vco_hz = OSC_HZ / 1000 * div->fbdiv / div->refdiv * 1000; in rkclk_set_pll()
52 pll, div->fbdiv, div->refdiv, div->postdiv1, in rkclk_set_pll()
64 (div->postdiv1 << PLL_POSTDIV1_SHIFT) | div->fbdiv); in rkclk_set_pll()
173 uint32_t refdiv, fbdiv, postdiv1, postdiv2; in rkclk_pll_get_rate() local
200 fbdiv = (con & PLL_FBDIV_MASK) >> PLL_FBDIV_SHIFT; in rkclk_pll_get_rate()
204 return (24 * fbdiv / (refdiv * postdiv1 * postdiv2)) * 1000000; in rkclk_pll_get_rate()
325 {.refdiv = 1, .fbdiv = 50, .postdiv1 = 3, .postdiv2 = 1}; in rk322x_ddr_set_clk()
329 {.refdiv = 1, .fbdiv = 75, .postdiv1 = 3, .postdiv2 = 1}; in rk322x_ddr_set_clk()
333 {.refdiv = 1, .fbdiv = 100, .postdiv1 = 3, .postdiv2 = 1}; in rk322x_ddr_set_clk()
Dclk_rk3036.c33 .fbdiv = (u32)((u64)hz * _refdiv * _postdiv1 * _postdiv2 / OSC_HZ),\
51 uint vco_hz = OSC_HZ / 1000 * div->fbdiv / div->refdiv * 1000; in rkclk_set_pll()
56 pll, div->fbdiv, div->refdiv, div->postdiv1, in rkclk_set_pll()
66 (div->postdiv1 << PLL_POSTDIV1_SHIFT) | div->fbdiv); in rkclk_set_pll()
172 uint32_t refdiv, fbdiv, postdiv1, postdiv2; in rkclk_pll_get_rate() local
199 fbdiv = (con & PLL_FBDIV_MASK) >> PLL_FBDIV_SHIFT; in rkclk_pll_get_rate()
203 return (24 * fbdiv / (refdiv * postdiv1 * postdiv2)) * 1000000; in rkclk_pll_get_rate()
Dclk_rv1108.c31 .fbdiv = (u32)((u64)hz * _refdiv * _postdiv1 * _postdiv2 / OSC_HZ),\
63 uint32_t refdiv, fbdiv, postdiv1, postdiv2; in rkclk_pll_get_rate() local
74 fbdiv = (con0 >> FBDIV_SHIFT) & FBDIV_MASK; in rkclk_pll_get_rate()
78 freq = (24 * fbdiv / (refdiv * postdiv1 * postdiv2)) * 1000000; in rkclk_pll_get_rate()
Dclk_rk3328.c22 u32 fbdiv; member
34 .fbdiv = (u32)((u64)hz * _refdiv * _postdiv1 * _postdiv2 / OSC_HZ),\
241 u32 vco_khz = OSC_HZ / 1000 * div->fbdiv / div->refdiv; in rkclk_set_pll()
246 pll_con, div->fbdiv, div->refdiv, div->postdiv1, in rkclk_set_pll()
250 div->fbdiv >= PLL_DIV_MIN && div->fbdiv <= PLL_DIV_MAX); in rkclk_set_pll()
264 (div->fbdiv << PLL_FBDIV_SHIFT) | in rkclk_set_pll()
/external/u-boot/drivers/video/rockchip/
Drk_mipi.c202 u64 fbdiv; in rk_mipi_phy_enable() local
280 fbdiv = ddr_clk * prediv / refclk; in rk_mipi_phy_enable()
281 ddr_clk = refclk * fbdiv / prediv; in rk_mipi_phy_enable()
285 __func__, refclk, prediv, fbdiv, ddr_clk); in rk_mipi_phy_enable()
290 test_data[0] = (fbdiv - 1) & 0x1f; in rk_mipi_phy_enable()
292 test_data[0] = (fbdiv - 1) >> 5 | 0x80; in rk_mipi_phy_enable()
/external/u-boot/drivers/clk/
Dclk-hsdk-cgu.c185 u32 fbdiv; member
350 val |= cfg->fbdiv << CGU_PLL_CTRL_FBDIV_SHIFT; in hsdk_pll_set_cfg()
373 u32 idiv, fbdiv, odiv; in pll_get() local
391 fbdiv = 2 * (1 + ((val & CGU_PLL_CTRL_FBDIV_MASK) >> CGU_PLL_CTRL_FBDIV_SHIFT)); in pll_get()
395 rate = (u64)PARENT_RATE * fbdiv; in pll_get()
/external/u-boot/arch/arm/include/asm/arch-rockchip/
Dcru_rv1108.h51 u32 fbdiv; member
Dcru_rk3036.h62 u32 fbdiv; member
Dcru_rk322x.h63 u32 fbdiv; member
Dcru_rk3128.h65 u32 fbdiv; member
/external/u-boot/arch/arm/mach-rockchip/rk3036/
Dsdram_rk3036.c341 dpll_init_cfg.fbdiv); in rkdclk_init()