summaryrefslogtreecommitdiff
path: root/components/drivers/include
diff options
context:
space:
mode:
authorGuEe-GUI <[email protected]>2024-10-25 16:21:54 +0800
committerRbb666 <[email protected]>2024-11-20 11:08:28 +0800
commitb6dff44054335c80531ed1fe4e2ad49216582993 (patch)
treeea4a4b266a50849f6273ea849747175e24652768 /components/drivers/include
parentbdf4da8ee1b061e1888006e121046530425cdca4 (diff)
[DM/FIXUP] Fixup CLK
1. Default return OK when input NULL (if is not necessary in device). 2. Support object parse in OFW. 3. Support CLK depends fix auto. 4. Fixup rt_clk_array_prepare_enable and rt_clk_array_disable_unprepare. Signed-off-by: GuEe-GUI <[email protected]>
Diffstat (limited to 'components/drivers/include')
-rw-r--r--components/drivers/include/drivers/clk.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/components/drivers/include/drivers/clk.h b/components/drivers/include/drivers/clk.h
index 83662d7744..97491bf8be 100644
--- a/components/drivers/include/drivers/clk.h
+++ b/components/drivers/include/drivers/clk.h
@@ -16,6 +16,8 @@
#include <ref.h>
#include <drivers/ofw.h>
+#define RT_CLK_NODE_OBJ_NAME "CLKNP"
+
struct rt_clk_ops;
struct rt_reset_control_node;
@@ -37,6 +39,8 @@ struct rt_clk_node
* };
* We assume the 'N' is the max value of element in 'clock-indices' if OFW.
*/
+ struct rt_object rt_parent;
+
rt_list_t list;
rt_list_t children_nodes;
@@ -74,6 +78,8 @@ struct rt_clk
const char *con_id;
rt_ubase_t rate;
+ int prepare_count;
+ int enable_count;
void *fw_node;
void *priv;