/linux-6.6.21/drivers/clk/x86/ |
D | clk-lgm.c | 124 static const struct clk_div_table pll_div[] = { variable 196 0, PLL_DIV_WIDTH, 24, 1, 0, 0, pll_div), 198 4, PLL_DIV_WIDTH, 25, 1, 0, 0, pll_div), 200 8, PLL_DIV_WIDTH, 26, 1, 0, 0, pll_div), 202 12, PLL_DIV_WIDTH, 27, 1, 0, 0, pll_div), 205 pll_div), 207 0, PLL_DIV_WIDTH, 24, 1, 0, 0, pll_div), 211 1, 0, 0, pll_div), 214 8, PLL_DIV_WIDTH, 26, 1, 0, 0, pll_div), 218 0, PLL_DIV_WIDTH, 24, 1, 0, 0, pll_div), [all …]
|
/linux-6.6.21/sound/soc/codecs/ |
D | wm8804.c | 319 struct pll_div { struct 344 static int pll_factors(struct pll_div *pll_div, unsigned int target, in pll_factors() argument 359 pll_div->freqmode = post_table[i].freqmode; in pll_factors() 360 pll_div->mclkdiv = post_table[i].mclkdiv; in pll_factors() 372 pll_div->prescale = 0; in pll_factors() 376 pll_div->prescale = 1; in pll_factors() 385 pll_div->n = Ndiv; in pll_factors() 396 pll_div->k = K; in pll_factors() 417 struct pll_div pll_div; in wm8804_set_pll() local 419 ret = pll_factors(&pll_div, freq_out, freq_in, in wm8804_set_pll() [all …]
|
D | wm8580.c | 400 static int pll_factors(struct _pll_div *pll_div, unsigned int target, in pll_factors() argument 415 pll_div->freqmode = post_table[i].freqmode; in pll_factors() 416 pll_div->postscale = post_table[i].postscale; in pll_factors() 432 pll_div->prescale = 1; in pll_factors() 435 pll_div->prescale = 0; in pll_factors() 443 pll_div->n = Ndiv; in pll_factors() 451 pll_div->k = K; in pll_factors() 454 pll_div->n, pll_div->k, pll_div->prescale, pll_div->freqmode, in pll_factors() 455 pll_div->postscale); in pll_factors() 467 struct _pll_div pll_div; in wm8580_set_dai_pll() local [all …]
|
D | wm9713.c | 753 struct _pll_div *pll_div, unsigned int source) in pll_factors() argument 764 pll_div->divsel = 1; in pll_factors() 768 pll_div->divctl = 1; in pll_factors() 770 pll_div->divctl = 0; in pll_factors() 773 pll_div->divsel = 0; in pll_factors() 774 pll_div->divctl = 0; in pll_factors() 781 pll_div->lf = 1; in pll_factors() 784 pll_div->lf = 0; in pll_factors() 792 pll_div->n = Ndiv; in pll_factors() 807 pll_div->k = K; in pll_factors() [all …]
|
D | wm8940.c | 528 static struct pll_ pll_div; variable 543 pll_div.pre_scale = 0; in pll_factors() 548 pll_div.pre_scale = 3; in pll_factors() 553 pll_div.pre_scale = 2; in pll_factors() 556 pll_div.pre_scale = 1; in pll_factors() 563 pll_div.n = Ndiv; in pll_factors() 578 pll_div.k = K; in pll_factors() 603 if (pll_div.k) in wm8940_set_dai_pll() 605 (pll_div.pre_scale << 4) | pll_div.n | (1 << 6)); in wm8940_set_dai_pll() 608 (pll_div.pre_scale << 4) | pll_div.n); in wm8940_set_dai_pll() [all …]
|
D | wm8978.c | 409 struct wm8978_pll_div *pll_div, unsigned int target, unsigned int source) in pll_factors() argument 417 pll_div->div2 = 1; in pll_factors() 420 pll_div->div2 = 0; in pll_factors() 428 pll_div->n = n_div; in pll_factors() 436 pll_div->k = k; in pll_factors() 474 struct wm8978_pll_div pll_div; in wm8978_configure_pll() local 536 pll_factors(component, &pll_div, f2, wm8978->f_mclk); in wm8978_configure_pll() 539 __func__, pll_div.n, pll_div.k, pll_div.div2); in wm8978_configure_pll() 544 snd_soc_component_write(component, WM8978_PLL_N, (pll_div.div2 << 4) | pll_div.n); in wm8978_configure_pll() 545 snd_soc_component_write(component, WM8978_PLL_K1, pll_div.k >> 18); in wm8978_configure_pll() [all …]
|
D | wm8974.c | 272 static void pll_factors(struct pll_ *pll_div, in pll_factors() argument 284 pll_div->pre_div = 1; in pll_factors() 287 pll_div->pre_div = 0; in pll_factors() 294 pll_div->n = Ndiv; in pll_factors() 309 pll_div->k = K; in pll_factors() 316 struct pll_ pll_div; in wm8974_set_dai_pll() local 330 pll_factors(&pll_div, freq_out, freq_in); in wm8974_set_dai_pll() 332 snd_soc_component_write(component, WM8974_PLLN, (pll_div.pre_div << 4) | pll_div.n); in wm8974_set_dai_pll() 333 snd_soc_component_write(component, WM8974_PLLK1, pll_div.k >> 18); in wm8974_set_dai_pll() 334 snd_soc_component_write(component, WM8974_PLLK2, (pll_div.k >> 9) & 0x1ff); in wm8974_set_dai_pll() [all …]
|
D | wm8510.c | 271 static struct pll_ pll_div; variable 285 pll_div.pre_div = 1; in pll_factors() 288 pll_div.pre_div = 0; in pll_factors() 295 pll_div.n = Ndiv; in pll_factors() 310 pll_div.k = K; in pll_factors() 332 snd_soc_component_write(component, WM8510_PLLN, (pll_div.pre_div << 4) | pll_div.n); in wm8510_set_dai_pll() 333 snd_soc_component_write(component, WM8510_PLLK1, pll_div.k >> 18); in wm8510_set_dai_pll() 334 snd_soc_component_write(component, WM8510_PLLK2, (pll_div.k >> 9) & 0x1ff); in wm8510_set_dai_pll() 335 snd_soc_component_write(component, WM8510_PLLK3, pll_div.k & 0x1ff); in wm8510_set_dai_pll()
|
D | wm8983.c | 743 struct pll_div { struct 750 static int pll_factors(struct pll_div *pll_div, unsigned int target, in pll_factors() argument 756 pll_div->div2 = 0; in pll_factors() 760 pll_div->div2 = 1; in pll_factors() 769 pll_div->n = Ndiv; in pll_factors() 780 pll_div->k = K; in pll_factors() 790 struct pll_div pll_div; in wm8983_set_pll() local 799 ret = pll_factors(&pll_div, freq_out * 4 * 2, freq_in); in wm8983_set_pll() 809 (pll_div.div2 << WM8983_PLL_PRESCALE_SHIFT) in wm8983_set_pll() 810 | pll_div.n); in wm8983_set_pll() [all …]
|
D | wm8985.c | 840 struct pll_div { struct 847 static int pll_factors(struct pll_div *pll_div, unsigned int target, in pll_factors() argument 853 pll_div->div2 = 0; in pll_factors() 857 pll_div->div2 = 1; in pll_factors() 866 pll_div->n = Ndiv; in pll_factors() 877 pll_div->k = K; in pll_factors() 888 struct pll_div pll_div; in wm8985_set_pll() local 896 ret = pll_factors(&pll_div, freq_out * 4 * 2, freq_in); in wm8985_set_pll() 902 (pll_div.div2 << WM8985_PLL_PRESCALE_SHIFT) in wm8985_set_pll() 903 | pll_div.n); in wm8985_set_pll() [all …]
|
D | wm8960.c | 1164 struct _pll_div *pll_div) in pll_factors() argument 1177 pll_div->pre_div = 1; in pll_factors() 1180 pll_div->pre_div = 0; in pll_factors() 1187 pll_div->n = Ndiv; in pll_factors() 1202 pll_div->k = K; in pll_factors() 1205 pll_div->n, pll_div->k, pll_div->pre_div); in pll_factors() 1214 static struct _pll_div pll_div; in wm8960_set_pll() local 1218 ret = pll_factors(freq_in, freq_out, &pll_div); in wm8960_set_pll() 1232 reg |= pll_div.pre_div << 4; in wm8960_set_pll() 1233 reg |= pll_div.n; in wm8960_set_pll() [all …]
|
D | wm8990.c | 806 static void pll_factors(struct _pll_div *pll_div, unsigned int target, in pll_factors() argument 816 pll_div->div2 = 1; in pll_factors() 819 pll_div->div2 = 0; in pll_factors() 825 pll_div->n = Ndiv; in pll_factors() 840 pll_div->k = K; in pll_factors() 847 struct _pll_div pll_div; in wm8990_set_dai_pll() local 850 pll_factors(&pll_div, freq_out * 4, freq_in); in wm8990_set_dai_pll() 861 snd_soc_component_write(component, WM8990_PLL1, pll_div.n | WM8990_SDM | in wm8990_set_dai_pll() 862 (pll_div.div2?WM8990_PRESCALE:0)); in wm8990_set_dai_pll() 863 snd_soc_component_write(component, WM8990_PLL2, (u8)(pll_div.k>>8)); in wm8990_set_dai_pll() [all …]
|
D | wm8991.c | 877 static void pll_factors(struct _pll_div *pll_div, unsigned int target, in pll_factors() argument 887 pll_div->div2 = 1; in pll_factors() 890 pll_div->div2 = 0; in pll_factors() 896 pll_div->n = Ndiv; in pll_factors() 911 pll_div->k = K; in pll_factors() 919 struct _pll_div pll_div; in wm8991_set_dai_pll() local 922 pll_factors(&pll_div, freq_out * 4, freq_in); in wm8991_set_dai_pll() 934 snd_soc_component_write(component, WM8991_PLL1, pll_div.n | WM8991_SDM | in wm8991_set_dai_pll() 935 (pll_div.div2 ? WM8991_PRESCALE : 0)); in wm8991_set_dai_pll() 936 snd_soc_component_write(component, WM8991_PLL2, (u8)(pll_div.k>>8)); in wm8991_set_dai_pll() [all …]
|
D | wm8753.c | 702 static void pll_factors(struct _pll_div *pll_div, unsigned int target, in pll_factors() argument 711 pll_div->div2 = 1; in pll_factors() 714 pll_div->div2 = 0; in pll_factors() 720 pll_div->n = Ndiv; in pll_factors() 735 pll_div->k = K; in pll_factors() 765 struct _pll_div pll_div; in wm8753_set_dai_pll() local 767 pll_factors(&pll_div, freq_out * 8, freq_in); in wm8753_set_dai_pll() 771 value = (pll_div.n << 5) + ((pll_div.k & 0x3c0000) >> 18); in wm8753_set_dai_pll() 775 value = (pll_div.k & 0x03fe00) >> 9; in wm8753_set_dai_pll() 779 value = pll_div.k & 0x0001ff; in wm8753_set_dai_pll() [all …]
|
D | alc5632.c | 682 int gbl_clk = 0, pll_div = 0; in alc5632_set_dai_pll() local 710 pll_div = codec_master_pll_div[i].regvalue; in alc5632_set_dai_pll() 721 pll_div = codec_slave_pll_div[i].regvalue; in alc5632_set_dai_pll() 732 pll_div = codec_slave_pll_div[i].regvalue; in alc5632_set_dai_pll() 741 if (!pll_div) in alc5632_set_dai_pll() 747 snd_soc_component_write(component, ALC5632_PLL1_CTRL, pll_div); in alc5632_set_dai_pll()
|
D | alc5623.c | 525 int gbl_clk = 0, pll_div = 0; in alc5623_set_dai_pll() local 550 pll_div = codec_master_pll_div[i].regvalue; in alc5623_set_dai_pll() 561 pll_div = codec_slave_pll_div[i].regvalue; in alc5623_set_dai_pll() 570 if (!pll_div) in alc5623_set_dai_pll() 574 snd_soc_component_write(component, ALC5623_PLL_CTRL, pll_div); in alc5623_set_dai_pll()
|
D | rt5631.c | 1217 struct pll_div { struct 1223 static const struct pll_div codec_master_pll_div[] = { argument 1260 static const struct pll_div codec_slave_pll_div[] = {
|
D | da7210.c | 211 struct pll_div { struct 221 static const struct pll_div da7210_pll_div[] = { argument
|
D | da9055.c | 239 struct pll_div { struct 249 static const struct pll_div da9055_pll_div[] = { argument
|
/linux-6.6.21/drivers/clk/imx/ |
D | clk-fracn-gppll.c | 155 u32 pll_numerator, pll_denominator, pll_div; in clk_fracn_gppll_recalc_rate() local 167 pll_div = readl_relaxed(pll->base + PLL_DIV); in clk_fracn_gppll_recalc_rate() 168 mfi = FIELD_GET(PLL_MFI_MASK, pll_div); in clk_fracn_gppll_recalc_rate() 170 rdiv = FIELD_GET(PLL_RDIV_MASK, pll_div); in clk_fracn_gppll_recalc_rate() 171 odiv = FIELD_GET(PLL_ODIV_MASK, pll_div); in clk_fracn_gppll_recalc_rate() 229 u32 tmp, pll_div, ana_mfn; in clk_fracn_gppll_set_rate() local 252 pll_div = FIELD_PREP(PLL_RDIV_MASK, rate->rdiv) | rate->odiv | in clk_fracn_gppll_set_rate() 254 writel_relaxed(pll_div, pll->base + PLL_DIV); in clk_fracn_gppll_set_rate()
|
D | clk-pll14xx.c | 265 u32 pll_div) in clk_pll14xx_mp_change() argument 269 old_mdiv = FIELD_GET(MDIV_MASK, pll_div); in clk_pll14xx_mp_change() 270 old_pdiv = FIELD_GET(PDIV_MASK, pll_div); in clk_pll14xx_mp_change()
|
/linux-6.6.21/drivers/clk/meson/ |
D | vid-pll-div.c | 79 struct meson_vid_pll_div_data *pll_div = meson_vid_pll_div_data(clk); in meson_vid_pll_div_recalc_rate() local 82 div = _get_table_val(meson_parm_read(clk->map, &pll_div->val), in meson_vid_pll_div_recalc_rate() 83 meson_parm_read(clk->map, &pll_div->sel)); in meson_vid_pll_div_recalc_rate()
|
/linux-6.6.21/drivers/gpu/drm/i915/display/ |
D | vlv_dsi_pll.c | 123 u32 pll_ctl, pll_div; in vlv_dsi_pclk() local 129 pll_div = config->dsi_pll.div; in vlv_dsi_pclk() 136 n = (pll_div & DSI_PLL_N1_DIV_MASK) >> DSI_PLL_N1_DIV_SHIFT; in vlv_dsi_pclk() 140 pll_div &= DSI_PLL_M1_DIV_MASK; in vlv_dsi_pclk() 141 pll_div = pll_div >> DSI_PLL_M1_DIV_SHIFT; in vlv_dsi_pclk() 155 if (lfsr_converts[i] == pll_div) in vlv_dsi_pclk() 324 u32 pll_ctl, pll_div; in vlv_dsi_get_pclk() local 330 pll_div = vlv_cck_read(dev_priv, CCK_REG_DSI_PLL_DIVIDER); in vlv_dsi_get_pclk() 334 config->dsi_pll.div = pll_div; in vlv_dsi_get_pclk()
|
/linux-6.6.21/drivers/clk/ |
D | clk-stm32f4.c | 720 struct stm32f4_pll_div *pll_div = to_pll_div_clk(div); in stm32f4_pll_div_set_rate() local 722 pll_state = stm32f4_pll_is_enabled(pll_div->hw_pll); in stm32f4_pll_div_set_rate() 725 stm32f4_pll_disable(pll_div->hw_pll); in stm32f4_pll_div_set_rate() 730 stm32f4_pll_enable(pll_div->hw_pll); in stm32f4_pll_div_set_rate() 747 struct stm32f4_pll_div *pll_div; in clk_register_pll_div() local 753 pll_div = kzalloc(sizeof(*pll_div), GFP_KERNEL); in clk_register_pll_div() 754 if (!pll_div) in clk_register_pll_div() 764 pll_div->div.reg = reg; in clk_register_pll_div() 765 pll_div->div.shift = shift; in clk_register_pll_div() 766 pll_div->div.width = width; in clk_register_pll_div() [all …]
|
/linux-6.6.21/drivers/net/wireless/ath/ath9k/ |
D | ar9002_phy.c | 308 int pll_div = 0x2c; in ar9002_hw_compute_pll_control() local 314 pll_div = 0x50; in ar9002_hw_compute_pll_control() 316 pll_div = 0x28; in ar9002_hw_compute_pll_control() 321 pll |= SM(pll_div, AR_RTC_9160_PLL_DIV); in ar9002_hw_compute_pll_control()
|