Lines Matching +full:clk +full:- +full:phase +full:-
6 * SPDX-License-Identifier: GPL-2.0+
12 /* See clk.h for background documentation. */
14 #include <clk.h>
19 * struct clk_ops - The functions that a clock driver must implement.
23 * of_xlate - Translate a client's device-tree (OF) clock specifier.
29 * default implementation, which assumes #clock-cells = <1>, and that
32 * At present, the clock API solely supports device-tree. If this
40 int (*of_xlate)(struct clk *clock,
43 * request - Request a translated clock.
55 int (*request)(struct clk *clock);
57 * free - Free a previously requested clock.
64 int (*free)(struct clk *clock);
66 * get_rate() - Get current clock rate.
68 * @clk: The clock to query.
69 * @return clock rate in Hz, or -ve error code
71 ulong (*get_rate)(struct clk *clk);
73 * set_rate() - Set current clock rate.
75 * @clk: The clock to manipulate.
77 * @return new rate, or -ve error code.
79 ulong (*set_rate)(struct clk *clk, ulong rate);
81 * clk_get_phase() - Get the phase shift of a clock signal.
83 * @clk: The clock to manipulate.
84 * @return the phase shift of a clock node in degrees,
85 * otherwise returns -ve error code.
87 int (*get_phase)(struct clk *clk);
90 * clk_set_rate() - Adjust the phase shift of a clock signal.
92 * @clk: The clock to manipulate.
94 * @return 0 on success, or -ve error code.
96 int (*set_phase)(struct clk *clk, int degrees);
98 * set_parent() - Set current clock parent
100 * @clk: The clock to manipulate.
102 * @return zero on success, or -ve error code.
104 int (*set_parent)(struct clk *clk, struct clk *parent);
106 * enable() - Enable a clock.
108 * @clk: The clock to manipulate.
109 * @return zero on success, or -ve error code.
111 int (*enable)(struct clk *clk);
113 * disable() - Disable a clock.
115 * @clk: The clock to manipulate.
116 * @return zero on success, or -ve error code.
118 int (*disable)(struct clk *clk);