Lines Matching full:pclk
53 * @pclk: PIT64B's peripheral clock
59 struct clk *pclk; member
138 clk_disable_unprepare(timer->pclk); in mchp_pit64b_suspend()
143 clk_prepare_enable(timer->pclk); in mchp_pit64b_resume()
249 * PIT64B timer may be fed by gclk or pclk. When gclk is used its rate has to
250 * be at least 3 times lower that pclk's rate. pclk rate is fixed, gclk rate
251 * could be changed via clock APIs. The chosen clock (pclk or gclk) could be
256 * requested rate. If PCLK/GCLK < 3 (condition requested by PIT64B hardware)
257 * then the function falls back on using PCLK as clock source for PIT64B timer
268 * | |-->pclk -->|-->| | +---------+ +-----+ |
275 * - gclk rate <= pclk rate/3
277 * - pclk rate is fixed (cannot be requested from PMC)
286 pclk_rate = clk_get_rate(timer->pclk); in mchp_pit64b_init_mode()
295 goto pclk; in mchp_pit64b_init_mode()
298 goto pclk; in mchp_pit64b_init_mode()
310 pclk: in mchp_pit64b_init_mode()
311 /* Check if requested rate could be obtained using PCLK. */ in mchp_pit64b_init_mode()
316 /* Use PCLK. */ in mchp_pit64b_init_mode()
328 timer->mode & MCHP_PIT64B_MR_SGCLK ? "gclk" : "pclk", best_pres, in mchp_pit64b_init_mode()
350 cs->timer.pclk = timer->pclk; in mchp_pit64b_init_clksrc()
391 ce->timer.pclk = timer->pclk; in mchp_pit64b_init_clkevt()
428 timer.pclk = of_clk_get_by_name(node, "pclk"); in mchp_pit64b_dt_init_timer()
429 if (IS_ERR(timer.pclk)) in mchp_pit64b_dt_init_timer()
430 return PTR_ERR(timer.pclk); in mchp_pit64b_dt_init_timer()
453 ret = clk_prepare_enable(timer.pclk); in mchp_pit64b_dt_init_timer()
464 clk_rate = clk_get_rate(timer.pclk); in mchp_pit64b_dt_init_timer()
482 clk_disable_unprepare(timer.pclk); in mchp_pit64b_dt_init_timer()