/linux/drivers/gpu/drm/mgag200/ |
H A D | mgag200_g200.c | 83 long ref_clk = g200->ref_clk; in mgag200_g200_pixpllc_atomic_check() local 106 computed = ref_clk * (testn + 1) / (testm + 1); in mgag200_g200_pixpllc_atomic_check() 118 f_vco = ref_clk * n / m; in mgag200_g200_pixpllc_atomic_check() 300 g200->ref_clk = 14318; in mgag200_g200_interpret_bios() 306 g200->ref_clk = 14318; in mgag200_g200_interpret_bios() 315 g200->ref_clk = 14318; in mgag200_g200_interpret_bios() 333 g200->ref_clk = 27050; in mgag200_g200_init_refclk() 348 g200->pclk_min, g200->pclk_max, g200->ref_clk); in mgag200_g200_init_refclk()
|
/linux/drivers/clk/imx/ |
H A D | clk-pllv2.c | 81 long mfi, mfn, mfd, pdf, ref_clk; in __clk_pllv2_recalc_rate() local 94 ref_clk = 2 * parent_rate; in __clk_pllv2_recalc_rate() 96 ref_clk *= 2; in __clk_pllv2_recalc_rate() 98 ref_clk /= (pdf + 1); in __clk_pllv2_recalc_rate() 99 temp = (u64) ref_clk * abs(mfn); in __clk_pllv2_recalc_rate() 102 temp = (ref_clk * mfi) - temp; in __clk_pllv2_recalc_rate() 104 temp = (ref_clk * mfi) + temp; in __clk_pllv2_recalc_rate()
|
/linux/drivers/phy/samsung/ |
H A D | phy-samsung-usb2.c | 36 ret = clk_prepare_enable(drv->ref_clk); in samsung_usb2_phy_power_on() 50 clk_disable_unprepare(drv->ref_clk); in samsung_usb2_phy_power_on() 75 clk_disable_unprepare(drv->ref_clk); in samsung_usb2_phy_power_off() 199 drv->ref_clk = devm_clk_get(dev, "ref"); in samsung_usb2_phy_probe() 200 if (IS_ERR(drv->ref_clk)) { in samsung_usb2_phy_probe() 202 return PTR_ERR(drv->ref_clk); in samsung_usb2_phy_probe() 205 drv->ref_rate = clk_get_rate(drv->ref_clk); in samsung_usb2_phy_probe()
|
/linux/drivers/phy/hisilicon/ |
H A D | phy-hisi-inno-usb2.c | 52 struct clk *ref_clk; member 100 ret = clk_prepare_enable(priv->ref_clk); in hisi_inno_phy_init() 124 clk_disable_unprepare(priv->ref_clk); in hisi_inno_phy_exit() 154 priv->ref_clk = devm_clk_get(dev, NULL); in hisi_inno_phy_probe() 155 if (IS_ERR(priv->ref_clk)) in hisi_inno_phy_probe() 156 return PTR_ERR(priv->ref_clk); in hisi_inno_phy_probe()
|
H A D | phy-histb-combphy.c | 48 struct clk *ref_clk; member 121 ret = clk_prepare_enable(priv->ref_clk); in histb_combphy_init() 154 clk_disable_unprepare(priv->ref_clk); in histb_combphy_exit() 244 priv->ref_clk = devm_clk_get(dev, NULL); in histb_combphy_probe() 245 if (IS_ERR(priv->ref_clk)) { in histb_combphy_probe() 247 return PTR_ERR(priv->ref_clk); in histb_combphy_probe()
|
/linux/drivers/gpu/drm/msm/hdmi/ |
H A D | hdmi_phy_8996.c | 103 static inline u32 pll_get_cpctrl(u64 frac_start, unsigned long ref_clk, in pll_get_cpctrl() argument 107 return (11000000 / (ref_clk / 20)); in pll_get_cpctrl() 128 static inline u32 pll_get_integloop_gain(u64 frac_start, u64 bclk, u32 ref_clk, in pll_get_integloop_gain() argument 135 base = (64 * ref_clk) / HDMI_DEFAULT_REF_CLOCK; in pll_get_integloop_gain() 137 base = (1022 * ref_clk) / 100; in pll_get_integloop_gain() 144 static inline u32 pll_get_pll_cmp(u64 fdata, unsigned long ref_clk) in pll_get_pll_cmp() argument 147 u32 divisor = ref_clk * 10; in pll_get_pll_cmp() 157 static inline u64 pll_cmp_to_fdata(u32 pll_cmp, unsigned long ref_clk) in pll_cmp_to_fdata() argument 159 u64 fdata = ((u64)pll_cmp) * ref_clk * 10; in pll_cmp_to_fdata() 218 static int pll_calculate(unsigned long pix_clk, unsigned long ref_clk, in pll_calculate() argument [all …]
|
H A D | hdmi_phy_8998.c | 102 static inline u32 pll_get_cpctrl(u64 frac_start, unsigned long ref_clk, in pll_get_cpctrl() argument 127 static inline u32 pll_get_integloop_gain(u64 frac_start, u64 bclk, u32 ref_clk, in pll_get_integloop_gain() argument 143 static inline u32 pll_get_pll_cmp(u64 fdata, unsigned long ref_clk) in pll_get_pll_cmp() argument 146 u32 divisor = ref_clk * 10; in pll_get_pll_cmp() 282 static int pll_calculate(unsigned long pix_clk, unsigned long ref_clk, in pll_calculate() argument 307 pll_divisor = 4 * ref_clk; in pll_calculate() 317 cpctrl = pll_get_cpctrl(frac_start, ref_clk, false); in pll_calculate() 321 ref_clk, false); in pll_calculate() 326 pll_cmp = pll_get_pll_cmp(fdata, ref_clk); in pll_calculate()
|
/linux/drivers/phy/qualcomm/ |
H A D | phy-qcom-snps-eusb2.c | 128 struct clk *ref_clk; member 191 unsigned long ref_clk_freq = clk_get_rate(phy->ref_clk); in qcom_eusb2_ref_clk_init() 248 ret = clk_prepare_enable(phy->ref_clk); in qcom_snps_eusb2_hsphy_init() 339 clk_disable_unprepare(phy->ref_clk); in qcom_snps_eusb2_hsphy_init() 351 clk_disable_unprepare(phy->ref_clk); in qcom_snps_eusb2_hsphy_exit() 389 phy->ref_clk = devm_clk_get(dev, "ref"); in qcom_snps_eusb2_hsphy_probe() 390 if (IS_ERR(phy->ref_clk)) in qcom_snps_eusb2_hsphy_probe() 391 return dev_err_probe(dev, PTR_ERR(phy->ref_clk), in qcom_snps_eusb2_hsphy_probe()
|
H A D | phy-qcom-ipq806x-usb.c | 122 struct clk *ref_clk; member 262 ret = clk_prepare_enable(phy_dwc3->ref_clk); in qcom_ipq806x_usb_hs_phy_init() 295 clk_disable_unprepare(phy_dwc3->ref_clk); in qcom_ipq806x_usb_hs_phy_exit() 311 ret = clk_prepare_enable(phy_dwc3->ref_clk); in qcom_ipq806x_usb_ss_phy_init() 448 clk_disable_unprepare(phy_dwc3->ref_clk); in qcom_ipq806x_usb_ss_phy_exit() 509 phy_dwc3->ref_clk = devm_clk_get(phy_dwc3->dev, "ref"); in qcom_ipq806x_usb_phy_probe() 510 if (IS_ERR(phy_dwc3->ref_clk)) { in qcom_ipq806x_usb_phy_probe() 512 return PTR_ERR(phy_dwc3->ref_clk); in qcom_ipq806x_usb_phy_probe() 515 clk_set_rate(phy_dwc3->ref_clk, data->clk_rate); in qcom_ipq806x_usb_phy_probe()
|
H A D | phy-qcom-usb-hs.c | 32 struct clk *ref_clk; member 115 ret = clk_prepare_enable(uphy->ref_clk); in qcom_usb_hs_phy_power_on() 176 clk_disable_unprepare(uphy->ref_clk); in qcom_usb_hs_phy_power_on() 190 clk_disable_unprepare(uphy->ref_clk); in qcom_usb_hs_phy_power_off() 232 uphy->ref_clk = clk = devm_clk_get(&ulpi->dev, "ref"); in qcom_usb_hs_phy_probe()
|
H A D | phy-qcom-qusb2.c | 433 struct clk *ref_clk; member 665 clk_disable_unprepare(qphy->ref_clk); in qusb2_phy_runtime_suspend() 699 ret = clk_prepare_enable(qphy->ref_clk); in qusb2_phy_runtime_resume() 827 ret = clk_prepare_enable(qphy->ref_clk); in qusb2_phy_init() 863 clk_disable_unprepare(qphy->ref_clk); in qusb2_phy_init() 885 clk_disable_unprepare(qphy->ref_clk); in qusb2_phy_exit() 982 qphy->ref_clk = devm_clk_get(dev, "ref"); in qusb2_phy_probe() 983 if (IS_ERR(qphy->ref_clk)) in qusb2_phy_probe() 984 return dev_err_probe(dev, PTR_ERR(qphy->ref_clk), in qusb2_phy_probe()
|
/linux/drivers/phy/mediatek/ |
H A D | phy-mtk-mipi-dsi.c | 110 struct clk *ref_clk; in mtk_mipi_tx_probe() local 132 ref_clk = devm_clk_get(dev, NULL); in mtk_mipi_tx_probe() 133 if (IS_ERR(ref_clk)) in mtk_mipi_tx_probe() 134 return dev_err_probe(dev, PTR_ERR(ref_clk), in mtk_mipi_tx_probe() 151 ref_clk_name = __clk_get_name(ref_clk); in mtk_mipi_tx_probe()
|
H A D | phy-mtk-hdmi.c | 82 struct clk *ref_clk; in mtk_hdmi_phy_probe() local 101 ref_clk = devm_clk_get(dev, "pll_ref"); in mtk_hdmi_phy_probe() 102 if (IS_ERR(ref_clk)) in mtk_hdmi_phy_probe() 103 return dev_err_probe(dev, PTR_ERR(ref_clk), in mtk_hdmi_phy_probe() 106 ref_clk_name = __clk_get_name(ref_clk); in mtk_hdmi_phy_probe()
|
H A D | phy-mtk-xsphy.c | 87 struct clk *ref_clk; /* reference clock of anolog phy */ member 314 ret = clk_prepare_enable(inst->ref_clk); in mtk_phy_init() 330 clk_disable_unprepare(inst->ref_clk); in mtk_phy_init() 365 clk_disable_unprepare(inst->ref_clk); in mtk_phy_exit() 508 inst->ref_clk = devm_clk_get(&phy->dev, "ref"); in mtk_xsphy_probe() 509 if (IS_ERR(inst->ref_clk)) { in mtk_xsphy_probe() 511 return PTR_ERR(inst->ref_clk); in mtk_xsphy_probe()
|
/linux/drivers/rtc/ |
H A D | rtc-cadence.c | 82 struct clk *ref_clk; member 281 crtc->ref_clk = devm_clk_get(&pdev->dev, "ref_clk"); in cdns_rtc_probe() 282 if (IS_ERR(crtc->ref_clk)) { in cdns_rtc_probe() 283 ret = PTR_ERR(crtc->ref_clk); in cdns_rtc_probe() 302 ret = clk_prepare_enable(crtc->ref_clk); in cdns_rtc_probe() 309 ref_clk_freq = clk_get_rate(crtc->ref_clk); in cdns_rtc_probe() 349 clk_disable_unprepare(crtc->ref_clk); in cdns_rtc_probe() 365 clk_disable_unprepare(crtc->ref_clk); in cdns_rtc_remove()
|
/linux/drivers/gpu/drm/rockchip/ |
H A D | dw_hdmi-rockchip.c | 80 struct clk *ref_clk; member 210 hdmi->ref_clk = devm_clk_get_optional_enabled(hdmi->dev, "ref"); in rockchip_hdmi_parse_dt() 211 if (!hdmi->ref_clk) in rockchip_hdmi_parse_dt() 212 hdmi->ref_clk = devm_clk_get_optional_enabled(hdmi->dev, "vpll"); in rockchip_hdmi_parse_dt() 214 if (IS_ERR(hdmi->ref_clk)) { in rockchip_hdmi_parse_dt() 215 ret = PTR_ERR(hdmi->ref_clk); in rockchip_hdmi_parse_dt() 250 if (hdmi->ref_clk) { in dw_hdmi_rockchip_mode_valid() 251 int rpclk = clk_round_rate(hdmi->ref_clk, pclk); in dw_hdmi_rockchip_mode_valid() 285 clk_set_rate(hdmi->ref_clk, adj_mode->clock * 1000); in dw_hdmi_rockchip_encoder_mode_set()
|
/linux/drivers/phy/starfive/ |
H A D | phy-jh7110-dphy-rx.c | 65 struct clk *ref_clk; member 123 clk_set_rate(dphy->ref_clk, 49500000); in stf_dphy_power_on() 171 dphy->ref_clk = devm_clk_get(&pdev->dev, "ref"); in stf_dphy_probe() 172 if (IS_ERR(dphy->ref_clk)) in stf_dphy_probe() 173 return PTR_ERR(dphy->ref_clk); in stf_dphy_probe()
|
/linux/drivers/clk/ |
H A D | clk-moxart.c | 20 struct clk *ref_clk; in moxart_of_pll_clk_init() local 37 ref_clk = of_clk_get(node, 0); in moxart_of_pll_clk_init() 38 if (IS_ERR(ref_clk)) { in moxart_of_pll_clk_init()
|
H A D | clk-cs2000-cp.c | 106 struct clk *ref_clk; member 442 struct clk *clk_in, *ref_clk; in cs2000_clk_get() local 449 ref_clk = devm_clk_get(dev, "ref_clk"); in cs2000_clk_get() 451 if (IS_ERR(ref_clk)) in cs2000_clk_get() 455 priv->ref_clk = ref_clk; in cs2000_clk_get() 486 ref_clk_rate = clk_get_rate(priv->ref_clk); in cs2000_clk_register() 506 parent_names[REF_CLK] = __clk_get_name(priv->ref_clk); in cs2000_clk_register()
|
/linux/include/linux/platform_data/ |
H A D | net-cw1200.h | 13 u16 ref_clk; /* REQUIRED (in KHz) */ member 26 u16 ref_clk; /* REQUIRED (in KHz) */ member
|
/linux/drivers/phy/marvell/ |
H A D | phy-mvebu-a3700-comphy.c | 534 u32 mask, data, ref_clk; in mvebu_a3700_comphy_sata_power_on() local 561 ref_clk = REF_FREF_SEL_SERDES_40MHZ; in mvebu_a3700_comphy_sata_power_on() 563 ref_clk = REF_FREF_SEL_SERDES_25MHZ; in mvebu_a3700_comphy_sata_power_on() 565 data = ref_clk | COMPHY_MODE_SATA; in mvebu_a3700_comphy_sata_power_on() 823 u32 mask, data, cfg, ref_clk; in mvebu_a3700_comphy_usb3_power_on() local 901 ref_clk = REF_FREF_SEL_PCIE_USB3_40MHZ; in mvebu_a3700_comphy_usb3_power_on() 904 ref_clk = REF_FREF_SEL_PCIE_USB3_25MHZ; in mvebu_a3700_comphy_usb3_power_on() 909 PU_TX_INTP_BIT | PU_DFE_BIT | COMPHY_MODE_USB3 | ref_clk; in mvebu_a3700_comphy_usb3_power_on() 988 u32 mask, data, ref_clk; in mvebu_a3700_comphy_pcie_power_on() local 1034 ref_clk = REF_FREF_SEL_PCIE_USB3_40MHZ; in mvebu_a3700_comphy_pcie_power_on() [all …]
|
/linux/Documentation/devicetree/bindings/rtc/ |
H A D | cdns,rtc.txt | 12 - ref_clk: reference 1Hz or 100Hz clock, depending on IP configuration 20 clock-names = "pclk", "ref_clk";
|
/linux/Documentation/devicetree/bindings/spi/ |
H A D | jcore,spi.txt | 15 - clocks: If a phandle named "ref_clk" is present, SPI clock speed 33 clock-names = "ref_clk";
|
/linux/drivers/clk/baikal-t1/ |
H A D | ccu-pll.c | 64 static inline unsigned long ccu_pll_lock_delay_us(unsigned long ref_clk, in ccu_pll_lock_delay_us() argument 69 do_div(us, ref_clk); in ccu_pll_lock_delay_us() 74 static inline unsigned long ccu_pll_calc_freq(unsigned long ref_clk, in ccu_pll_calc_freq() argument 79 u64 tmp = ref_clk; in ccu_pll_calc_freq() 88 static int ccu_pll_reset(struct ccu_pll *pll, unsigned long ref_clk, in ccu_pll_reset() argument 94 ud = ccu_pll_lock_delay_us(ref_clk, nr); in ccu_pll_reset()
|
/linux/drivers/clk/tegra/ |
H A D | clk-dfll.c | 271 struct clk *ref_clk; member 394 ret = clk_enable(td->ref_clk); in tegra_dfll_runtime_resume() 403 clk_disable(td->ref_clk); in tegra_dfll_runtime_resume() 411 clk_disable(td->ref_clk); in tegra_dfll_runtime_resume() 430 clk_disable(td->ref_clk); in tegra_dfll_runtime_suspend() 1426 td->ref_clk = devm_clk_get(td->dev, "ref"); in dfll_init_clks() 1427 if (IS_ERR(td->ref_clk)) { in dfll_init_clks() 1429 return PTR_ERR(td->ref_clk); in dfll_init_clks() 1461 td->ref_rate = clk_get_rate(td->ref_clk); in dfll_init() 1471 ret = clk_prepare(td->ref_clk); in dfll_init() [all …]
|