|
@@ -98,6 +98,21 @@ int clk_get_by_index(struct udevice *dev, int index, struct clk *clk);
|
|
* @return 0 if OK, or a negative error code.
|
|
* @return 0 if OK, or a negative error code.
|
|
*/
|
|
*/
|
|
int clk_get_by_name(struct udevice *dev, const char *name, struct clk *clk);
|
|
int clk_get_by_name(struct udevice *dev, const char *name, struct clk *clk);
|
|
|
|
+
|
|
|
|
+/**
|
|
|
|
+ * clk_release_all() - Disable (turn off)/Free an array of previously
|
|
|
|
+ * requested clocks.
|
|
|
|
+ *
|
|
|
|
+ * For each clock contained in the clock array, this function will check if
|
|
|
|
+ * clock has been previously requested and then will disable and free it.
|
|
|
|
+ *
|
|
|
|
+ * @clk: A clock struct array that was previously successfully
|
|
|
|
+ * requested by clk_request/get_by_*().
|
|
|
|
+ * @count Number of clock contained in the array
|
|
|
|
+ * @return zero on success, or -ve error code.
|
|
|
|
+ */
|
|
|
|
+int clk_release_all(struct clk *clk, int count);
|
|
|
|
+
|
|
#else
|
|
#else
|
|
static inline int clk_get_by_index(struct udevice *dev, int index,
|
|
static inline int clk_get_by_index(struct udevice *dev, int index,
|
|
struct clk *clk)
|
|
struct clk *clk)
|
|
@@ -110,6 +125,12 @@ static inline int clk_get_by_name(struct udevice *dev, const char *name,
|
|
{
|
|
{
|
|
return -ENOSYS;
|
|
return -ENOSYS;
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+static inline int clk_release_all(struct clk *clk, int count)
|
|
|
|
+{
|
|
|
|
+ return -ENOSYS;
|
|
|
|
+}
|
|
|
|
+
|
|
#endif
|
|
#endif
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -174,20 +195,6 @@ int clk_enable(struct clk *clk);
|
|
*/
|
|
*/
|
|
int clk_disable(struct clk *clk);
|
|
int clk_disable(struct clk *clk);
|
|
|
|
|
|
-/**
|
|
|
|
- * clk_release_all() - Disable (turn off)/Free an array of previously
|
|
|
|
- * requested clocks.
|
|
|
|
- *
|
|
|
|
- * For each clock contained in the clock array, this function will check if
|
|
|
|
- * clock has been previously requested and then will disable and free it.
|
|
|
|
- *
|
|
|
|
- * @clk: A clock struct array that was previously successfully
|
|
|
|
- * requested by clk_request/get_by_*().
|
|
|
|
- * @count Number of clock contained in the array
|
|
|
|
- * @return zero on success, or -ve error code.
|
|
|
|
- */
|
|
|
|
-int clk_release_all(struct clk *clk, int count);
|
|
|
|
-
|
|
|
|
int soc_clk_dump(void);
|
|
int soc_clk_dump(void);
|
|
|
|
|
|
#endif
|
|
#endif
|