Home
last modified time | relevance | path

Searched refs:clkin (Results 1 – 25 of 30) sorted by relevance

12

/drivers/iio/filter/
Dadmv8818.c87 struct clk *clkin; member
246 st->cf_hz = clk_get_rate(st->clkin); in admv8818_rfin_band_select()
444 if (!st->clkin) { in admv8818_set_mode()
464 ret = clk_prepare_enable(st->clkin); in admv8818_set_mode()
468 ret = clk_notifier_register(st->clkin, &st->nb); in admv8818_set_mode()
470 clk_disable_unprepare(st->clkin); in admv8818_set_mode()
479 clk_disable_unprepare(st->clkin); in admv8818_set_mode()
481 ret = clk_notifier_unregister(st->clkin, &st->nb); in admv8818_set_mode()
560 clk_notifier_unregister(st->clkin, &st->nb); in admv8818_clk_notifier_unreg()
568 clk_disable_unprepare(st->clkin); in admv8818_clk_disable()
[all …]
/drivers/video/fbdev/omap2/omapfb/dss/
Dhdmi_pll.c46 unsigned long clkin; in hdmi_pll_compute() local
49 clkin = clk_get_rate(pll->pll.clkin); in hdmi_pll_compute()
51 DSSDBG("clkin %lu, target tmds %lu\n", clkin, target_tmds); in hdmi_pll_compute()
56 n = DIV_ROUND_UP(clkin, hw->fint_max); in hdmi_pll_compute()
57 fint = clkin / n; in hdmi_pll_compute()
186 pll->clkin = clk; in dsi_init_pll_data()
Dpll.c72 r = clk_prepare_enable(pll->clkin); in dss_pll_enable()
92 clk_disable_unprepare(pll->clkin); in dss_pll_enable()
103 clk_disable_unprepare(pll->clkin); in dss_pll_disable()
146 bool dss_pll_calc(const struct dss_pll *pll, unsigned long clkin, in dss_pll_calc() argument
162 n_start = max(DIV_ROUND_UP(clkin, fint_hw_max), 1ul); in dss_pll_calc()
163 n_stop = min((unsigned)(clkin / fint_hw_min), hw->n_max); in dss_pll_calc()
168 fint = clkin / n; in dss_pll_calc()
Ddpi.c222 unsigned long clkin; in dpi_dsi_clk_calc() local
233 clkin = clk_get_rate(ctx->pll->clkin); in dpi_dsi_clk_calc()
235 return dss_pll_calc(ctx->pll, clkin, in dpi_dsi_clk_calc()
Ddss.h152 struct clk *clkin; member
473 bool dss_pll_calc(const struct dss_pll *pll, unsigned long clkin,
Dvideo-pll.c173 pll->clkin = clk; in dss_video_pll_init()
/drivers/gpu/drm/omapdrm/dss/
Dpll.c127 r = clk_prepare_enable(pll->clkin); in dss_pll_enable()
147 clk_disable_unprepare(pll->clkin); in dss_pll_enable()
158 clk_disable_unprepare(pll->clkin); in dss_pll_disable()
205 bool dss_pll_calc_a(const struct dss_pll *pll, unsigned long clkin, in dss_pll_calc_a() argument
221 n_start = max(DIV_ROUND_UP(clkin, fint_hw_max), 1ul); in dss_pll_calc_a()
222 n_stop = min((unsigned)(clkin / fint_hw_min), hw->n_max); in dss_pll_calc_a()
236 fint = clkin / n; in dss_pll_calc_a()
272 bool dss_pll_calc_b(const struct dss_pll *pll, unsigned long clkin, in dss_pll_calc_b() argument
281 DSSDBG("clkin %lu, target clkout %lu\n", clkin, target_clkout); in dss_pll_calc_b()
284 n = DIV_ROUND_UP(clkin, hw->fint_max); in dss_pll_calc_b()
[all …]
Ddpi.c222 unsigned long clkin; in dpi_pll_clk_calc() local
228 clkin = clk_get_rate(dpi->pll->clkin); in dpi_pll_clk_calc()
239 return dss_pll_calc_a(ctx->dpi->pll, clkin, in dpi_pll_clk_calc()
243 dss_pll_calc_b(dpi->pll, clkin, pck, &ctx->pll_cinfo); in dpi_pll_clk_calc()
Ddss.h182 struct clk *clkin; member
533 bool dss_pll_calc_a(const struct dss_pll *pll, unsigned long clkin,
537 bool dss_pll_calc_b(const struct dss_pll *pll, unsigned long clkin,
Dhdmi_pll.c145 pll->clkin = clk; in hdmi_init_pll_data()
Dvideo-pll.c177 pll->clkin = clk; in dss_video_pll_init()
/drivers/iio/frequency/
Dadf4350.c39 unsigned long clkin; member
128 st->fpfd = (st->clkin * (pdata->ref_doubler_en ? 2 : 1)) / in adf4350_tune_r_cnt()
285 st->clkin = readin; in adf4350_write()
334 st->clkin = clk_get_rate(st->clk); in adf4350_read()
336 val = st->clkin; in adf4350_read()
501 if (!pdata->clkin) { in adf4350_probe()
533 st->clkin = clk_get_rate(clk); in adf4350_probe()
535 st->clkin = pdata->clkin; in adf4350_probe()
Dadmv1014.c121 struct clk *clkin; member
223 u64 rate = clk_get_rate(st->clkin); in admv1014_update_quad_filters()
625 ret = clk_prepare_enable(st->clkin); in admv1014_init()
629 ret = devm_add_action_or_reset(&spi->dev, admv1014_clk_disable, st->clkin); in admv1014_init()
634 ret = devm_clk_notifier_register(&spi->dev, st->clkin, &st->nb); in admv1014_init()
754 st->clkin = devm_clk_get(&spi->dev, "lo_in"); in admv1014_properties_parse()
755 if (IS_ERR(st->clkin)) in admv1014_properties_parse()
756 return dev_err_probe(&spi->dev, PTR_ERR(st->clkin), in admv1014_properties_parse()
Dadmv1013.c95 struct clk *clkin; member
329 u64 rate = clk_get_rate(st->clkin); in admv1013_update_quad_filters()
611 st->clkin = devm_clk_get_enabled(&spi->dev, "lo_in"); in admv1013_probe()
612 if (IS_ERR(st->clkin)) in admv1013_probe()
613 return dev_err_probe(&spi->dev, PTR_ERR(st->clkin), in admv1013_probe()
617 ret = devm_clk_notifier_register(&spi->dev, st->clkin, &st->nb); in admv1013_probe()
Dadf4377.c406 struct clk *clkin; member
517 clkin_freq = clk_get_rate(st->clkin); in adf4377_get_freq()
725 st->clkin_freq = clk_get_rate(st->clkin); in adf4377_init()
876 st->clkin = devm_clk_get_enabled(&spi->dev, "ref_in"); in adf4377_properties_parse()
877 if (IS_ERR(st->clkin)) in adf4377_properties_parse()
878 return dev_err_probe(&spi->dev, PTR_ERR(st->clkin), in adf4377_properties_parse()
959 ret = devm_clk_notifier_register(&spi->dev, st->clkin, &st->nb); in adf4377_probe()
Dadf4371.c160 struct clk *clkin; member
575 st->clkin = devm_clk_get_enabled(&spi->dev, "clkin"); in adf4371_probe()
576 if (IS_ERR(st->clkin)) in adf4371_probe()
577 return PTR_ERR(st->clkin); in adf4371_probe()
579 st->clkin_freq = clk_get_rate(st->clkin); in adf4371_probe()
Dadrf6780.c75 struct clk *clkin; member
470 st->clkin = devm_clk_get_enabled(&spi->dev, "lo_in"); in adrf6780_probe()
471 if (IS_ERR(st->clkin)) in adrf6780_probe()
472 return dev_err_probe(&spi->dev, PTR_ERR(st->clkin), in adrf6780_probe()
/drivers/i2c/busses/
Di2c-s3c2410.c795 static int s3c24xx_i2c_calcdivisor(unsigned long clkin, unsigned int wanted, in s3c24xx_i2c_calcdivisor() argument
798 unsigned int calc_divs = clkin / wanted; in s3c24xx_i2c_calcdivisor()
817 return clkin / (calc_divs * calc_div1); in s3c24xx_i2c_calcdivisor()
828 unsigned long clkin = clk_get_rate(i2c->clk); in s3c24xx_i2c_clockrate() local
834 i2c->clkrate = clkin; in s3c24xx_i2c_clockrate()
835 clkin /= 1000; /* clkin now in KHz */ in s3c24xx_i2c_clockrate()
843 freq = s3c24xx_i2c_calcdivisor(clkin, target_frequency, &div1, &divs); in s3c24xx_i2c_clockrate()
870 sda_delay = clkin * pdata->sda_delay; in s3c24xx_i2c_clockrate()
/drivers/clk/
Dclk-aspeed.c586 u32 val, div, clkin, hpll; in aspeed_ast2400_cc() local
600 clkin = 25000000; in aspeed_ast2400_cc()
603 clkin = 48000000; in aspeed_ast2400_cc()
606 clkin = 24000000; in aspeed_ast2400_cc()
609 hw = clk_hw_register_fixed_rate(NULL, "clkin", NULL, 0, clkin); in aspeed_ast2400_cc()
610 pr_debug("clkin @%u MHz\n", clkin / 1000000); in aspeed_ast2400_cc()
Dclk-cdce706.c82 struct cdce706_hw_data clkin[1]; member
312 struct clk *gp_clk = cdce->clkin_clk[cdce->clkin[0].parent]; in cdce706_divider_determine_rate()
505 cdce->clkin[0].parent = !!(clock & CDCE706_CLKIN_CLOCK_MASK); in cdce706_register_clkin()
508 ret = cdce706_register_hw(cdce, cdce->clkin, in cdce706_register_clkin()
509 ARRAY_SIZE(cdce->clkin), in cdce706_register_clkin()
Dclk-si5351.c59 struct clk_hw clkin; member
246 container_of(hw, struct si5351_driver_data, clkin); in si5351_clkin_prepare()
255 container_of(hw, struct si5351_driver_data, clkin); in si5351_clkin_unprepare()
269 container_of(hw, struct si5351_driver_data, clkin); in si5351_clkin_recalc_rate()
1518 drvdata->clkin.init = &init; in si5351_i2c_probe()
1519 ret = devm_clk_hw_register(&client->dev, &drvdata->clkin); in si5351_i2c_probe()
/drivers/media/i2c/
Dds90ub913.c70 struct clk *clkin; member
615 __clk_get_name(priv->clkin), 0, 1, 2); in ub913_register_clkout()
640 ref = clk_get_rate(priv->clkin) / 2; in ub913_i2c_master_init()
824 priv->clkin = devm_clk_get(dev, "clkin"); in ub913_probe()
825 if (IS_ERR(priv->clkin)) in ub913_probe()
826 return dev_err_probe(dev, PTR_ERR(priv->clkin), in ub913_probe()
Dds90ub953.c148 struct clk *clkin; member
857 return clk_get_rate(priv->clkin) * 80ull; in ub953_get_fc_rate()
1211 if (priv->mode == UB953_MODE_NONSYNC_EXT && !priv->clkin) in ub953_hw_init()
1330 priv->clkin = devm_clk_get_optional(dev, "clkin"); in ub953_probe()
1331 if (IS_ERR(priv->clkin)) { in ub953_probe()
1332 ret = PTR_ERR(priv->clkin); in ub953_probe()
/drivers/hwmon/
Dw83795.c281 static unsigned int pwm_freq_from_reg(u8 reg, u16 clkin) in pwm_freq_from_reg() argument
286 base_clock = clkin * 1000 / ((clkin == 48000) ? 384 : 256); in pwm_freq_from_reg()
292 static u8 pwm_freq_to_reg(unsigned long val, u16 clkin) in pwm_freq_to_reg() argument
306 base_clock = clkin * 1000 / ((clkin == 48000) ? 384 : 256); in pwm_freq_to_reg()
363 u16 clkin; /* CLKIN frequency in kHz */ member
843 val = pwm_freq_from_reg(data->pwm[index][nr], data->clkin); in show_pwm()
874 val = pwm_freq_to_reg(val, data->clkin); in store_pwm()
1859 static const u16 clkin[4] = { /* in kHz */ in w83795_init_client() local
1875 data->clkin = clkin[(config >> 3) & 0x3]; in w83795_init_client()
1876 dev_dbg(&client->dev, "clkin = %u kHz\n", data->clkin); in w83795_init_client()
/drivers/iio/adc/
Dmeson_saradc.c342 struct clk *clkin; member
752 clk_parents[0] = __clk_get_name(priv->clkin); in meson_sar_adc_clk_init()
1014 ret = clk_set_parent(priv->adc_sel_clk, priv->clkin); in meson_sar_adc_init()
1381 priv->clkin = devm_clk_get(dev, "clkin"); in meson_sar_adc_probe()
1382 if (IS_ERR(priv->clkin)) in meson_sar_adc_probe()
1383 return dev_err_probe(dev, PTR_ERR(priv->clkin), "failed to get clkin\n"); in meson_sar_adc_probe()

12