Lines Matching refs:sclk
304 struct clk_src *sclk = to_src(hw); in src_clk_enable() local
305 u32 enreg = sclk->group1 ? SRC_PCKEN1 : SRC_PCKEN0; in src_clk_enable()
306 u32 sreg = sclk->group1 ? SRC_PCKSR1 : SRC_PCKSR0; in src_clk_enable()
308 writel(sclk->clkbit, src_base + enreg); in src_clk_enable()
310 while (!(readl(src_base + sreg) & sclk->clkbit)) in src_clk_enable()
317 struct clk_src *sclk = to_src(hw); in src_clk_disable() local
318 u32 disreg = sclk->group1 ? SRC_PCKDIS1 : SRC_PCKDIS0; in src_clk_disable()
319 u32 sreg = sclk->group1 ? SRC_PCKSR1 : SRC_PCKSR0; in src_clk_disable()
321 writel(sclk->clkbit, src_base + disreg); in src_clk_disable()
323 while (readl(src_base + sreg) & sclk->clkbit) in src_clk_disable()
329 struct clk_src *sclk = to_src(hw); in src_clk_is_enabled() local
330 u32 sreg = sclk->group1 ? SRC_PCKSR1 : SRC_PCKSR0; in src_clk_is_enabled()
333 return !!(val & sclk->clkbit); in src_clk_is_enabled()
355 struct clk_src *sclk; in src_clk_register() local
358 sclk = kzalloc(sizeof(*sclk), GFP_KERNEL); in src_clk_register()
359 if (!sclk) { in src_clk_register()
373 sclk->hw.init = &init; in src_clk_register()
374 sclk->id = id; in src_clk_register()
375 sclk->group1 = (id > 31); in src_clk_register()
376 sclk->clkbit = BIT(id & 0x1f); in src_clk_register()
379 name, id, sclk->group1, sclk->clkbit); in src_clk_register()
381 ret = clk_hw_register(dev, &sclk->hw); in src_clk_register()
383 kfree(sclk); in src_clk_register()
387 return &sclk->hw; in src_clk_register()