Lines Matching full:clk_core
54 struct clk_core *core;
60 struct clk_core { struct
68 struct clk_core *parent; argument
75 struct clk_core *new_parent; argument
76 struct clk_core *new_child; argument
103 struct clk_core *core; argument
114 static int clk_pm_runtime_get(struct clk_core *core) in clk_pm_runtime_get()
122 static void clk_pm_runtime_put(struct clk_core *core) in clk_pm_runtime_put()
148 struct clk_core *core, *failed; in clk_pm_runtime_get_all()
193 struct clk_core *core; in clk_pm_runtime_put_all()
200 static void clk_pm_runtime_init(struct clk_core *core) in clk_pm_runtime_init()
282 static bool clk_core_rate_is_protected(struct clk_core *core) in clk_core_rate_is_protected()
287 static bool clk_core_is_prepared(struct clk_core *core) in clk_core_is_prepared()
306 static bool clk_core_is_enabled(struct clk_core *core) in clk_core_is_enabled()
386 static struct clk_core *__clk_lookup_subtree(const char *name, in __clk_lookup_subtree()
387 struct clk_core *core) in __clk_lookup_subtree()
389 struct clk_core *child; in __clk_lookup_subtree()
390 struct clk_core *ret; in __clk_lookup_subtree()
404 static struct clk_core *clk_core_lookup(const char *name) in clk_core_lookup()
406 struct clk_core *root_clk; in clk_core_lookup()
407 struct clk_core *ret; in clk_core_lookup()
449 * clk_core_get - Find the clk_core parent of a clk
482 * A valid clk_core pointer when the clk can be found in the provider.
484 static struct clk_core *clk_core_get(struct clk_core *core, u8 p_index) in clk_core_get()
515 static void clk_core_fill_parent_index(struct clk_core *core, u8 index) in clk_core_fill_parent_index()
518 struct clk_core *parent; in clk_core_fill_parent_index()
541 static struct clk_core *clk_core_get_parent_by_index(struct clk_core *core, in clk_core_get_parent_by_index()
556 struct clk_core *parent; in clk_hw_get_parent_by_index()
569 static unsigned long clk_core_get_rate_nolock(struct clk_core *core) in clk_core_get_rate_nolock()
591 static unsigned long clk_core_get_accuracy_no_lock(struct clk_core *core) in clk_core_get_accuracy_no_lock()
635 static void clk_core_init_rate_req(struct clk_core * const core,
639 static int clk_core_round_rate_nolock(struct clk_core *core,
642 static bool clk_core_has_parent(struct clk_core *core, const struct clk_core *parent) in clk_core_has_parent()
644 struct clk_core *tmp; in clk_core_has_parent()
664 clk_core_forward_rate_req(struct clk_core *core, in clk_core_forward_rate_req()
666 struct clk_core *parent, in clk_core_forward_rate_req()
686 struct clk_core *core = hw->core; in clk_core_determine_rate_no_reparent()
687 struct clk_core *parent = core->parent; in clk_core_determine_rate_no_reparent()
727 struct clk_core *core = hw->core, *parent, *best_parent = NULL; in clk_mux_determine_rate_flags()
782 struct clk_core *core = clk_core_lookup(name); in __clk_lookup()
787 static void clk_core_get_boundaries(struct clk_core *core, in clk_core_get_boundaries()
821 static bool clk_core_check_boundaries(struct clk_core *core, in clk_core_check_boundaries()
893 static void clk_core_rate_unprotect(struct clk_core *core) in clk_core_rate_unprotect()
910 static int clk_core_rate_nuke_protect(struct clk_core *core) in clk_core_rate_nuke_protect()
968 static void clk_core_rate_protect(struct clk_core *core) in clk_core_rate_protect()
981 static void clk_core_rate_restore_protect(struct clk_core *core, int count) in clk_core_rate_restore_protect()
1046 static void clk_core_unprepare(struct clk_core *core) in clk_core_unprepare()
1079 static void clk_core_unprepare_lock(struct clk_core *core) in clk_core_unprepare_lock()
1106 static int clk_core_prepare(struct clk_core *core) in clk_core_prepare()
1155 static int clk_core_prepare_lock(struct clk_core *core) in clk_core_prepare_lock()
1187 static void clk_core_disable(struct clk_core *core) in clk_core_disable()
1214 static void clk_core_disable_lock(struct clk_core *core) in clk_core_disable_lock()
1244 static int clk_core_enable(struct clk_core *core) in clk_core_enable()
1280 static int clk_core_enable_lock(struct clk_core *core) in clk_core_enable_lock()
1304 struct clk_core *core = hw->core; in clk_gate_restore_context()
1313 static int clk_core_save_context(struct clk_core *core) in clk_core_save_context()
1315 struct clk_core *child; in clk_core_save_context()
1330 static void clk_core_restore_context(struct clk_core *core) in clk_core_restore_context()
1332 struct clk_core *child; in clk_core_restore_context()
1350 struct clk_core *clk; in clk_save_context()
1377 struct clk_core *core; in clk_restore_context()
1430 static int clk_core_prepare_enable(struct clk_core *core) in clk_core_prepare_enable()
1445 static void clk_core_disable_unprepare(struct clk_core *core) in clk_core_disable_unprepare()
1451 static void __init clk_unprepare_unused_subtree(struct clk_core *core) in clk_unprepare_unused_subtree()
1453 struct clk_core *child; in clk_unprepare_unused_subtree()
1476 static void __init clk_disable_unused_subtree(struct clk_core *core) in clk_disable_unused_subtree()
1478 struct clk_core *child; in clk_disable_unused_subtree()
1527 struct clk_core *core; in clk_disable_unused()
1566 static int clk_core_determine_round_nolock(struct clk_core *core, in clk_core_determine_round_nolock()
1614 static void clk_core_init_rate_req(struct clk_core * const core, in clk_core_init_rate_req()
1618 struct clk_core *parent; in clk_core_init_rate_req()
1689 static bool clk_core_can_round(struct clk_core * const core) in clk_core_can_round()
1694 static int clk_core_round_rate_nolock(struct clk_core *core, in clk_core_round_rate_nolock()
1840 static int __clk_notify(struct clk_core *core, unsigned long msg, in __clk_notify()
1872 static void __clk_recalc_accuracies(struct clk_core *core) in __clk_recalc_accuracies()
1875 struct clk_core *child; in __clk_recalc_accuracies()
1892 static long clk_core_get_accuracy_recalc(struct clk_core *core) in clk_core_get_accuracy_recalc()
1924 static unsigned long clk_recalc(struct clk_core *core, in clk_recalc()
1949 static void __clk_recalc_rates(struct clk_core *core, bool update_req, in __clk_recalc_rates()
1954 struct clk_core *child; in __clk_recalc_rates()
1978 static unsigned long clk_core_get_rate_recalc(struct clk_core *core) in clk_core_get_rate_recalc()
2010 static int clk_fetch_parent_index(struct clk_core *core, in clk_fetch_parent_index()
2011 struct clk_core *parent) in clk_fetch_parent_index()
2074 static void clk_core_update_orphan_status(struct clk_core *core, bool is_orphan) in clk_core_update_orphan_status()
2076 struct clk_core *child; in clk_core_update_orphan_status()
2084 static void clk_reparent(struct clk_core *core, struct clk_core *new_parent) in clk_reparent()
2110 static struct clk_core *__clk_set_parent_before(struct clk_core *core, in __clk_set_parent_before()
2111 struct clk_core *parent) in __clk_set_parent_before()
2114 struct clk_core *old_parent = core->parent; in __clk_set_parent_before()
2156 static void __clk_set_parent_after(struct clk_core *core, in __clk_set_parent_after()
2157 struct clk_core *parent, in __clk_set_parent_after()
2158 struct clk_core *old_parent) in __clk_set_parent_after()
2176 static int __clk_set_parent(struct clk_core *core, struct clk_core *parent, in __clk_set_parent()
2181 struct clk_core *old_parent; in __clk_set_parent()
2222 static int __clk_speculate_rates(struct clk_core *core, in __clk_speculate_rates()
2225 struct clk_core *child; in __clk_speculate_rates()
2253 static void clk_calc_subtree(struct clk_core *core, unsigned long new_rate, in clk_calc_subtree()
2254 struct clk_core *new_parent, u8 p_index) in clk_calc_subtree()
2256 struct clk_core *child; in clk_calc_subtree()
2276 static struct clk_core *clk_calc_new_rates(struct clk_core *core, in clk_calc_new_rates()
2279 struct clk_core *top = core; in clk_calc_new_rates()
2280 struct clk_core *old_parent, *parent; in clk_calc_new_rates()
2363 static struct clk_core *clk_propagate_rate_change(struct clk_core *core, in clk_propagate_rate_change()
2366 struct clk_core *child, *tmp_clk, *fail_clk = NULL; in clk_propagate_rate_change()
2401 static void clk_change_rate(struct clk_core *core) in clk_change_rate()
2403 struct clk_core *child; in clk_change_rate()
2408 struct clk_core *old_parent; in clk_change_rate()
2409 struct clk_core *parent = NULL; in clk_change_rate()
2490 static unsigned long clk_core_req_round_rate_nolock(struct clk_core *core, in clk_core_req_round_rate_nolock()
2520 static int clk_core_set_rate_nolock(struct clk_core *core, in clk_core_set_rate_nolock()
2523 struct clk_core *top, *fail_clk; in clk_core_set_rate_nolock()
2815 static struct clk_core *__clk_init_parent(struct clk_core *core) in __clk_init_parent()
2825 static void clk_core_reparent(struct clk_core *core, in clk_core_reparent()
2826 struct clk_core *new_parent) in clk_core_reparent()
2861 static int clk_core_set_parent_nolock(struct clk_core *core, in clk_core_set_parent_nolock()
2862 struct clk_core *parent) in clk_core_set_parent_nolock()
2973 static int clk_core_set_phase_nolock(struct clk_core *core, int degrees) in clk_core_set_phase_nolock()
3046 static int clk_core_get_phase(struct clk_core *core) in clk_core_get_phase()
3084 static void clk_core_reset_duty_cycle_nolock(struct clk_core *core) in clk_core_reset_duty_cycle_nolock()
3091 static int clk_core_update_duty_cycle_parent_nolock(struct clk_core *core);
3093 static int clk_core_update_duty_cycle_nolock(struct clk_core *core) in clk_core_update_duty_cycle_nolock()
3118 static int clk_core_update_duty_cycle_parent_nolock(struct clk_core *core) in clk_core_update_duty_cycle_parent_nolock()
3133 static int clk_core_set_duty_cycle_parent_nolock(struct clk_core *core,
3136 static int clk_core_set_duty_cycle_nolock(struct clk_core *core, in clk_core_set_duty_cycle_nolock()
3160 static int clk_core_set_duty_cycle_parent_nolock(struct clk_core *core, in clk_core_set_duty_cycle_parent_nolock()
3216 static int clk_core_get_scaled_duty_cycle(struct clk_core *core, in clk_core_get_scaled_duty_cycle()
3257 * share the same struct clk_core object.
3291 static void clk_summary_show_one(struct seq_file *s, struct clk_core *c, in clk_summary_show_one()
3332 static void clk_summary_show_subtree(struct seq_file *s, struct clk_core *c, in clk_summary_show_subtree()
3335 struct clk_core *child; in clk_summary_show_subtree()
3345 struct clk_core *c; in clk_summary_show()
3370 static void clk_dump_one(struct seq_file *s, struct clk_core *c, int level) in clk_dump_one()
3393 static void clk_dump_subtree(struct seq_file *s, struct clk_core *c, int level) in clk_dump_subtree()
3395 struct clk_core *child; in clk_dump_subtree()
3409 struct clk_core *c; in clk_dump_show()
3448 struct clk_core *core = data; in clk_rate_set()
3462 struct clk_core *core = data; in clk_phase_set()
3477 struct clk_core *core = data; in clk_prepare_enable_set()
3490 struct clk_core *core = data; in clk_prepare_enable_get()
3509 struct clk_core *core = data; in clk_rate_get()
3522 struct clk_core *core = data; in clk_phase_get()
3552 struct clk_core *core = s->private; in clk_flags_show()
3571 static void possible_parent_show(struct seq_file *s, struct clk_core *core, in possible_parent_show()
3574 struct clk_core *parent; in possible_parent_show()
3610 struct clk_core *core = s->private; in possible_parents_show()
3624 struct clk_core *core = s->private; in current_parent_show()
3638 struct clk_core *core = s->private; in current_parent_write()
3639 struct clk_core *parent; in current_parent_write()
3671 struct clk_core *core = s->private; in clk_duty_cycle_show()
3682 struct clk_core *core = s->private; in clk_min_rate_show()
3696 struct clk_core *core = s->private; in clk_max_rate_show()
3708 static void clk_debug_create_one(struct clk_core *core, struct dentry *pdentry) in clk_debug_create_one()
3761 static void clk_debug_register(struct clk_core *core) in clk_debug_register()
3778 static void clk_debug_unregister(struct clk_core *core) in clk_debug_unregister()
3798 struct clk_core *core; in clk_debug_init()
3840 static inline void clk_debug_register(struct clk_core *core) { } in clk_debug_register()
3841 static inline void clk_debug_unregister(struct clk_core *core) in clk_debug_unregister()
3848 struct clk_core *orphan; in clk_core_reparent_orphans_nolock()
3856 struct clk_core *parent = __clk_init_parent(orphan); in clk_core_reparent_orphans_nolock()
3888 * __clk_core_init - initialize the data structures in a struct clk_core
3889 * @core: clk_core being initialized
3891 * Initializes the lists in struct clk_core, queries the hardware for the
3894 static int __clk_core_init(struct clk_core *core) in __clk_core_init()
3897 struct clk_core *parent; in __clk_core_init()
4093 * clk_core_link_consumer - Add a clk consumer to the list of consumers in a clk_core
4097 static void clk_core_link_consumer(struct clk_core *core, struct clk *clk) in clk_core_link_consumer()
4105 * clk_core_unlink_consumer - Remove a clk consumer from the list of consumers in a clk_core
4115 * alloc_clk - Allocate a clk consumer, but leave it unlinked to the clk_core
4122 static struct clk *alloc_clk(struct clk_core *core, const char *dev_id, in alloc_clk()
4143 * Note, this assumes the clk has been unlinked from the clk_core consumer
4153 * clk_hw_create_clk: Allocate and link a clk consumer to a clk_core given
4161 * consumers. It connects a consumer to the clk_core and clk_hw structures
4168 struct clk_core *core; in clk_hw_create_clk()
4227 static int clk_core_populate_parent_map(struct clk_core *core, in clk_core_populate_parent_map()
4241 * Avoid unnecessary string look-ups of clk_core's possible parents by in clk_core_populate_parent_map()
4242 * having a cache of names/clk_hw pointers to clk_core pointers. in clk_core_populate_parent_map()
4289 static void clk_core_free_parent_map(struct clk_core *core) in clk_core_free_parent_map()
4304 /* Free memory allocated for a struct clk_core */
4307 struct clk_core *core = container_of(ref, struct clk_core, ref); in __clk_release()
4324 struct clk_core *core; in __clk_register()
4520 static void clk_core_evict_parent_cache_subtree(struct clk_core *root, in clk_core_evict_parent_cache_subtree()
4521 const struct clk_core *target) in clk_core_evict_parent_cache_subtree()
4524 struct clk_core *child; in clk_core_evict_parent_cache_subtree()
4535 static void clk_core_evict_parent_cache(struct clk_core *core) in clk_core_evict_parent_cache()
4538 struct clk_core *root; in clk_core_evict_parent_cache()
4583 struct clk_core *child; in clk_unregister()