summaryrefslogtreecommitdiff
path: root/drivers/clk/imx/clk-imx8.h
diff options
context:
space:
mode:
authorPeng Fan <peng.fan@nxp.com>2019-03-05 02:32:33 +0000
committerStefano Babic <sbabic@denx.de>2019-04-25 17:03:25 +0200
commit98c63a78408e87fcbf0ea200c7a2306a76da9021 (patch)
tree3e3850358aef1bf8bd8f83ee39c21c227ee4ce40 /drivers/clk/imx/clk-imx8.h
parent7f50af6090507e79505846d80f76c8636903367c (diff)
clk: imx8: split code into common and soc specific part
To make it easy to add new clk driver for i.MX8, split the code into common part and SoC specific part. Make the get/set/enable non static and introduce a num_clks for soc_clk_dump, because the arrays are moved to clk-imx8qxp.c. Signed-off-by: Peng Fan <peng.fan@nxp.com>
Diffstat (limited to 'drivers/clk/imx/clk-imx8.h')
-rw-r--r--drivers/clk/imx/clk-imx8.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/drivers/clk/imx/clk-imx8.h b/drivers/clk/imx/clk-imx8.h
new file mode 100644
index 0000000000..68ad6755e8
--- /dev/null
+++ b/drivers/clk/imx/clk-imx8.h
@@ -0,0 +1,19 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
+/*
+ * Copyright 2018 NXP
+ * Peng Fan <peng.fan@nxp.com>
+ */
+
+struct imx8_clks {
+ ulong id;
+ const char *name;
+};
+
+#if CONFIG_IS_ENABLED(CMD_CLK)
+extern struct imx8_clks imx8_clk_names[];
+extern int num_clks;
+#endif
+
+ulong imx8_clk_get_rate(struct clk *clk);
+ulong imx8_clk_set_rate(struct clk *clk, unsigned long rate);
+int __imx8_clk_enable(struct clk *clk, bool enable);