Lines Matching +full:signal +full:- +full:id
1 /* SPDX-License-Identifier: GPL-2.0-only */
7 * Copyright (C) 2011-2012 Linaro Ltd <mturquette@linaro.org>
24 * PRE_RATE_CHANGE - called immediately before the clk rate is changed,
35 * POST_RATE_CHANGE - called after the clk rate change has successfully
44 * struct clk_notifier - associate a clk with a notifier
61 * struct clk_notifier_data - rate data to pass to the notifier callback
66 * For a pre-notifier, old_rate is the clk's rate before this rate
68 * post-notifier, old_rate and new_rate are both set to the clk's
78 * struct clk_bulk_data - Data used for bulk clk operations.
80 * @id: clock consumer ID
88 const char *id; member
95 * clk_notifier_register: register a clock rate-change notifier callback
106 * clk_notifier_unregister: unregister a clock rate-change notifier callback
113 * clk_get_accuracy - obtain the clock accuracy in ppb (parts per billion)
123 * clk_set_phase - adjust the phase shift of a clock signal
124 * @clk: clock signal source
125 * @degrees: number of degrees the signal is shifted
127 * Shifts the phase of a clock signal by the specified degrees. Returns 0 on
128 * success, -EERROR otherwise.
133 * clk_get_phase - return the phase shift of a clock signal
134 * @clk: clock signal source
137 * -EERROR.
142 * clk_set_duty_cycle - adjust the duty cycle ratio of a clock signal
143 * @clk: clock signal source
147 * Adjust the duty cycle of a clock signal by the specified ratio. Returns 0 on
148 * success, -EERROR otherwise.
153 * clk_get_duty_cycle - return the duty cycle ratio of a clock signal
154 * @clk: clock signal source
158 * returns -EERROR.
163 * clk_is_match - check if two clk's point to the same hardware clock
180 return -ENOTSUPP; in clk_notifier_register()
186 return -ENOTSUPP; in clk_notifier_unregister()
191 return -ENOTSUPP; in clk_get_accuracy()
196 return -ENOTSUPP; in clk_set_phase()
201 return -ENOTSUPP; in clk_get_phase()
207 return -ENOTSUPP; in clk_set_duty_cycle()
224 * clk_prepare - prepare a clock source
251 * clk_unprepare - undo preparation of a clock source
276 * clk_get - lookup and obtain a reference to a clock producer.
278 * @id: clock consumer ID
282 * uses @dev and @id to determine the clock consumer, and thereby
283 * the clock producer. (IOW, @id may be identical strings, but
290 struct clk *clk_get(struct device *dev, const char *id);
293 * clk_bulk_get - lookup and obtain a number of references to clock producer.
304 * The implementation uses @dev and @clk_bulk_data.id to determine the
315 * clk_bulk_get_all - lookup and obtain all available references to clock
336 * clk_bulk_get_optional - lookup and obtain a number of references to clock producer
342 * In this case, instead of returning -ENOENT, the function returns 0 and
348 * devm_clk_bulk_get - managed get multiple clk consumers
362 * devm_clk_bulk_get_optional - managed get multiple optional consumer clocks
368 * producer. In this case, instead of returning -ENOENT, the function returns
374 * The implementation uses @dev and @clk_bulk_data.id to determine the
385 * devm_clk_bulk_get_all - managed get multiple clk consumers
402 * devm_clk_get - lookup and obtain a managed reference to a clock producer.
404 * @id: clock consumer ID
408 * uses @dev and @id to determine the clock consumer, and thereby
409 * the clock producer. (IOW, @id may be identical strings, but
419 struct clk *devm_clk_get(struct device *dev, const char *id);
422 * devm_clk_get_optional - lookup and obtain a managed reference to an optional
425 * @id: clock consumer ID
428 * In this case, instead of returning -ENOENT, the function returns NULL.
430 struct clk *devm_clk_get_optional(struct device *dev, const char *id);
433 * devm_get_clk_from_child - lookup and obtain a managed reference to a
437 * @con_id: clock consumer ID
449 * clk_rate_exclusive_get - get exclusivity over the rate control of a
467 * clk_rate_exclusive_put - release exclusivity over the rate control of a
482 * clk_enable - inform the system when the clock source should be running.
494 * clk_bulk_enable - inform the system when the set of clks should be running.
506 * clk_disable - inform the system when the clock source is no longer required.
522 * clk_bulk_disable - inform the system when the set of clks is no
540 * clk_get_rate - obtain the current clock rate (in Hz) for a clock source.
547 * clk_put - "free" the clock source
559 * clk_bulk_put - "free" the clock source
572 * clk_bulk_put_all - "free" all the clock source
585 * devm_clk_put - "free" a managed clock source
603 * clk_round_rate - adjust a rate to the exact rate a clock can provide
626 * clk_set_rate - set the clock rate for a clock source
630 * Updating the rate starts at the top-most affected clock and then
631 * walks the tree down to the bottom-most clock that needs updating.
638 * clk_set_rate_exclusive- set the clock rate and claim exclusivity over
655 * clk_has_parent - check if a clock is a possible parent for another
667 * clk_set_rate_range - set a rate range for a clock source
677 * clk_set_min_rate - set a minimum clock rate for a clock source
686 * clk_set_max_rate - set a maximum clock rate for a clock source
695 * clk_set_parent - set the parent clock source for this clock
704 * clk_get_parent - get the parent clock source for this clock
713 * clk_get_sys - get a clock based upon the device name
715 * @con_id: connection ID
730 * clk_save_context - save clock context for poweroff
739 * clk_restore_context - restore clock context after poweroff
748 static inline struct clk *clk_get(struct device *dev, const char *id) in clk_get() argument
771 static inline struct clk *devm_clk_get(struct device *dev, const char *id) in devm_clk_get() argument
777 const char *id) in devm_clk_get_optional() argument
905 /* clk_prepare_enable helps cases using clk_enable in non-atomic context. */
920 /* clk_disable_unprepare helps cases using clk_disable in non-atomic context. */
950 * clk_get_optional - lookup and obtain a reference to an optional clock
953 * @id: clock consumer ID
956 * this case, instead of returning -ENOENT, the function returns NULL.
958 static inline struct clk *clk_get_optional(struct device *dev, const char *id) in clk_get_optional() argument
960 struct clk *clk = clk_get(dev, id); in clk_get_optional()
962 if (clk == ERR_PTR(-ENOENT)) in clk_get_optional()
975 return ERR_PTR(-ENOENT); in of_clk_get()
980 return ERR_PTR(-ENOENT); in of_clk_get_by_name()
984 return ERR_PTR(-ENOENT); in of_clk_get_from_provider()