Home
last modified time | relevance | path

Searched refs:num_clks (Results 1 – 25 of 149) sorted by relevance

123456

/kernel/linux/linux-5.10/drivers/clk/
Dclk-bulk.c15 static int __must_check of_clk_bulk_get(struct device_node *np, int num_clks, in of_clk_bulk_get() argument
21 for (i = 0; i < num_clks; i++) { in of_clk_bulk_get()
26 for (i = 0; i < num_clks; i++) { in of_clk_bulk_get()
50 int num_clks; in of_clk_bulk_get_all() local
53 num_clks = of_clk_get_parent_count(np); in of_clk_bulk_get_all()
54 if (!num_clks) in of_clk_bulk_get_all()
57 clk_bulk = kmalloc_array(num_clks, sizeof(*clk_bulk), GFP_KERNEL); in of_clk_bulk_get_all()
61 ret = of_clk_bulk_get(np, num_clks, clk_bulk); in of_clk_bulk_get_all()
69 return num_clks; in of_clk_bulk_get_all()
72 void clk_bulk_put(int num_clks, struct clk_bulk_data *clks) in clk_bulk_put() argument
[all …]
Dclk-devres.c45 int num_clks; member
52 clk_bulk_put(devres->num_clks, devres->clks); in devm_clk_bulk_release()
55 static int __devm_clk_bulk_get(struct device *dev, int num_clks, in __devm_clk_bulk_get() argument
67 ret = clk_bulk_get_optional(dev, num_clks, clks); in __devm_clk_bulk_get()
69 ret = clk_bulk_get(dev, num_clks, clks); in __devm_clk_bulk_get()
72 devres->num_clks = num_clks; in __devm_clk_bulk_get()
81 int __must_check devm_clk_bulk_get(struct device *dev, int num_clks, in devm_clk_bulk_get() argument
84 return __devm_clk_bulk_get(dev, num_clks, clks, false); in devm_clk_bulk_get()
88 int __must_check devm_clk_bulk_get_optional(struct device *dev, int num_clks, in devm_clk_bulk_get_optional() argument
91 return __devm_clk_bulk_get(dev, num_clks, clks, true); in devm_clk_bulk_get_optional()
[all …]
Dclk-max77686.c51 size_t num_clks; member
153 if (idx >= drv_data->num_clks) { in of_clk_max77686_get()
169 int i, ret, num_clks; in max77686_clk_probe() local
185 num_clks = MAX77686_CLKS_NUM; in max77686_clk_probe()
190 num_clks = MAX77802_CLKS_NUM; in max77686_clk_probe()
195 num_clks = MAX77620_CLKS_NUM; in max77686_clk_probe()
204 drv_data->num_clks = num_clks; in max77686_clk_probe()
205 drv_data->max_clk_data = devm_kcalloc(dev, num_clks, in max77686_clk_probe()
211 for (i = 0; i < num_clks; i++) { in max77686_clk_probe()
Dclk-bm1880.c526 int num_clks, in bm1880_clk_register_plls() argument
533 for (i = 0; i < num_clks; i++) { in bm1880_clk_register_plls()
556 int num_clks, in bm1880_clk_register_mux() argument
563 for (i = 0; i < num_clks; i++) { in bm1880_clk_register_mux()
691 int num_clks, in bm1880_clk_register_divs() argument
698 for (i = 0; i < num_clks; i++) { in bm1880_clk_register_divs()
722 int num_clks, in bm1880_clk_register_gate() argument
729 for (i = 0; i < num_clks; i++) { in bm1880_clk_register_gate()
845 int num_clks, in bm1880_clk_register_composites() argument
852 for (i = 0; i < num_clks; i++) { in bm1880_clk_register_composites()
[all …]
/kernel/linux/linux-5.10/include/linux/
Dclk.h233 int __must_check clk_bulk_prepare(int num_clks,
243 clk_bulk_prepare(int num_clks, const struct clk_bulk_data *clks) in clk_bulk_prepare() argument
261 void clk_bulk_unprepare(int num_clks, const struct clk_bulk_data *clks);
267 static inline void clk_bulk_unprepare(int num_clks, in clk_bulk_unprepare() argument
312 int __must_check clk_bulk_get(struct device *dev, int num_clks,
345 int __must_check clk_bulk_get_optional(struct device *dev, int num_clks,
359 int __must_check devm_clk_bulk_get(struct device *dev, int num_clks,
382 int __must_check devm_clk_bulk_get_optional(struct device *dev, int num_clks,
502 int __must_check clk_bulk_enable(int num_clks,
537 void clk_bulk_disable(int num_clks, const struct clk_bulk_data *clks);
[all …]
/kernel/linux/linux-5.10/drivers/usb/dwc3/
Ddwc3-exynos.c24 int num_clks; member
33 int num_clks; member
54 exynos->num_clks = driver_data->num_clks; in dwc3_exynos_probe()
60 for (i = 0; i < exynos->num_clks; i++) { in dwc3_exynos_probe()
69 for (i = 0; i < exynos->num_clks; i++) { in dwc3_exynos_probe()
122 for (i = exynos->num_clks - 1; i >= 0; i--) in dwc3_exynos_probe()
138 for (i = exynos->num_clks - 1; i >= 0; i--) in dwc3_exynos_remove()
152 .num_clks = 1,
158 .num_clks = 4,
164 .num_clks = 3,
[all …]
/kernel/linux/linux-5.10/drivers/clk/renesas/
Dclk-rz.c91 int num_clks; in rz_cpg_clocks_init() local
93 num_clks = of_property_count_strings(np, "clock-output-names"); in rz_cpg_clocks_init()
94 if (WARN(num_clks <= 0, "can't count CPG clocks\n")) in rz_cpg_clocks_init()
98 clks = kcalloc(num_clks, sizeof(*clks), GFP_KERNEL); in rz_cpg_clocks_init()
102 cpg->data.clk_num = num_clks; in rz_cpg_clocks_init()
106 for (i = 0; i < num_clks; ++i) { in rz_cpg_clocks_init()
Dclk-r8a7778.c83 int num_clks; in r8a7778_cpg_clocks_init() local
97 num_clks = of_property_count_strings(np, "clock-output-names"); in r8a7778_cpg_clocks_init()
98 if (num_clks < 0) { in r8a7778_cpg_clocks_init()
104 clks = kcalloc(num_clks, sizeof(*clks), GFP_KERNEL); in r8a7778_cpg_clocks_init()
115 cpg->data.clk_num = num_clks; in r8a7778_cpg_clocks_init()
121 for (i = 0; i < num_clks; ++i) { in r8a7778_cpg_clocks_init()
Dclk-r8a7779.c125 int num_clks; in r8a7779_cpg_clocks_init() local
131 num_clks = of_property_count_strings(np, "clock-output-names"); in r8a7779_cpg_clocks_init()
132 if (num_clks < 0) { in r8a7779_cpg_clocks_init()
149 cpg->data.clk_num = num_clks; in r8a7779_cpg_clocks_init()
154 for (i = 0; i < num_clks; ++i) { in r8a7779_cpg_clocks_init()
Dclk-r8a7740.c150 int num_clks; in r8a7740_cpg_clocks_init() local
155 num_clks = of_property_count_strings(np, "clock-output-names"); in r8a7740_cpg_clocks_init()
156 if (num_clks < 0) { in r8a7740_cpg_clocks_init()
162 clks = kcalloc(num_clks, sizeof(*clks), GFP_KERNEL); in r8a7740_cpg_clocks_init()
173 cpg->data.clk_num = num_clks; in r8a7740_cpg_clocks_init()
179 for (i = 0; i < num_clks; ++i) { in r8a7740_cpg_clocks_init()
Dclk-sh73a0.c167 int num_clks; in sh73a0_cpg_clocks_init() local
169 num_clks = of_property_count_strings(np, "clock-output-names"); in sh73a0_cpg_clocks_init()
170 if (num_clks < 0) { in sh73a0_cpg_clocks_init()
176 clks = kcalloc(num_clks, sizeof(*clks), GFP_KERNEL); in sh73a0_cpg_clocks_init()
187 cpg->data.clk_num = num_clks; in sh73a0_cpg_clocks_init()
198 for (i = 0; i < num_clks; ++i) { in sh73a0_cpg_clocks_init()
Dclk-r8a73a4.c194 int num_clks; in r8a73a4_cpg_clocks_init() local
196 num_clks = of_property_count_strings(np, "clock-output-names"); in r8a73a4_cpg_clocks_init()
197 if (num_clks < 0) { in r8a73a4_cpg_clocks_init()
203 clks = kcalloc(num_clks, sizeof(*clks), GFP_KERNEL); in r8a73a4_cpg_clocks_init()
214 cpg->data.clk_num = num_clks; in r8a73a4_cpg_clocks_init()
220 for (i = 0; i < num_clks; ++i) { in r8a73a4_cpg_clocks_init()
/kernel/linux/linux-5.10/sound/soc/qcom/
Dlpass-apq8016.c169 drvdata->clks = devm_kcalloc(dev, variant->num_clks, in apq8016_lpass_init()
173 drvdata->num_clks = variant->num_clks; in apq8016_lpass_init()
175 for (i = 0; i < drvdata->num_clks; i++) in apq8016_lpass_init()
178 ret = devm_clk_bulk_get(dev, drvdata->num_clks, drvdata->clks); in apq8016_lpass_init()
184 ret = clk_bulk_prepare_enable(drvdata->num_clks, drvdata->clks); in apq8016_lpass_init()
215 clk_bulk_disable_unprepare(drvdata->num_clks, drvdata->clks); in apq8016_lpass_init()
223 clk_bulk_disable_unprepare(drvdata->num_clks, drvdata->clks); in apq8016_lpass_exit()
273 .num_clks = 2,
Dlpass-sc7180.c130 drvdata->clks = devm_kcalloc(dev, variant->num_clks, in sc7180_lpass_init()
135 drvdata->num_clks = variant->num_clks; in sc7180_lpass_init()
137 for (i = 0; i < drvdata->num_clks; i++) in sc7180_lpass_init()
140 ret = devm_clk_bulk_get(dev, drvdata->num_clks, drvdata->clks); in sc7180_lpass_init()
146 ret = clk_bulk_prepare_enable(drvdata->num_clks, drvdata->clks); in sc7180_lpass_init()
159 clk_bulk_disable_unprepare(drvdata->num_clks, drvdata->clks); in sc7180_lpass_exit()
270 .num_clks = 3,
/kernel/linux/linux-5.10/drivers/remoteproc/
Dqcom_q6v5_adsp.c63 int num_clks; member
74 int num_clks; member
112 clk_bulk_disable_unprepare(adsp->num_clks, adsp->clks); in qcom_adsp_shutdown()
201 ret = clk_bulk_prepare_enable(adsp->num_clks, adsp->clks); in adsp_start()
242 clk_bulk_disable_unprepare(adsp->num_clks, adsp->clks); in adsp_start()
314 int num_clks = 0; in adsp_init_clock() local
326 num_clks++; in adsp_init_clock()
328 adsp->num_clks = num_clks; in adsp_init_clock()
329 adsp->clks = devm_kcalloc(adsp->dev, adsp->num_clks, in adsp_init_clock()
334 for (i = 0; i < adsp->num_clks; i++) in adsp_init_clock()
[all …]
/kernel/linux/linux-5.10/drivers/clk/keystone/
Dsyscon-clk.c98 int num_clks, i; in ti_syscon_gate_clk_probe() local
112 num_clks = 0; in ti_syscon_gate_clk_probe()
114 num_clks++; in ti_syscon_gate_clk_probe()
116 hw_data = devm_kzalloc(dev, struct_size(hw_data, hws, num_clks), in ti_syscon_gate_clk_probe()
121 hw_data->num = num_clks; in ti_syscon_gate_clk_probe()
123 for (i = 0; i < num_clks; i++) { in ti_syscon_gate_clk_probe()
Dsci-clk.c430 int num_clks = 0; in ti_sci_scan_clocks_from_fw() local
465 if (num_clks == max_clks) { in ti_sci_scan_clocks_from_fw()
484 clks[num_clks] = sci_clk; in ti_sci_scan_clocks_from_fw()
487 num_clks++; in ti_sci_scan_clocks_from_fw()
490 provider->clocks = devm_kmalloc_array(dev, num_clks, sizeof(sci_clk), in ti_sci_scan_clocks_from_fw()
495 memcpy(provider->clocks, clks, num_clks * sizeof(sci_clk)); in ti_sci_scan_clocks_from_fw()
497 provider->num_clocks = num_clks; in ti_sci_scan_clocks_from_fw()
524 int num_clks = 0; in ti_sci_scan_clocks_from_dt() local
570 num_clks++; in ti_sci_scan_clocks_from_dt()
606 num_clks++; in ti_sci_scan_clocks_from_dt()
[all …]
/kernel/linux/linux-5.10/drivers/gpu/drm/msm/dsi/pll/
Ddsi_pll.c79 struct clk **clks, u32 num_clks) in msm_dsi_pll_helper_unregister_clks() argument
83 if (!num_clks || !clks) in msm_dsi_pll_helper_unregister_clks()
87 clk_unregister(clks[--num_clks]); in msm_dsi_pll_helper_unregister_clks()
88 clks[num_clks] = NULL; in msm_dsi_pll_helper_unregister_clks()
89 } while (num_clks); in msm_dsi_pll_helper_unregister_clks()
/kernel/linux/linux-5.10/drivers/phy/rockchip/
Dphy-rockchip-dphy-rx0.c143 unsigned int num_clks; member
265 ret = clk_bulk_enable(priv->drv_data->num_clks, priv->clks); in rk_dphy_power_on()
279 clk_bulk_disable(priv->drv_data->num_clks, priv->clks); in rk_dphy_power_off()
287 return clk_bulk_prepare(priv->drv_data->num_clks, priv->clks); in rk_dphy_init()
294 clk_bulk_unprepare(priv->drv_data->num_clks, priv->clks); in rk_dphy_exit()
309 .num_clks = ARRAY_SIZE(rk3399_mipidphy_clks),
356 priv->clks = devm_kcalloc(&pdev->dev, drv_data->num_clks, in rk_dphy_probe()
360 for (i = 0; i < drv_data->num_clks; i++) in rk_dphy_probe()
362 ret = devm_clk_bulk_get(&pdev->dev, drv_data->num_clks, priv->clks); in rk_dphy_probe()
/kernel/linux/linux-5.10/drivers/nvmem/
Drockchip-otp.c61 int num_clks; member
142 ret = clk_bulk_prepare_enable(otp->num_clks, otp->clks); in rockchip_otp_read()
178 clk_bulk_disable_unprepare(otp->num_clks, otp->clks); in rockchip_otp_read()
233 otp->num_clks = ARRAY_SIZE(rockchip_otp_clocks); in rockchip_otp_probe()
234 otp->clks = devm_kcalloc(dev, otp->num_clks, in rockchip_otp_probe()
239 for (i = 0; i < otp->num_clks; ++i) in rockchip_otp_probe()
242 ret = devm_clk_bulk_get(dev, otp->num_clks, otp->clks); in rockchip_otp_probe()
/kernel/linux/linux-5.10/drivers/phy/qualcomm/
Dphy-qcom-usb-hs-28nm.c60 int num_clks; member
261 ret = clk_bulk_prepare_enable(priv->num_clks, priv->clks); in qcom_snps_hsphy_init()
278 clk_bulk_disable_unprepare(priv->num_clks, priv->clks); in qcom_snps_hsphy_init()
286 clk_bulk_disable_unprepare(priv->num_clks, priv->clks); in qcom_snps_hsphy_exit()
323 priv->num_clks = ARRAY_SIZE(qcom_snps_hsphy_clks); in qcom_snps_hsphy_probe()
324 priv->clks = devm_kcalloc(dev, priv->num_clks, sizeof(*priv->clks), in qcom_snps_hsphy_probe()
329 for (i = 0; i < priv->num_clks; i++) in qcom_snps_hsphy_probe()
332 ret = devm_clk_bulk_get(dev, priv->num_clks, priv->clks); in qcom_snps_hsphy_probe()
/kernel/linux/linux-5.10/drivers/clk/davinci/
Dpsc.c362 int num_clks, in __davinci_psc_register_clocks() argument
375 clks = kmalloc_array(num_clks, sizeof(*clks), GFP_KERNEL); in __davinci_psc_register_clocks()
382 psc->clk_data.clk_num = num_clks; in __davinci_psc_register_clocks()
388 for (i = 0; i < num_clks; i++) in __davinci_psc_register_clocks()
391 pm_domains = kcalloc(num_clks, sizeof(*pm_domains), GFP_KERNEL); in __davinci_psc_register_clocks()
398 psc->pm_data.num_domains = num_clks; in __davinci_psc_register_clocks()
435 psc->rcdev.nr_resets = num_clks; in __davinci_psc_register_clocks()
455 u8 num_clks, in davinci_psc_register_clocks() argument
460 psc = __davinci_psc_register_clocks(dev, info, num_clks, base); in davinci_psc_register_clocks()
480 u8 num_clks, in of_davinci_psc_clk_init() argument
[all …]
/kernel/linux/linux-5.10/drivers/clk/qcom/
Dclk-rpm.c152 size_t num_clks; member
159 size_t num_clks; member
496 .num_clks = ARRAY_SIZE(msm8660_clks),
543 .num_clks = ARRAY_SIZE(apq8064_clks),
577 .num_clks = ARRAY_SIZE(ipq806x_clks),
595 if (idx >= rcc->num_clks) { in qcom_rpm_clk_hw_get()
607 size_t num_clks, i; in rpm_clk_probe() local
623 num_clks = desc->num_clks; in rpm_clk_probe()
630 rcc->num_clks = num_clks; in rpm_clk_probe()
633 for (i = 0; i < num_clks; i++) { in rpm_clk_probe()
[all …]
/kernel/linux/linux-5.10/drivers/usb/cdns3/
Dcdns3-imx.c93 int num_clks; member
186 data->num_clks = ARRAY_SIZE(imx_cdns3_core_clks); in cdns_imx_probe()
192 ret = devm_clk_bulk_get(dev, data->num_clks, data->clks); in cdns_imx_probe()
196 ret = clk_bulk_prepare_enable(data->num_clks, data->clks); in cdns_imx_probe()
217 clk_bulk_disable_unprepare(data->num_clks, data->clks); in cdns_imx_probe()
348 return clk_bulk_prepare_enable(data->num_clks, data->clks); in cdns_imx_resume()
355 clk_bulk_disable_unprepare(data->num_clks, data->clks); in cdns_imx_suspend()
/kernel/linux/linux-5.10/drivers/soc/amlogic/
Dmeson-ee-pwrc.c304 int num_clks; member
353 if (pwrc_domain->num_clks) { in meson_ee_pwrc_off()
355 clk_bulk_disable_unprepare(pwrc_domain->num_clks, in meson_ee_pwrc_off()
394 return clk_bulk_prepare_enable(pwrc_domain->num_clks, in meson_ee_pwrc_on()
406 dom->num_clks = dom->desc.clk_names_count; in meson_ee_pwrc_init_domain()
421 if (dom->num_clks) { in meson_ee_pwrc_init_domain()
426 if (dom->num_clks != ret) { in meson_ee_pwrc_init_domain()
429 dom->num_clks = ret; in meson_ee_pwrc_init_domain()
448 if (dom->num_clks && dom->desc.get_power && !dom->desc.get_power(dom)) { in meson_ee_pwrc_init_domain()
449 ret = clk_bulk_prepare_enable(dom->num_clks, dom->clks); in meson_ee_pwrc_init_domain()

123456