Home
last modified time | relevance | path

Searched full:freq_out (Results 1 – 25 of 81) sorted by relevance

1234

/openbmc/linux/sound/soc/codecs/
H A Dadau-utils.c15 int adau_calc_pll_cfg(unsigned int freq_in, unsigned int freq_out, in adau_calc_pll_cfg() argument
21 if (!freq_out) { in adau_calc_pll_cfg()
27 if (freq_out % freq_in != 0) { in adau_calc_pll_cfg()
30 r = freq_out / freq_in; in adau_calc_pll_cfg()
31 i = freq_out % freq_in; in adau_calc_pll_cfg()
37 r = freq_out / freq_in; in adau_calc_pll_cfg()
H A Drl6231.c133 * @freq_out: target clock which codec works on.
141 const unsigned int freq_out, struct rl6231_pll_code *pll_code) in rl6231_pll_calc() argument
147 unsigned int red_t = abs(freq_out - freq_in); in rl6231_pll_calc()
156 freq_out == pll_preset_table[i].pll_out) { in rl6231_pll_calc()
167 min_k = 80000000 / freq_out - 2; in rl6231_pll_calc()
168 max_k = 150000000 / freq_out - 2; in rl6231_pll_calc()
173 div_t = gcd(freq_in, freq_out); in rl6231_pll_calc()
177 f_out = freq_out / div; in rl6231_pll_calc()
H A Dwm8960.c53 unsigned int freq_in, unsigned int freq_out);
683 * - freq_out = sysclk * sysclk_divs
706 int sysclk, bclk, lrclk, freq_out; in wm8960_configure_pll() local
728 freq_out = sysclk * sysclk_divs[i]; in wm8960_configure_pll()
731 if (!is_pll_freq_available(freq_in, freq_out)) in wm8960_configure_pll()
739 return freq_out; in wm8960_configure_pll()
746 best_freq_out = freq_out; in wm8960_configure_pll()
757 int freq_out, freq_in; in wm8960_configure_clocking() local
790 freq_out = freq_in; in wm8960_configure_clocking()
792 freq_out = wm8960->sysclk; in wm8960_configure_clocking()
[all …]
H A Dak4375.c255 unsigned int freq_in, freq_out; in ak4375_hw_params() local
267 freq_out = AK4375_PLL_FREQ_OUT_122880000; in ak4375_hw_params()
269 freq_out = AK4375_PLL_FREQ_OUT_112896000; in ak4375_hw_params()
271 return snd_soc_dai_set_pll(dai, 0, 0, freq_in, freq_out); in ak4375_hw_params()
275 unsigned int freq_in, unsigned int freq_out) in ak4375_dai_set_pll() argument
327 mdiv = freq_out / mclk - 1; in ak4375_dai_set_pll()
332 mdiv = freq_out / mclk - 1; in ak4375_dai_set_pll()
350 plm = freq_out / freq_in - 1; in ak4375_dai_set_pll()
362 ak4375->rate, mclk, freq_in, freq_out, ak4375->pld, plm, mdiv, div); in ak4375_dai_set_pll()
H A Drt1019.c325 unsigned int freq_in, unsigned int freq_out) in rt1019_set_dai_pll() argument
332 if (!freq_in || !freq_out) { in rt1019_set_dai_pll()
340 freq_out == rt1019->pll_out) in rt1019_set_dai_pll()
359 ret = rl6231_pll_calc(freq_in, freq_out, &pll_code); in rt1019_set_dai_pll()
383 rt1019->pll_out = freq_out; in rt1019_set_dai_pll()
H A Dadav80x.c623 int source, unsigned int freq_in, unsigned int freq_out) in adav80x_set_pll() argument
640 if (!freq_out) in adav80x_set_pll()
656 if (freq_out > 12288000) { in adav80x_set_pll()
658 freq_out /= 2; in adav80x_set_pll()
661 /* freq_out = sample_rate * 256 */ in adav80x_set_pll()
662 switch (freq_out) { in adav80x_set_pll()
H A Dadau-utils.h5 int adau_calc_pll_cfg(unsigned int freq_in, unsigned int freq_out,
H A Drt1016.c455 unsigned int freq_out) in rt1016_set_component_pll() argument
461 if (!freq_in || !freq_out) { in rt1016_set_component_pll()
471 freq_out == rt1016->pll_out) in rt1016_set_component_pll()
490 ret = rl6231_pll_calc(freq_in, freq_out * 4, &pll_code); in rt1016_set_component_pll()
510 rt1016->pll_out = freq_out; in rt1016_set_component_pll()
H A Dwm8995.c1724 int freq_in, int freq_out) in wm8995_get_fll_config() argument
1729 pr_debug("FLL input=%dHz, output=%dHz\n", freq_in, freq_out); in wm8995_get_fll_config()
1744 while (freq_out * (fll->outdiv + 1) < 90000000) { in wm8995_get_fll_config()
1749 freq_out *= fll->outdiv + 1; in wm8995_get_fll_config()
1750 pr_debug("OUTDIV=%d, Fvco=%dHz\n", fll->outdiv, freq_out); in wm8995_get_fll_config()
1770 Ndiv = freq_out / freq_in; in wm8995_get_fll_config()
1773 Nmod = freq_out % freq_in; in wm8995_get_fll_config()
1796 unsigned int freq_out) in wm8995_set_fll() argument
1829 if (freq_out) in wm8995_set_fll()
1843 wm8995->fll[id].in == freq_in && wm8995->fll[id].out == freq_out) in wm8995_set_fll()
[all …]
H A Dnau8540.c595 /* Calculate the frequency of DCO (FDCO) given freq_out = 256 * Fs. in nau8540_calc_fll_param()
598 * FDCO = freq_out * 2 * mclk_src_scaling in nau8540_calc_fll_param()
663 /* freq_out must be 256*Fs in order to achieve the best performance */
665 unsigned int freq_in, unsigned int freq_out) in nau8540_set_pll() argument
697 freq_out, pll_id); in nau8540_set_pll()
699 fs = freq_out / 256; in nau8540_set_pll()
H A Dwm8900.c746 int fll_id, unsigned int freq_in, unsigned int freq_out) in wm8900_set_fll() argument
751 if (wm8900->fll_in == freq_in && wm8900->fll_out == freq_out) in wm8900_set_fll()
759 if (!freq_in || !freq_out) { in wm8900_set_fll()
765 wm8900->fll_out = freq_out; in wm8900_set_fll()
770 if (fll_factors(&fll_div, freq_in, freq_out) != 0) in wm8900_set_fll()
774 wm8900->fll_out = freq_out; in wm8900_set_fll()
810 int source, unsigned int freq_in, unsigned int freq_out) in wm8900_set_dai_pll() argument
812 return wm8900_set_fll(codec_dai->component, pll_id, freq_in, freq_out); in wm8900_set_dai_pll()
H A Drl6231.h29 const unsigned int freq_out, struct rl6231_pll_code *pll_code);
H A Dnau8822.c725 unsigned int freq_in, unsigned int freq_out) in nau8822_set_pll() argument
733 freq_out == pll_param->freq_out) in nau8822_set_pll()
736 if (freq_out == 0) { in nau8822_set_pll()
743 fs = freq_out / 256; in nau8822_set_pll()
780 pll_param->freq_out = freq_out; in nau8822_set_pll()
H A Drt1308.c617 unsigned int freq_out) in rt1308_set_component_pll() argument
624 freq_out == rt1308->pll_out) in rt1308_set_component_pll()
627 if (!freq_in || !freq_out) { in rt1308_set_component_pll()
663 ret = rl6231_pll_calc(freq_in, freq_out, &pll_code); in rt1308_set_component_pll()
680 rt1308->pll_out = freq_out; in rt1308_set_component_pll()
H A Dwm8400.c922 unsigned int freq_out) in wm8400_set_dai_pll() argument
930 if (freq_in == wm8400->fll_in && freq_out == wm8400->fll_out) in wm8400_set_dai_pll()
933 if (freq_out) { in wm8400_set_dai_pll()
934 ret = fll_factors(wm8400, &factors, freq_in, freq_out); in wm8400_set_dai_pll()
940 * freq_out is 0 before any of the uses. */ in wm8400_set_dai_pll()
944 wm8400->fll_out = freq_out; in wm8400_set_dai_pll()
956 if (!freq_out) in wm8400_set_dai_pll()
H A Dwm8580.c461 int source, unsigned int freq_in, unsigned int freq_out) in wm8580_set_dai_pll() argument
492 if (freq_in && freq_out) { in wm8580_set_dai_pll()
493 ret = pll_factors(&pll_div, freq_out, freq_in); in wm8580_set_dai_pll()
499 state->out = freq_out; in wm8580_set_dai_pll()
506 if (!freq_in || !freq_out) in wm8580_set_dai_pll()
H A Dwm8994.c2123 int freq_in, int freq_out) in wm8994_get_fll_config() argument
2128 pr_debug("FLL input=%dHz, output=%dHz\n", freq_in, freq_out); in wm8994_get_fll_config()
2143 while (freq_out * (fll->outdiv + 1) < 90000000) { in wm8994_get_fll_config()
2148 freq_out *= fll->outdiv + 1; in wm8994_get_fll_config()
2149 pr_debug("OUTDIV=%d, Fvco=%dHz\n", fll->outdiv, freq_out); in wm8994_get_fll_config()
2169 Ndiv = freq_out / freq_in; in wm8994_get_fll_config()
2172 Nmod = freq_out % freq_in; in wm8994_get_fll_config()
2195 gcd_fll = gcd(freq_out, freq_in); in wm8994_get_fll_config()
2197 fll->k = (freq_out - (freq_in * fll->n)) / gcd_fll; in wm8994_get_fll_config()
2206 unsigned int freq_in, unsigned int freq_out) in _wm8994_set_fll() argument
[all …]
H A Drt1015.c829 unsigned int freq_out) in rt1015_set_component_pll() argument
835 if (!freq_in || !freq_out) { in rt1015_set_component_pll()
845 freq_out == rt1015->pll_out) in rt1015_set_component_pll()
864 ret = rl6231_pll_calc(freq_in, freq_out, &pll_code); in rt1015_set_component_pll()
882 rt1015->pll_out = freq_out; in rt1015_set_component_pll()
H A Drt5682s.c2298 if (plla_table[i].freq_in == f_in && plla_table[i].freq_out == f_out) { in find_pll_inter_combination()
2306 if (pllb_table[i].freq_in == f_in && pllb_table[i].freq_out == f_out) { in find_pll_inter_combination()
2314 if (plla_table[i].freq_in == f_in && plla_table[i].freq_out == 3840000) { in find_pll_inter_combination()
2317 pllb_table[j].freq_out == f_out) { in find_pll_inter_combination()
2331 unsigned int freq_out) in rt5682s_set_component_pll() argument
2337 freq_out == rt5682s->pll_out[pll_id]) in rt5682s_set_component_pll()
2340 if (!freq_in || !freq_out) { in rt5682s_set_component_pll()
2363 rt5682s->pll_comb = find_pll_inter_combination(freq_in, freq_out, in rt5682s_set_component_pll()
2371 pll_id + 1, freq_in, freq_out, rt5682s->pll_comb); in rt5682s_set_component_pll()
2375 pll_id + 1, freq_in, freq_out, rt5682s->pll_comb); in rt5682s_set_component_pll()
[all …]
/openbmc/linux/drivers/mfd/
H A Dtwl6040.c369 unsigned int freq_in, unsigned int freq_out) in twl6040_set_pll() argument
389 if (twl6040->sysclk_rate != freq_out) { in twl6040_set_pll()
390 switch (freq_out) { in twl6040_set_pll()
399 "freq_out %d not supported\n", in twl6040_set_pll()
400 freq_out); in twl6040_set_pll()
436 if (freq_out != 19200000) { in twl6040_set_pll()
438 "freq_out %d not supported\n", freq_out); in twl6040_set_pll()
502 twl6040->sysclk_rate = freq_out; in twl6040_set_pll()
/openbmc/linux/sound/soc/intel/avs/boards/
H A Drt5682.c148 int pll_source, freq_in, freq_out; in avs_rt5682_hw_params() local
162 freq_out = params_rate(params) * 512; in avs_rt5682_hw_params()
164 ret = snd_soc_dai_set_pll(codec_dai, RT5682_PLL1, pll_source, freq_in, freq_out); in avs_rt5682_hw_params()
168 ret = snd_soc_dai_set_sysclk(codec_dai, RT5682_SCLK_S_PLL1, freq_out, SND_SOC_CLOCK_IN); in avs_rt5682_hw_params()
/openbmc/linux/drivers/gpu/drm/bridge/
H A Dchipone-icn6211.c256 unsigned int freq_p, freq_s, freq_out; in chipone_configure_pll() local
307 freq_out = (fin * m) / p; in chipone_configure_pll()
308 if (freq_out > 1000000000) in chipone_configure_pll()
312 freq_out /= BIT(s + 1); in chipone_configure_pll()
314 delta = abs(mode_clock - freq_out); in chipone_configure_pll()
/openbmc/linux/sound/soc/pxa/
H A Dmmp-sspa.c135 unsigned int freq_out) in mmp_sspa_set_dai_pll() argument
146 ret = clk_set_rate(sspa->sysclk, freq_out); in mmp_sspa_set_dai_pll()
151 ret = clk_set_rate(sspa->clk, freq_out); in mmp_sspa_set_dai_pll()
/openbmc/linux/Documentation/devicetree/bindings/sound/
H A Dnvidia,tegra186-asrc.yaml12 wide range of sample rate ratios (freq_in/freq_out) from 1:24 to 24:1.
/openbmc/linux/sound/soc/
H A Dsoc-dai.c97 * @freq_out: requested PLL output clock frequency in Hz
102 unsigned int freq_in, unsigned int freq_out) in snd_soc_dai_set_pll() argument
109 freq_in, freq_out); in snd_soc_dai_set_pll()
112 freq_in, freq_out); in snd_soc_dai_set_pll()

1234