18c2ecf20Sopenharmony_ci// SPDX-License-Identifier: GPL-2.0
28c2ecf20Sopenharmony_ci/*
38c2ecf20Sopenharmony_ci * Copyright (c) 2018, The Linux Foundation. All rights reserved.
48c2ecf20Sopenharmony_ci */
58c2ecf20Sopenharmony_ci
68c2ecf20Sopenharmony_ci#include <linux/clk-provider.h>
78c2ecf20Sopenharmony_ci#include <linux/module.h>
88c2ecf20Sopenharmony_ci#include <linux/platform_device.h>
98c2ecf20Sopenharmony_ci#include <linux/regmap.h>
108c2ecf20Sopenharmony_ci
118c2ecf20Sopenharmony_ci#include <dt-bindings/clock/qcom,camcc-sdm845.h>
128c2ecf20Sopenharmony_ci
138c2ecf20Sopenharmony_ci#include "common.h"
148c2ecf20Sopenharmony_ci#include "clk-alpha-pll.h"
158c2ecf20Sopenharmony_ci#include "clk-branch.h"
168c2ecf20Sopenharmony_ci#include "clk-rcg.h"
178c2ecf20Sopenharmony_ci#include "clk-regmap.h"
188c2ecf20Sopenharmony_ci#include "gdsc.h"
198c2ecf20Sopenharmony_ci
208c2ecf20Sopenharmony_cienum {
218c2ecf20Sopenharmony_ci	P_BI_TCXO,
228c2ecf20Sopenharmony_ci	P_CAM_CC_PLL0_OUT_EVEN,
238c2ecf20Sopenharmony_ci	P_CAM_CC_PLL1_OUT_EVEN,
248c2ecf20Sopenharmony_ci	P_CAM_CC_PLL2_OUT_EVEN,
258c2ecf20Sopenharmony_ci	P_CAM_CC_PLL3_OUT_EVEN,
268c2ecf20Sopenharmony_ci	P_CORE_BI_PLL_TEST_SE,
278c2ecf20Sopenharmony_ci};
288c2ecf20Sopenharmony_ci
298c2ecf20Sopenharmony_cistatic const struct parent_map cam_cc_parent_map_0[] = {
308c2ecf20Sopenharmony_ci	{ P_BI_TCXO, 0 },
318c2ecf20Sopenharmony_ci	{ P_CAM_CC_PLL2_OUT_EVEN, 1 },
328c2ecf20Sopenharmony_ci	{ P_CAM_CC_PLL1_OUT_EVEN, 2 },
338c2ecf20Sopenharmony_ci	{ P_CAM_CC_PLL3_OUT_EVEN, 5 },
348c2ecf20Sopenharmony_ci	{ P_CAM_CC_PLL0_OUT_EVEN, 6 },
358c2ecf20Sopenharmony_ci	{ P_CORE_BI_PLL_TEST_SE, 7 },
368c2ecf20Sopenharmony_ci};
378c2ecf20Sopenharmony_ci
388c2ecf20Sopenharmony_cistatic const char * const cam_cc_parent_names_0[] = {
398c2ecf20Sopenharmony_ci	"bi_tcxo",
408c2ecf20Sopenharmony_ci	"cam_cc_pll2_out_even",
418c2ecf20Sopenharmony_ci	"cam_cc_pll1_out_even",
428c2ecf20Sopenharmony_ci	"cam_cc_pll3_out_even",
438c2ecf20Sopenharmony_ci	"cam_cc_pll0_out_even",
448c2ecf20Sopenharmony_ci	"core_bi_pll_test_se",
458c2ecf20Sopenharmony_ci};
468c2ecf20Sopenharmony_ci
478c2ecf20Sopenharmony_cistatic struct clk_alpha_pll cam_cc_pll0 = {
488c2ecf20Sopenharmony_ci	.offset = 0x0,
498c2ecf20Sopenharmony_ci	.regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_FABIA],
508c2ecf20Sopenharmony_ci	.clkr = {
518c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
528c2ecf20Sopenharmony_ci			.name = "cam_cc_pll0",
538c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){ "bi_tcxo" },
548c2ecf20Sopenharmony_ci			.num_parents = 1,
558c2ecf20Sopenharmony_ci			.ops = &clk_alpha_pll_fabia_ops,
568c2ecf20Sopenharmony_ci		},
578c2ecf20Sopenharmony_ci	},
588c2ecf20Sopenharmony_ci};
598c2ecf20Sopenharmony_ci
608c2ecf20Sopenharmony_cistatic const struct clk_div_table post_div_table_fabia_even[] = {
618c2ecf20Sopenharmony_ci	{ 0x0, 1 },
628c2ecf20Sopenharmony_ci	{ 0x1, 2 },
638c2ecf20Sopenharmony_ci	{ }
648c2ecf20Sopenharmony_ci};
658c2ecf20Sopenharmony_ci
668c2ecf20Sopenharmony_cistatic struct clk_alpha_pll_postdiv cam_cc_pll0_out_even = {
678c2ecf20Sopenharmony_ci	.offset = 0x0,
688c2ecf20Sopenharmony_ci	.post_div_shift = 8,
698c2ecf20Sopenharmony_ci	.post_div_table = post_div_table_fabia_even,
708c2ecf20Sopenharmony_ci	.num_post_div = ARRAY_SIZE(post_div_table_fabia_even),
718c2ecf20Sopenharmony_ci	.width = 4,
728c2ecf20Sopenharmony_ci	.regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_FABIA],
738c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
748c2ecf20Sopenharmony_ci		.name = "cam_cc_pll0_out_even",
758c2ecf20Sopenharmony_ci		.parent_names = (const char *[]){ "cam_cc_pll0" },
768c2ecf20Sopenharmony_ci		.num_parents = 1,
778c2ecf20Sopenharmony_ci		.ops = &clk_alpha_pll_postdiv_fabia_ops,
788c2ecf20Sopenharmony_ci	},
798c2ecf20Sopenharmony_ci};
808c2ecf20Sopenharmony_ci
818c2ecf20Sopenharmony_cistatic struct clk_alpha_pll cam_cc_pll1 = {
828c2ecf20Sopenharmony_ci	.offset = 0x1000,
838c2ecf20Sopenharmony_ci	.regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_FABIA],
848c2ecf20Sopenharmony_ci	.clkr = {
858c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
868c2ecf20Sopenharmony_ci			.name = "cam_cc_pll1",
878c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){ "bi_tcxo" },
888c2ecf20Sopenharmony_ci			.num_parents = 1,
898c2ecf20Sopenharmony_ci			.ops = &clk_alpha_pll_fabia_ops,
908c2ecf20Sopenharmony_ci		},
918c2ecf20Sopenharmony_ci	},
928c2ecf20Sopenharmony_ci};
938c2ecf20Sopenharmony_ci
948c2ecf20Sopenharmony_cistatic struct clk_alpha_pll_postdiv cam_cc_pll1_out_even = {
958c2ecf20Sopenharmony_ci	.offset = 0x1000,
968c2ecf20Sopenharmony_ci	.post_div_shift = 8,
978c2ecf20Sopenharmony_ci	.post_div_table = post_div_table_fabia_even,
988c2ecf20Sopenharmony_ci	.num_post_div = ARRAY_SIZE(post_div_table_fabia_even),
998c2ecf20Sopenharmony_ci	.width = 4,
1008c2ecf20Sopenharmony_ci	.regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_FABIA],
1018c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
1028c2ecf20Sopenharmony_ci		.name = "cam_cc_pll1_out_even",
1038c2ecf20Sopenharmony_ci		.parent_names = (const char *[]){ "cam_cc_pll1" },
1048c2ecf20Sopenharmony_ci		.num_parents = 1,
1058c2ecf20Sopenharmony_ci		.ops = &clk_alpha_pll_postdiv_fabia_ops,
1068c2ecf20Sopenharmony_ci	},
1078c2ecf20Sopenharmony_ci};
1088c2ecf20Sopenharmony_ci
1098c2ecf20Sopenharmony_cistatic struct clk_alpha_pll cam_cc_pll2 = {
1108c2ecf20Sopenharmony_ci	.offset = 0x2000,
1118c2ecf20Sopenharmony_ci	.regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_FABIA],
1128c2ecf20Sopenharmony_ci	.clkr = {
1138c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
1148c2ecf20Sopenharmony_ci			.name = "cam_cc_pll2",
1158c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){ "bi_tcxo" },
1168c2ecf20Sopenharmony_ci			.num_parents = 1,
1178c2ecf20Sopenharmony_ci			.ops = &clk_alpha_pll_fabia_ops,
1188c2ecf20Sopenharmony_ci		},
1198c2ecf20Sopenharmony_ci	},
1208c2ecf20Sopenharmony_ci};
1218c2ecf20Sopenharmony_ci
1228c2ecf20Sopenharmony_cistatic struct clk_alpha_pll_postdiv cam_cc_pll2_out_even = {
1238c2ecf20Sopenharmony_ci	.offset = 0x2000,
1248c2ecf20Sopenharmony_ci	.post_div_shift = 8,
1258c2ecf20Sopenharmony_ci	.post_div_table = post_div_table_fabia_even,
1268c2ecf20Sopenharmony_ci	.num_post_div = ARRAY_SIZE(post_div_table_fabia_even),
1278c2ecf20Sopenharmony_ci	.width = 4,
1288c2ecf20Sopenharmony_ci	.regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_FABIA],
1298c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
1308c2ecf20Sopenharmony_ci		.name = "cam_cc_pll2_out_even",
1318c2ecf20Sopenharmony_ci		.parent_names = (const char *[]){ "cam_cc_pll2" },
1328c2ecf20Sopenharmony_ci		.num_parents = 1,
1338c2ecf20Sopenharmony_ci		.ops = &clk_alpha_pll_postdiv_fabia_ops,
1348c2ecf20Sopenharmony_ci	},
1358c2ecf20Sopenharmony_ci};
1368c2ecf20Sopenharmony_ci
1378c2ecf20Sopenharmony_cistatic struct clk_alpha_pll cam_cc_pll3 = {
1388c2ecf20Sopenharmony_ci	.offset = 0x3000,
1398c2ecf20Sopenharmony_ci	.regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_FABIA],
1408c2ecf20Sopenharmony_ci	.clkr = {
1418c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
1428c2ecf20Sopenharmony_ci			.name = "cam_cc_pll3",
1438c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){ "bi_tcxo" },
1448c2ecf20Sopenharmony_ci			.num_parents = 1,
1458c2ecf20Sopenharmony_ci			.ops = &clk_alpha_pll_fabia_ops,
1468c2ecf20Sopenharmony_ci		},
1478c2ecf20Sopenharmony_ci	},
1488c2ecf20Sopenharmony_ci};
1498c2ecf20Sopenharmony_ci
1508c2ecf20Sopenharmony_cistatic struct clk_alpha_pll_postdiv cam_cc_pll3_out_even = {
1518c2ecf20Sopenharmony_ci	.offset = 0x3000,
1528c2ecf20Sopenharmony_ci	.post_div_shift = 8,
1538c2ecf20Sopenharmony_ci	.post_div_table = post_div_table_fabia_even,
1548c2ecf20Sopenharmony_ci	.num_post_div = ARRAY_SIZE(post_div_table_fabia_even),
1558c2ecf20Sopenharmony_ci	.width = 4,
1568c2ecf20Sopenharmony_ci	.regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_FABIA],
1578c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
1588c2ecf20Sopenharmony_ci		.name = "cam_cc_pll3_out_even",
1598c2ecf20Sopenharmony_ci		.parent_names = (const char *[]){ "cam_cc_pll3" },
1608c2ecf20Sopenharmony_ci		.num_parents = 1,
1618c2ecf20Sopenharmony_ci		.ops = &clk_alpha_pll_postdiv_fabia_ops,
1628c2ecf20Sopenharmony_ci	},
1638c2ecf20Sopenharmony_ci};
1648c2ecf20Sopenharmony_ci
1658c2ecf20Sopenharmony_cistatic const struct freq_tbl ftbl_cam_cc_bps_clk_src[] = {
1668c2ecf20Sopenharmony_ci	F(19200000, P_BI_TCXO, 1, 0, 0),
1678c2ecf20Sopenharmony_ci	F(100000000, P_CAM_CC_PLL0_OUT_EVEN, 6, 0, 0),
1688c2ecf20Sopenharmony_ci	F(200000000, P_CAM_CC_PLL0_OUT_EVEN, 3, 0, 0),
1698c2ecf20Sopenharmony_ci	F(404000000, P_CAM_CC_PLL1_OUT_EVEN, 2, 0, 0),
1708c2ecf20Sopenharmony_ci	F(480000000, P_CAM_CC_PLL2_OUT_EVEN, 1, 0, 0),
1718c2ecf20Sopenharmony_ci	F(600000000, P_CAM_CC_PLL0_OUT_EVEN, 1, 0, 0),
1728c2ecf20Sopenharmony_ci	{ }
1738c2ecf20Sopenharmony_ci};
1748c2ecf20Sopenharmony_ci
1758c2ecf20Sopenharmony_ci/*
1768c2ecf20Sopenharmony_ci * As per HW design, some of the CAMCC RCGs needs to
1778c2ecf20Sopenharmony_ci * move to XO clock during their clock disable so using
1788c2ecf20Sopenharmony_ci * clk_rcg2_shared_ops for such RCGs. This is required
1798c2ecf20Sopenharmony_ci * to power down the camera memories gracefully.
1808c2ecf20Sopenharmony_ci * Also, use CLK_SET_RATE_PARENT flag for the RCGs which
1818c2ecf20Sopenharmony_ci * have CAM_CC_PLL2_OUT_EVEN PLL as parent in frequency
1828c2ecf20Sopenharmony_ci * table and requires reconfiguration of the PLL frequency.
1838c2ecf20Sopenharmony_ci */
1848c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_bps_clk_src = {
1858c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x600c,
1868c2ecf20Sopenharmony_ci	.mnd_width = 0,
1878c2ecf20Sopenharmony_ci	.hid_width = 5,
1888c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
1898c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_bps_clk_src,
1908c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
1918c2ecf20Sopenharmony_ci		.name = "cam_cc_bps_clk_src",
1928c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
1938c2ecf20Sopenharmony_ci		.num_parents = 6,
1948c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
1958c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_shared_ops,
1968c2ecf20Sopenharmony_ci	},
1978c2ecf20Sopenharmony_ci};
1988c2ecf20Sopenharmony_ci
1998c2ecf20Sopenharmony_cistatic const struct freq_tbl ftbl_cam_cc_cci_clk_src[] = {
2008c2ecf20Sopenharmony_ci	F(19200000, P_BI_TCXO, 1, 0, 0),
2018c2ecf20Sopenharmony_ci	F(37500000, P_CAM_CC_PLL0_OUT_EVEN, 16, 0, 0),
2028c2ecf20Sopenharmony_ci	F(50000000, P_CAM_CC_PLL0_OUT_EVEN, 12, 0, 0),
2038c2ecf20Sopenharmony_ci	F(100000000, P_CAM_CC_PLL0_OUT_EVEN, 6, 0, 0),
2048c2ecf20Sopenharmony_ci	{ }
2058c2ecf20Sopenharmony_ci};
2068c2ecf20Sopenharmony_ci
2078c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_cci_clk_src = {
2088c2ecf20Sopenharmony_ci	.cmd_rcgr = 0xb0d8,
2098c2ecf20Sopenharmony_ci	.mnd_width = 8,
2108c2ecf20Sopenharmony_ci	.hid_width = 5,
2118c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
2128c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_cci_clk_src,
2138c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
2148c2ecf20Sopenharmony_ci		.name = "cam_cc_cci_clk_src",
2158c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
2168c2ecf20Sopenharmony_ci		.num_parents = 6,
2178c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_ops,
2188c2ecf20Sopenharmony_ci	},
2198c2ecf20Sopenharmony_ci};
2208c2ecf20Sopenharmony_ci
2218c2ecf20Sopenharmony_cistatic const struct freq_tbl ftbl_cam_cc_cphy_rx_clk_src[] = {
2228c2ecf20Sopenharmony_ci	F(19200000, P_BI_TCXO, 1, 0, 0),
2238c2ecf20Sopenharmony_ci	F(384000000, P_CAM_CC_PLL3_OUT_EVEN, 1, 0, 0),
2248c2ecf20Sopenharmony_ci	{ }
2258c2ecf20Sopenharmony_ci};
2268c2ecf20Sopenharmony_ci
2278c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_cphy_rx_clk_src = {
2288c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x9060,
2298c2ecf20Sopenharmony_ci	.mnd_width = 0,
2308c2ecf20Sopenharmony_ci	.hid_width = 5,
2318c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
2328c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_cphy_rx_clk_src,
2338c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
2348c2ecf20Sopenharmony_ci		.name = "cam_cc_cphy_rx_clk_src",
2358c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
2368c2ecf20Sopenharmony_ci		.num_parents = 6,
2378c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_ops,
2388c2ecf20Sopenharmony_ci	},
2398c2ecf20Sopenharmony_ci};
2408c2ecf20Sopenharmony_ci
2418c2ecf20Sopenharmony_cistatic const struct freq_tbl ftbl_cam_cc_csi0phytimer_clk_src[] = {
2428c2ecf20Sopenharmony_ci	F(19200000, P_BI_TCXO, 1, 0, 0),
2438c2ecf20Sopenharmony_ci	F(240000000, P_CAM_CC_PLL2_OUT_EVEN, 2, 0, 0),
2448c2ecf20Sopenharmony_ci	F(269333333, P_CAM_CC_PLL1_OUT_EVEN, 3, 0, 0),
2458c2ecf20Sopenharmony_ci	{ }
2468c2ecf20Sopenharmony_ci};
2478c2ecf20Sopenharmony_ci
2488c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_csi0phytimer_clk_src = {
2498c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x5004,
2508c2ecf20Sopenharmony_ci	.mnd_width = 0,
2518c2ecf20Sopenharmony_ci	.hid_width = 5,
2528c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
2538c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_csi0phytimer_clk_src,
2548c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
2558c2ecf20Sopenharmony_ci		.name = "cam_cc_csi0phytimer_clk_src",
2568c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
2578c2ecf20Sopenharmony_ci		.num_parents = 6,
2588c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
2598c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_ops,
2608c2ecf20Sopenharmony_ci	},
2618c2ecf20Sopenharmony_ci};
2628c2ecf20Sopenharmony_ci
2638c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_csi1phytimer_clk_src = {
2648c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x5028,
2658c2ecf20Sopenharmony_ci	.mnd_width = 0,
2668c2ecf20Sopenharmony_ci	.hid_width = 5,
2678c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
2688c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_csi0phytimer_clk_src,
2698c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
2708c2ecf20Sopenharmony_ci		.name = "cam_cc_csi1phytimer_clk_src",
2718c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
2728c2ecf20Sopenharmony_ci		.num_parents = 6,
2738c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
2748c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_ops,
2758c2ecf20Sopenharmony_ci	},
2768c2ecf20Sopenharmony_ci};
2778c2ecf20Sopenharmony_ci
2788c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_csi2phytimer_clk_src = {
2798c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x504c,
2808c2ecf20Sopenharmony_ci	.mnd_width = 0,
2818c2ecf20Sopenharmony_ci	.hid_width = 5,
2828c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
2838c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_csi0phytimer_clk_src,
2848c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
2858c2ecf20Sopenharmony_ci		.name = "cam_cc_csi2phytimer_clk_src",
2868c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
2878c2ecf20Sopenharmony_ci		.num_parents = 6,
2888c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
2898c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_ops,
2908c2ecf20Sopenharmony_ci	},
2918c2ecf20Sopenharmony_ci};
2928c2ecf20Sopenharmony_ci
2938c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_csi3phytimer_clk_src = {
2948c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x5070,
2958c2ecf20Sopenharmony_ci	.mnd_width = 0,
2968c2ecf20Sopenharmony_ci	.hid_width = 5,
2978c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
2988c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_csi0phytimer_clk_src,
2998c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
3008c2ecf20Sopenharmony_ci		.name = "cam_cc_csi3phytimer_clk_src",
3018c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
3028c2ecf20Sopenharmony_ci		.num_parents = 6,
3038c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
3048c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_ops,
3058c2ecf20Sopenharmony_ci	},
3068c2ecf20Sopenharmony_ci};
3078c2ecf20Sopenharmony_ci
3088c2ecf20Sopenharmony_cistatic const struct freq_tbl ftbl_cam_cc_fast_ahb_clk_src[] = {
3098c2ecf20Sopenharmony_ci	F(19200000, P_BI_TCXO, 1, 0, 0),
3108c2ecf20Sopenharmony_ci	F(50000000, P_CAM_CC_PLL0_OUT_EVEN, 12, 0, 0),
3118c2ecf20Sopenharmony_ci	F(100000000, P_CAM_CC_PLL0_OUT_EVEN, 6, 0, 0),
3128c2ecf20Sopenharmony_ci	F(200000000, P_CAM_CC_PLL0_OUT_EVEN, 3, 0, 0),
3138c2ecf20Sopenharmony_ci	F(300000000, P_CAM_CC_PLL0_OUT_EVEN, 2, 0, 0),
3148c2ecf20Sopenharmony_ci	F(400000000, P_CAM_CC_PLL0_OUT_EVEN, 1.5, 0, 0),
3158c2ecf20Sopenharmony_ci	{ }
3168c2ecf20Sopenharmony_ci};
3178c2ecf20Sopenharmony_ci
3188c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_fast_ahb_clk_src = {
3198c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x6038,
3208c2ecf20Sopenharmony_ci	.mnd_width = 0,
3218c2ecf20Sopenharmony_ci	.hid_width = 5,
3228c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
3238c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_fast_ahb_clk_src,
3248c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
3258c2ecf20Sopenharmony_ci		.name = "cam_cc_fast_ahb_clk_src",
3268c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
3278c2ecf20Sopenharmony_ci		.num_parents = 6,
3288c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_ops,
3298c2ecf20Sopenharmony_ci	},
3308c2ecf20Sopenharmony_ci};
3318c2ecf20Sopenharmony_ci
3328c2ecf20Sopenharmony_cistatic const struct freq_tbl ftbl_cam_cc_fd_core_clk_src[] = {
3338c2ecf20Sopenharmony_ci	F(19200000, P_BI_TCXO, 1, 0, 0),
3348c2ecf20Sopenharmony_ci	F(384000000, P_CAM_CC_PLL3_OUT_EVEN, 1, 0, 0),
3358c2ecf20Sopenharmony_ci	F(400000000, P_CAM_CC_PLL0_OUT_EVEN, 1.5, 0, 0),
3368c2ecf20Sopenharmony_ci	F(538666667, P_CAM_CC_PLL1_OUT_EVEN, 1.5, 0, 0),
3378c2ecf20Sopenharmony_ci	F(600000000, P_CAM_CC_PLL0_OUT_EVEN, 1, 0, 0),
3388c2ecf20Sopenharmony_ci	{ }
3398c2ecf20Sopenharmony_ci};
3408c2ecf20Sopenharmony_ci
3418c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_fd_core_clk_src = {
3428c2ecf20Sopenharmony_ci	.cmd_rcgr = 0xb0b0,
3438c2ecf20Sopenharmony_ci	.mnd_width = 0,
3448c2ecf20Sopenharmony_ci	.hid_width = 5,
3458c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
3468c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_fd_core_clk_src,
3478c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
3488c2ecf20Sopenharmony_ci		.name = "cam_cc_fd_core_clk_src",
3498c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
3508c2ecf20Sopenharmony_ci		.num_parents = 6,
3518c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_shared_ops,
3528c2ecf20Sopenharmony_ci	},
3538c2ecf20Sopenharmony_ci};
3548c2ecf20Sopenharmony_ci
3558c2ecf20Sopenharmony_cistatic const struct freq_tbl ftbl_cam_cc_icp_clk_src[] = {
3568c2ecf20Sopenharmony_ci	F(19200000, P_BI_TCXO, 1, 0, 0),
3578c2ecf20Sopenharmony_ci	F(384000000, P_CAM_CC_PLL3_OUT_EVEN, 1, 0, 0),
3588c2ecf20Sopenharmony_ci	F(400000000, P_CAM_CC_PLL0_OUT_EVEN, 1.5, 0, 0),
3598c2ecf20Sopenharmony_ci	F(538666667, P_CAM_CC_PLL1_OUT_EVEN, 1.5, 0, 0),
3608c2ecf20Sopenharmony_ci	F(600000000, P_CAM_CC_PLL0_OUT_EVEN, 1, 0, 0),
3618c2ecf20Sopenharmony_ci	{ }
3628c2ecf20Sopenharmony_ci};
3638c2ecf20Sopenharmony_ci
3648c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_icp_clk_src = {
3658c2ecf20Sopenharmony_ci	.cmd_rcgr = 0xb088,
3668c2ecf20Sopenharmony_ci	.mnd_width = 0,
3678c2ecf20Sopenharmony_ci	.hid_width = 5,
3688c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
3698c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_icp_clk_src,
3708c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
3718c2ecf20Sopenharmony_ci		.name = "cam_cc_icp_clk_src",
3728c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
3738c2ecf20Sopenharmony_ci		.num_parents = 6,
3748c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_shared_ops,
3758c2ecf20Sopenharmony_ci	},
3768c2ecf20Sopenharmony_ci};
3778c2ecf20Sopenharmony_ci
3788c2ecf20Sopenharmony_cistatic const struct freq_tbl ftbl_cam_cc_ife_0_clk_src[] = {
3798c2ecf20Sopenharmony_ci	F(19200000, P_BI_TCXO, 1, 0, 0),
3808c2ecf20Sopenharmony_ci	F(100000000, P_CAM_CC_PLL0_OUT_EVEN, 6, 0, 0),
3818c2ecf20Sopenharmony_ci	F(320000000, P_CAM_CC_PLL2_OUT_EVEN, 1.5, 0, 0),
3828c2ecf20Sopenharmony_ci	F(404000000, P_CAM_CC_PLL1_OUT_EVEN, 2, 0, 0),
3838c2ecf20Sopenharmony_ci	F(480000000, P_CAM_CC_PLL2_OUT_EVEN, 1, 0, 0),
3848c2ecf20Sopenharmony_ci	F(600000000, P_CAM_CC_PLL0_OUT_EVEN, 1, 0, 0),
3858c2ecf20Sopenharmony_ci	{ }
3868c2ecf20Sopenharmony_ci};
3878c2ecf20Sopenharmony_ci
3888c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_ife_0_clk_src = {
3898c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x900c,
3908c2ecf20Sopenharmony_ci	.mnd_width = 0,
3918c2ecf20Sopenharmony_ci	.hid_width = 5,
3928c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
3938c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_ife_0_clk_src,
3948c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
3958c2ecf20Sopenharmony_ci		.name = "cam_cc_ife_0_clk_src",
3968c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
3978c2ecf20Sopenharmony_ci		.num_parents = 6,
3988c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
3998c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_shared_ops,
4008c2ecf20Sopenharmony_ci	},
4018c2ecf20Sopenharmony_ci};
4028c2ecf20Sopenharmony_ci
4038c2ecf20Sopenharmony_cistatic const struct freq_tbl ftbl_cam_cc_ife_0_csid_clk_src[] = {
4048c2ecf20Sopenharmony_ci	F(19200000, P_BI_TCXO, 1, 0, 0),
4058c2ecf20Sopenharmony_ci	F(75000000, P_CAM_CC_PLL0_OUT_EVEN, 8, 0, 0),
4068c2ecf20Sopenharmony_ci	F(384000000, P_CAM_CC_PLL3_OUT_EVEN, 1, 0, 0),
4078c2ecf20Sopenharmony_ci	F(538666667, P_CAM_CC_PLL1_OUT_EVEN, 1.5, 0, 0),
4088c2ecf20Sopenharmony_ci	{ }
4098c2ecf20Sopenharmony_ci};
4108c2ecf20Sopenharmony_ci
4118c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_ife_0_csid_clk_src = {
4128c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x9038,
4138c2ecf20Sopenharmony_ci	.mnd_width = 0,
4148c2ecf20Sopenharmony_ci	.hid_width = 5,
4158c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
4168c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_ife_0_csid_clk_src,
4178c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
4188c2ecf20Sopenharmony_ci		.name = "cam_cc_ife_0_csid_clk_src",
4198c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
4208c2ecf20Sopenharmony_ci		.num_parents = 6,
4218c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_shared_ops,
4228c2ecf20Sopenharmony_ci	},
4238c2ecf20Sopenharmony_ci};
4248c2ecf20Sopenharmony_ci
4258c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_ife_1_clk_src = {
4268c2ecf20Sopenharmony_ci	.cmd_rcgr = 0xa00c,
4278c2ecf20Sopenharmony_ci	.mnd_width = 0,
4288c2ecf20Sopenharmony_ci	.hid_width = 5,
4298c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
4308c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_ife_0_clk_src,
4318c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
4328c2ecf20Sopenharmony_ci		.name = "cam_cc_ife_1_clk_src",
4338c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
4348c2ecf20Sopenharmony_ci		.num_parents = 6,
4358c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
4368c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_shared_ops,
4378c2ecf20Sopenharmony_ci	},
4388c2ecf20Sopenharmony_ci};
4398c2ecf20Sopenharmony_ci
4408c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_ife_1_csid_clk_src = {
4418c2ecf20Sopenharmony_ci	.cmd_rcgr = 0xa030,
4428c2ecf20Sopenharmony_ci	.mnd_width = 0,
4438c2ecf20Sopenharmony_ci	.hid_width = 5,
4448c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
4458c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_ife_0_csid_clk_src,
4468c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
4478c2ecf20Sopenharmony_ci		.name = "cam_cc_ife_1_csid_clk_src",
4488c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
4498c2ecf20Sopenharmony_ci		.num_parents = 6,
4508c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_shared_ops,
4518c2ecf20Sopenharmony_ci	},
4528c2ecf20Sopenharmony_ci};
4538c2ecf20Sopenharmony_ci
4548c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_ife_lite_clk_src = {
4558c2ecf20Sopenharmony_ci	.cmd_rcgr = 0xb004,
4568c2ecf20Sopenharmony_ci	.mnd_width = 0,
4578c2ecf20Sopenharmony_ci	.hid_width = 5,
4588c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
4598c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_ife_0_clk_src,
4608c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
4618c2ecf20Sopenharmony_ci		.name = "cam_cc_ife_lite_clk_src",
4628c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
4638c2ecf20Sopenharmony_ci		.num_parents = 6,
4648c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
4658c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_shared_ops,
4668c2ecf20Sopenharmony_ci	},
4678c2ecf20Sopenharmony_ci};
4688c2ecf20Sopenharmony_ci
4698c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_ife_lite_csid_clk_src = {
4708c2ecf20Sopenharmony_ci	.cmd_rcgr = 0xb024,
4718c2ecf20Sopenharmony_ci	.mnd_width = 0,
4728c2ecf20Sopenharmony_ci	.hid_width = 5,
4738c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
4748c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_ife_0_csid_clk_src,
4758c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
4768c2ecf20Sopenharmony_ci		.name = "cam_cc_ife_lite_csid_clk_src",
4778c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
4788c2ecf20Sopenharmony_ci		.num_parents = 6,
4798c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_shared_ops,
4808c2ecf20Sopenharmony_ci	},
4818c2ecf20Sopenharmony_ci};
4828c2ecf20Sopenharmony_ci
4838c2ecf20Sopenharmony_cistatic const struct freq_tbl ftbl_cam_cc_ipe_0_clk_src[] = {
4848c2ecf20Sopenharmony_ci	F(19200000, P_BI_TCXO, 1, 0, 0),
4858c2ecf20Sopenharmony_ci	F(100000000, P_CAM_CC_PLL0_OUT_EVEN, 6, 0, 0),
4868c2ecf20Sopenharmony_ci	F(240000000, P_CAM_CC_PLL0_OUT_EVEN, 2.5, 0, 0),
4878c2ecf20Sopenharmony_ci	F(404000000, P_CAM_CC_PLL1_OUT_EVEN, 2, 0, 0),
4888c2ecf20Sopenharmony_ci	F(480000000, P_CAM_CC_PLL2_OUT_EVEN, 1, 0, 0),
4898c2ecf20Sopenharmony_ci	F(538666667, P_CAM_CC_PLL1_OUT_EVEN, 1.5, 0, 0),
4908c2ecf20Sopenharmony_ci	F(600000000, P_CAM_CC_PLL0_OUT_EVEN, 1, 0, 0),
4918c2ecf20Sopenharmony_ci	{ }
4928c2ecf20Sopenharmony_ci};
4938c2ecf20Sopenharmony_ci
4948c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_ipe_0_clk_src = {
4958c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x700c,
4968c2ecf20Sopenharmony_ci	.mnd_width = 0,
4978c2ecf20Sopenharmony_ci	.hid_width = 5,
4988c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
4998c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_ipe_0_clk_src,
5008c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
5018c2ecf20Sopenharmony_ci		.name = "cam_cc_ipe_0_clk_src",
5028c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
5038c2ecf20Sopenharmony_ci		.num_parents = 6,
5048c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
5058c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_shared_ops,
5068c2ecf20Sopenharmony_ci	},
5078c2ecf20Sopenharmony_ci};
5088c2ecf20Sopenharmony_ci
5098c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_ipe_1_clk_src = {
5108c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x800c,
5118c2ecf20Sopenharmony_ci	.mnd_width = 0,
5128c2ecf20Sopenharmony_ci	.hid_width = 5,
5138c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
5148c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_ipe_0_clk_src,
5158c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
5168c2ecf20Sopenharmony_ci		.name = "cam_cc_ipe_1_clk_src",
5178c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
5188c2ecf20Sopenharmony_ci		.num_parents = 6,
5198c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
5208c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_shared_ops,
5218c2ecf20Sopenharmony_ci	},
5228c2ecf20Sopenharmony_ci};
5238c2ecf20Sopenharmony_ci
5248c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_jpeg_clk_src = {
5258c2ecf20Sopenharmony_ci	.cmd_rcgr = 0xb04c,
5268c2ecf20Sopenharmony_ci	.mnd_width = 0,
5278c2ecf20Sopenharmony_ci	.hid_width = 5,
5288c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
5298c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_bps_clk_src,
5308c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
5318c2ecf20Sopenharmony_ci		.name = "cam_cc_jpeg_clk_src",
5328c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
5338c2ecf20Sopenharmony_ci		.num_parents = 6,
5348c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
5358c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_shared_ops,
5368c2ecf20Sopenharmony_ci	},
5378c2ecf20Sopenharmony_ci};
5388c2ecf20Sopenharmony_ci
5398c2ecf20Sopenharmony_cistatic const struct freq_tbl ftbl_cam_cc_lrme_clk_src[] = {
5408c2ecf20Sopenharmony_ci	F(19200000, P_BI_TCXO, 1, 0, 0),
5418c2ecf20Sopenharmony_ci	F(100000000, P_CAM_CC_PLL0_OUT_EVEN, 6, 0, 0),
5428c2ecf20Sopenharmony_ci	F(200000000, P_CAM_CC_PLL0_OUT_EVEN, 3, 0, 0),
5438c2ecf20Sopenharmony_ci	F(269333333, P_CAM_CC_PLL1_OUT_EVEN, 3, 0, 0),
5448c2ecf20Sopenharmony_ci	F(320000000, P_CAM_CC_PLL2_OUT_EVEN, 1.5, 0, 0),
5458c2ecf20Sopenharmony_ci	F(400000000, P_CAM_CC_PLL0_OUT_EVEN, 1.5, 0, 0),
5468c2ecf20Sopenharmony_ci	{ }
5478c2ecf20Sopenharmony_ci};
5488c2ecf20Sopenharmony_ci
5498c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_lrme_clk_src = {
5508c2ecf20Sopenharmony_ci	.cmd_rcgr = 0xb0f8,
5518c2ecf20Sopenharmony_ci	.mnd_width = 0,
5528c2ecf20Sopenharmony_ci	.hid_width = 5,
5538c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
5548c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_lrme_clk_src,
5558c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
5568c2ecf20Sopenharmony_ci		.name = "cam_cc_lrme_clk_src",
5578c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
5588c2ecf20Sopenharmony_ci		.num_parents = 6,
5598c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
5608c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_shared_ops,
5618c2ecf20Sopenharmony_ci	},
5628c2ecf20Sopenharmony_ci};
5638c2ecf20Sopenharmony_ci
5648c2ecf20Sopenharmony_cistatic const struct freq_tbl ftbl_cam_cc_mclk0_clk_src[] = {
5658c2ecf20Sopenharmony_ci	F(19200000, P_BI_TCXO, 1, 0, 0),
5668c2ecf20Sopenharmony_ci	F(24000000, P_CAM_CC_PLL2_OUT_EVEN, 10, 1, 2),
5678c2ecf20Sopenharmony_ci	F(33333333, P_CAM_CC_PLL0_OUT_EVEN, 2, 1, 9),
5688c2ecf20Sopenharmony_ci	F(34285714, P_CAM_CC_PLL2_OUT_EVEN, 14, 0, 0),
5698c2ecf20Sopenharmony_ci	{ }
5708c2ecf20Sopenharmony_ci};
5718c2ecf20Sopenharmony_ci
5728c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_mclk0_clk_src = {
5738c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x4004,
5748c2ecf20Sopenharmony_ci	.mnd_width = 8,
5758c2ecf20Sopenharmony_ci	.hid_width = 5,
5768c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
5778c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_mclk0_clk_src,
5788c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
5798c2ecf20Sopenharmony_ci		.name = "cam_cc_mclk0_clk_src",
5808c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
5818c2ecf20Sopenharmony_ci		.num_parents = 6,
5828c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
5838c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_ops,
5848c2ecf20Sopenharmony_ci	},
5858c2ecf20Sopenharmony_ci};
5868c2ecf20Sopenharmony_ci
5878c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_mclk1_clk_src = {
5888c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x4024,
5898c2ecf20Sopenharmony_ci	.mnd_width = 8,
5908c2ecf20Sopenharmony_ci	.hid_width = 5,
5918c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
5928c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_mclk0_clk_src,
5938c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
5948c2ecf20Sopenharmony_ci		.name = "cam_cc_mclk1_clk_src",
5958c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
5968c2ecf20Sopenharmony_ci		.num_parents = 6,
5978c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
5988c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_ops,
5998c2ecf20Sopenharmony_ci	},
6008c2ecf20Sopenharmony_ci};
6018c2ecf20Sopenharmony_ci
6028c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_mclk2_clk_src = {
6038c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x4044,
6048c2ecf20Sopenharmony_ci	.mnd_width = 8,
6058c2ecf20Sopenharmony_ci	.hid_width = 5,
6068c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
6078c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_mclk0_clk_src,
6088c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
6098c2ecf20Sopenharmony_ci		.name = "cam_cc_mclk2_clk_src",
6108c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
6118c2ecf20Sopenharmony_ci		.num_parents = 6,
6128c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
6138c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_ops,
6148c2ecf20Sopenharmony_ci	},
6158c2ecf20Sopenharmony_ci};
6168c2ecf20Sopenharmony_ci
6178c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_mclk3_clk_src = {
6188c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x4064,
6198c2ecf20Sopenharmony_ci	.mnd_width = 8,
6208c2ecf20Sopenharmony_ci	.hid_width = 5,
6218c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
6228c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_mclk0_clk_src,
6238c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
6248c2ecf20Sopenharmony_ci		.name = "cam_cc_mclk3_clk_src",
6258c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
6268c2ecf20Sopenharmony_ci		.num_parents = 6,
6278c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
6288c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_ops,
6298c2ecf20Sopenharmony_ci	},
6308c2ecf20Sopenharmony_ci};
6318c2ecf20Sopenharmony_ci
6328c2ecf20Sopenharmony_cistatic const struct freq_tbl ftbl_cam_cc_slow_ahb_clk_src[] = {
6338c2ecf20Sopenharmony_ci	F(19200000, P_BI_TCXO, 1, 0, 0),
6348c2ecf20Sopenharmony_ci	F(60000000, P_CAM_CC_PLL0_OUT_EVEN, 10, 0, 0),
6358c2ecf20Sopenharmony_ci	F(66666667, P_CAM_CC_PLL0_OUT_EVEN, 9, 0, 0),
6368c2ecf20Sopenharmony_ci	F(73846154, P_CAM_CC_PLL2_OUT_EVEN, 6.5, 0, 0),
6378c2ecf20Sopenharmony_ci	F(80000000, P_CAM_CC_PLL2_OUT_EVEN, 6, 0, 0),
6388c2ecf20Sopenharmony_ci	{ }
6398c2ecf20Sopenharmony_ci};
6408c2ecf20Sopenharmony_ci
6418c2ecf20Sopenharmony_cistatic struct clk_rcg2 cam_cc_slow_ahb_clk_src = {
6428c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x6054,
6438c2ecf20Sopenharmony_ci	.mnd_width = 0,
6448c2ecf20Sopenharmony_ci	.hid_width = 5,
6458c2ecf20Sopenharmony_ci	.parent_map = cam_cc_parent_map_0,
6468c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_cam_cc_slow_ahb_clk_src,
6478c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
6488c2ecf20Sopenharmony_ci		.name = "cam_cc_slow_ahb_clk_src",
6498c2ecf20Sopenharmony_ci		.parent_names = cam_cc_parent_names_0,
6508c2ecf20Sopenharmony_ci		.num_parents = 6,
6518c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
6528c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_ops,
6538c2ecf20Sopenharmony_ci	},
6548c2ecf20Sopenharmony_ci};
6558c2ecf20Sopenharmony_ci
6568c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_bps_ahb_clk = {
6578c2ecf20Sopenharmony_ci	.halt_reg = 0x606c,
6588c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
6598c2ecf20Sopenharmony_ci	.clkr = {
6608c2ecf20Sopenharmony_ci		.enable_reg = 0x606c,
6618c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
6628c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
6638c2ecf20Sopenharmony_ci			.name = "cam_cc_bps_ahb_clk",
6648c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
6658c2ecf20Sopenharmony_ci				"cam_cc_slow_ahb_clk_src",
6668c2ecf20Sopenharmony_ci			},
6678c2ecf20Sopenharmony_ci			.num_parents = 1,
6688c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
6698c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
6708c2ecf20Sopenharmony_ci		},
6718c2ecf20Sopenharmony_ci	},
6728c2ecf20Sopenharmony_ci};
6738c2ecf20Sopenharmony_ci
6748c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_bps_areg_clk = {
6758c2ecf20Sopenharmony_ci	.halt_reg = 0x6050,
6768c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
6778c2ecf20Sopenharmony_ci	.clkr = {
6788c2ecf20Sopenharmony_ci		.enable_reg = 0x6050,
6798c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
6808c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
6818c2ecf20Sopenharmony_ci			.name = "cam_cc_bps_areg_clk",
6828c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
6838c2ecf20Sopenharmony_ci				"cam_cc_fast_ahb_clk_src",
6848c2ecf20Sopenharmony_ci			},
6858c2ecf20Sopenharmony_ci			.num_parents = 1,
6868c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
6878c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
6888c2ecf20Sopenharmony_ci		},
6898c2ecf20Sopenharmony_ci	},
6908c2ecf20Sopenharmony_ci};
6918c2ecf20Sopenharmony_ci
6928c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_bps_axi_clk = {
6938c2ecf20Sopenharmony_ci	.halt_reg = 0x6034,
6948c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
6958c2ecf20Sopenharmony_ci	.clkr = {
6968c2ecf20Sopenharmony_ci		.enable_reg = 0x6034,
6978c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
6988c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
6998c2ecf20Sopenharmony_ci			.name = "cam_cc_bps_axi_clk",
7008c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
7018c2ecf20Sopenharmony_ci		},
7028c2ecf20Sopenharmony_ci	},
7038c2ecf20Sopenharmony_ci};
7048c2ecf20Sopenharmony_ci
7058c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_bps_clk = {
7068c2ecf20Sopenharmony_ci	.halt_reg = 0x6024,
7078c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
7088c2ecf20Sopenharmony_ci	.clkr = {
7098c2ecf20Sopenharmony_ci		.enable_reg = 0x6024,
7108c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
7118c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
7128c2ecf20Sopenharmony_ci			.name = "cam_cc_bps_clk",
7138c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
7148c2ecf20Sopenharmony_ci				"cam_cc_bps_clk_src",
7158c2ecf20Sopenharmony_ci			},
7168c2ecf20Sopenharmony_ci			.num_parents = 1,
7178c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
7188c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
7198c2ecf20Sopenharmony_ci		},
7208c2ecf20Sopenharmony_ci	},
7218c2ecf20Sopenharmony_ci};
7228c2ecf20Sopenharmony_ci
7238c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_camnoc_atb_clk = {
7248c2ecf20Sopenharmony_ci	.halt_reg = 0xb12c,
7258c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
7268c2ecf20Sopenharmony_ci	.clkr = {
7278c2ecf20Sopenharmony_ci		.enable_reg = 0xb12c,
7288c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
7298c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
7308c2ecf20Sopenharmony_ci			.name = "cam_cc_camnoc_atb_clk",
7318c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
7328c2ecf20Sopenharmony_ci		},
7338c2ecf20Sopenharmony_ci	},
7348c2ecf20Sopenharmony_ci};
7358c2ecf20Sopenharmony_ci
7368c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_camnoc_axi_clk = {
7378c2ecf20Sopenharmony_ci	.halt_reg = 0xb124,
7388c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
7398c2ecf20Sopenharmony_ci	.clkr = {
7408c2ecf20Sopenharmony_ci		.enable_reg = 0xb124,
7418c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
7428c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
7438c2ecf20Sopenharmony_ci			.name = "cam_cc_camnoc_axi_clk",
7448c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
7458c2ecf20Sopenharmony_ci		},
7468c2ecf20Sopenharmony_ci	},
7478c2ecf20Sopenharmony_ci};
7488c2ecf20Sopenharmony_ci
7498c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_cci_clk = {
7508c2ecf20Sopenharmony_ci	.halt_reg = 0xb0f0,
7518c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
7528c2ecf20Sopenharmony_ci	.clkr = {
7538c2ecf20Sopenharmony_ci		.enable_reg = 0xb0f0,
7548c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
7558c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
7568c2ecf20Sopenharmony_ci			.name = "cam_cc_cci_clk",
7578c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
7588c2ecf20Sopenharmony_ci				"cam_cc_cci_clk_src",
7598c2ecf20Sopenharmony_ci			},
7608c2ecf20Sopenharmony_ci			.num_parents = 1,
7618c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
7628c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
7638c2ecf20Sopenharmony_ci		},
7648c2ecf20Sopenharmony_ci	},
7658c2ecf20Sopenharmony_ci};
7668c2ecf20Sopenharmony_ci
7678c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_cpas_ahb_clk = {
7688c2ecf20Sopenharmony_ci	.halt_reg = 0xb11c,
7698c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
7708c2ecf20Sopenharmony_ci	.clkr = {
7718c2ecf20Sopenharmony_ci		.enable_reg = 0xb11c,
7728c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
7738c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
7748c2ecf20Sopenharmony_ci			.name = "cam_cc_cpas_ahb_clk",
7758c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
7768c2ecf20Sopenharmony_ci				"cam_cc_slow_ahb_clk_src",
7778c2ecf20Sopenharmony_ci			},
7788c2ecf20Sopenharmony_ci			.num_parents = 1,
7798c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
7808c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
7818c2ecf20Sopenharmony_ci		},
7828c2ecf20Sopenharmony_ci	},
7838c2ecf20Sopenharmony_ci};
7848c2ecf20Sopenharmony_ci
7858c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_csi0phytimer_clk = {
7868c2ecf20Sopenharmony_ci	.halt_reg = 0x501c,
7878c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
7888c2ecf20Sopenharmony_ci	.clkr = {
7898c2ecf20Sopenharmony_ci		.enable_reg = 0x501c,
7908c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
7918c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
7928c2ecf20Sopenharmony_ci			.name = "cam_cc_csi0phytimer_clk",
7938c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
7948c2ecf20Sopenharmony_ci				"cam_cc_csi0phytimer_clk_src",
7958c2ecf20Sopenharmony_ci			},
7968c2ecf20Sopenharmony_ci			.num_parents = 1,
7978c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
7988c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
7998c2ecf20Sopenharmony_ci		},
8008c2ecf20Sopenharmony_ci	},
8018c2ecf20Sopenharmony_ci};
8028c2ecf20Sopenharmony_ci
8038c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_csi1phytimer_clk = {
8048c2ecf20Sopenharmony_ci	.halt_reg = 0x5040,
8058c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
8068c2ecf20Sopenharmony_ci	.clkr = {
8078c2ecf20Sopenharmony_ci		.enable_reg = 0x5040,
8088c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
8098c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
8108c2ecf20Sopenharmony_ci			.name = "cam_cc_csi1phytimer_clk",
8118c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
8128c2ecf20Sopenharmony_ci				"cam_cc_csi1phytimer_clk_src",
8138c2ecf20Sopenharmony_ci			},
8148c2ecf20Sopenharmony_ci			.num_parents = 1,
8158c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
8168c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
8178c2ecf20Sopenharmony_ci		},
8188c2ecf20Sopenharmony_ci	},
8198c2ecf20Sopenharmony_ci};
8208c2ecf20Sopenharmony_ci
8218c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_csi2phytimer_clk = {
8228c2ecf20Sopenharmony_ci	.halt_reg = 0x5064,
8238c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
8248c2ecf20Sopenharmony_ci	.clkr = {
8258c2ecf20Sopenharmony_ci		.enable_reg = 0x5064,
8268c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
8278c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
8288c2ecf20Sopenharmony_ci			.name = "cam_cc_csi2phytimer_clk",
8298c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
8308c2ecf20Sopenharmony_ci				"cam_cc_csi2phytimer_clk_src",
8318c2ecf20Sopenharmony_ci			},
8328c2ecf20Sopenharmony_ci			.num_parents = 1,
8338c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
8348c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
8358c2ecf20Sopenharmony_ci		},
8368c2ecf20Sopenharmony_ci	},
8378c2ecf20Sopenharmony_ci};
8388c2ecf20Sopenharmony_ci
8398c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_csi3phytimer_clk = {
8408c2ecf20Sopenharmony_ci	.halt_reg = 0x5088,
8418c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
8428c2ecf20Sopenharmony_ci	.clkr = {
8438c2ecf20Sopenharmony_ci		.enable_reg = 0x5088,
8448c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
8458c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
8468c2ecf20Sopenharmony_ci			.name = "cam_cc_csi3phytimer_clk",
8478c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
8488c2ecf20Sopenharmony_ci				"cam_cc_csi3phytimer_clk_src",
8498c2ecf20Sopenharmony_ci			},
8508c2ecf20Sopenharmony_ci			.num_parents = 1,
8518c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
8528c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
8538c2ecf20Sopenharmony_ci		},
8548c2ecf20Sopenharmony_ci	},
8558c2ecf20Sopenharmony_ci};
8568c2ecf20Sopenharmony_ci
8578c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_csiphy0_clk = {
8588c2ecf20Sopenharmony_ci	.halt_reg = 0x5020,
8598c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
8608c2ecf20Sopenharmony_ci	.clkr = {
8618c2ecf20Sopenharmony_ci		.enable_reg = 0x5020,
8628c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
8638c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
8648c2ecf20Sopenharmony_ci			.name = "cam_cc_csiphy0_clk",
8658c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
8668c2ecf20Sopenharmony_ci				"cam_cc_cphy_rx_clk_src",
8678c2ecf20Sopenharmony_ci			},
8688c2ecf20Sopenharmony_ci			.num_parents = 1,
8698c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
8708c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
8718c2ecf20Sopenharmony_ci		},
8728c2ecf20Sopenharmony_ci	},
8738c2ecf20Sopenharmony_ci};
8748c2ecf20Sopenharmony_ci
8758c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_csiphy1_clk = {
8768c2ecf20Sopenharmony_ci	.halt_reg = 0x5044,
8778c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
8788c2ecf20Sopenharmony_ci	.clkr = {
8798c2ecf20Sopenharmony_ci		.enable_reg = 0x5044,
8808c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
8818c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
8828c2ecf20Sopenharmony_ci			.name = "cam_cc_csiphy1_clk",
8838c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
8848c2ecf20Sopenharmony_ci				"cam_cc_cphy_rx_clk_src",
8858c2ecf20Sopenharmony_ci			},
8868c2ecf20Sopenharmony_ci			.num_parents = 1,
8878c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
8888c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
8898c2ecf20Sopenharmony_ci		},
8908c2ecf20Sopenharmony_ci	},
8918c2ecf20Sopenharmony_ci};
8928c2ecf20Sopenharmony_ci
8938c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_csiphy2_clk = {
8948c2ecf20Sopenharmony_ci	.halt_reg = 0x5068,
8958c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
8968c2ecf20Sopenharmony_ci	.clkr = {
8978c2ecf20Sopenharmony_ci		.enable_reg = 0x5068,
8988c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
8998c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
9008c2ecf20Sopenharmony_ci			.name = "cam_cc_csiphy2_clk",
9018c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
9028c2ecf20Sopenharmony_ci				"cam_cc_cphy_rx_clk_src",
9038c2ecf20Sopenharmony_ci			},
9048c2ecf20Sopenharmony_ci			.num_parents = 1,
9058c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
9068c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
9078c2ecf20Sopenharmony_ci		},
9088c2ecf20Sopenharmony_ci	},
9098c2ecf20Sopenharmony_ci};
9108c2ecf20Sopenharmony_ci
9118c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_csiphy3_clk = {
9128c2ecf20Sopenharmony_ci	.halt_reg = 0x508c,
9138c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
9148c2ecf20Sopenharmony_ci	.clkr = {
9158c2ecf20Sopenharmony_ci		.enable_reg = 0x508c,
9168c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
9178c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
9188c2ecf20Sopenharmony_ci			.name = "cam_cc_csiphy3_clk",
9198c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
9208c2ecf20Sopenharmony_ci				"cam_cc_cphy_rx_clk_src",
9218c2ecf20Sopenharmony_ci			},
9228c2ecf20Sopenharmony_ci			.num_parents = 1,
9238c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
9248c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
9258c2ecf20Sopenharmony_ci		},
9268c2ecf20Sopenharmony_ci	},
9278c2ecf20Sopenharmony_ci};
9288c2ecf20Sopenharmony_ci
9298c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_fd_core_clk = {
9308c2ecf20Sopenharmony_ci	.halt_reg = 0xb0c8,
9318c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
9328c2ecf20Sopenharmony_ci	.clkr = {
9338c2ecf20Sopenharmony_ci		.enable_reg = 0xb0c8,
9348c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
9358c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
9368c2ecf20Sopenharmony_ci			.name = "cam_cc_fd_core_clk",
9378c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
9388c2ecf20Sopenharmony_ci				"cam_cc_fd_core_clk_src",
9398c2ecf20Sopenharmony_ci			},
9408c2ecf20Sopenharmony_ci			.num_parents = 1,
9418c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
9428c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
9438c2ecf20Sopenharmony_ci		},
9448c2ecf20Sopenharmony_ci	},
9458c2ecf20Sopenharmony_ci};
9468c2ecf20Sopenharmony_ci
9478c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_fd_core_uar_clk = {
9488c2ecf20Sopenharmony_ci	.halt_reg = 0xb0d0,
9498c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
9508c2ecf20Sopenharmony_ci	.clkr = {
9518c2ecf20Sopenharmony_ci		.enable_reg = 0xb0d0,
9528c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
9538c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
9548c2ecf20Sopenharmony_ci			.name = "cam_cc_fd_core_uar_clk",
9558c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
9568c2ecf20Sopenharmony_ci				"cam_cc_fd_core_clk_src",
9578c2ecf20Sopenharmony_ci			},
9588c2ecf20Sopenharmony_ci			.num_parents = 1,
9598c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
9608c2ecf20Sopenharmony_ci		},
9618c2ecf20Sopenharmony_ci	},
9628c2ecf20Sopenharmony_ci};
9638c2ecf20Sopenharmony_ci
9648c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_icp_apb_clk = {
9658c2ecf20Sopenharmony_ci	.halt_reg = 0xb084,
9668c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
9678c2ecf20Sopenharmony_ci	.clkr = {
9688c2ecf20Sopenharmony_ci		.enable_reg = 0xb084,
9698c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
9708c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
9718c2ecf20Sopenharmony_ci			.name = "cam_cc_icp_apb_clk",
9728c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
9738c2ecf20Sopenharmony_ci		},
9748c2ecf20Sopenharmony_ci	},
9758c2ecf20Sopenharmony_ci};
9768c2ecf20Sopenharmony_ci
9778c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_icp_atb_clk = {
9788c2ecf20Sopenharmony_ci	.halt_reg = 0xb078,
9798c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
9808c2ecf20Sopenharmony_ci	.clkr = {
9818c2ecf20Sopenharmony_ci		.enable_reg = 0xb078,
9828c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
9838c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
9848c2ecf20Sopenharmony_ci			.name = "cam_cc_icp_atb_clk",
9858c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
9868c2ecf20Sopenharmony_ci		},
9878c2ecf20Sopenharmony_ci	},
9888c2ecf20Sopenharmony_ci};
9898c2ecf20Sopenharmony_ci
9908c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_icp_clk = {
9918c2ecf20Sopenharmony_ci	.halt_reg = 0xb0a0,
9928c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
9938c2ecf20Sopenharmony_ci	.clkr = {
9948c2ecf20Sopenharmony_ci		.enable_reg = 0xb0a0,
9958c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
9968c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
9978c2ecf20Sopenharmony_ci			.name = "cam_cc_icp_clk",
9988c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
9998c2ecf20Sopenharmony_ci				"cam_cc_icp_clk_src",
10008c2ecf20Sopenharmony_ci			},
10018c2ecf20Sopenharmony_ci			.num_parents = 1,
10028c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
10038c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
10048c2ecf20Sopenharmony_ci		},
10058c2ecf20Sopenharmony_ci	},
10068c2ecf20Sopenharmony_ci};
10078c2ecf20Sopenharmony_ci
10088c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_icp_cti_clk = {
10098c2ecf20Sopenharmony_ci	.halt_reg = 0xb07c,
10108c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
10118c2ecf20Sopenharmony_ci	.clkr = {
10128c2ecf20Sopenharmony_ci		.enable_reg = 0xb07c,
10138c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
10148c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
10158c2ecf20Sopenharmony_ci			.name = "cam_cc_icp_cti_clk",
10168c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
10178c2ecf20Sopenharmony_ci		},
10188c2ecf20Sopenharmony_ci	},
10198c2ecf20Sopenharmony_ci};
10208c2ecf20Sopenharmony_ci
10218c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_icp_ts_clk = {
10228c2ecf20Sopenharmony_ci	.halt_reg = 0xb080,
10238c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
10248c2ecf20Sopenharmony_ci	.clkr = {
10258c2ecf20Sopenharmony_ci		.enable_reg = 0xb080,
10268c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
10278c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
10288c2ecf20Sopenharmony_ci			.name = "cam_cc_icp_ts_clk",
10298c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
10308c2ecf20Sopenharmony_ci		},
10318c2ecf20Sopenharmony_ci	},
10328c2ecf20Sopenharmony_ci};
10338c2ecf20Sopenharmony_ci
10348c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ife_0_axi_clk = {
10358c2ecf20Sopenharmony_ci	.halt_reg = 0x907c,
10368c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
10378c2ecf20Sopenharmony_ci	.clkr = {
10388c2ecf20Sopenharmony_ci		.enable_reg = 0x907c,
10398c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
10408c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
10418c2ecf20Sopenharmony_ci			.name = "cam_cc_ife_0_axi_clk",
10428c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
10438c2ecf20Sopenharmony_ci		},
10448c2ecf20Sopenharmony_ci	},
10458c2ecf20Sopenharmony_ci};
10468c2ecf20Sopenharmony_ci
10478c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ife_0_clk = {
10488c2ecf20Sopenharmony_ci	.halt_reg = 0x9024,
10498c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
10508c2ecf20Sopenharmony_ci	.clkr = {
10518c2ecf20Sopenharmony_ci		.enable_reg = 0x9024,
10528c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
10538c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
10548c2ecf20Sopenharmony_ci			.name = "cam_cc_ife_0_clk",
10558c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
10568c2ecf20Sopenharmony_ci				"cam_cc_ife_0_clk_src",
10578c2ecf20Sopenharmony_ci			},
10588c2ecf20Sopenharmony_ci			.num_parents = 1,
10598c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
10608c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
10618c2ecf20Sopenharmony_ci		},
10628c2ecf20Sopenharmony_ci	},
10638c2ecf20Sopenharmony_ci};
10648c2ecf20Sopenharmony_ci
10658c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ife_0_cphy_rx_clk = {
10668c2ecf20Sopenharmony_ci	.halt_reg = 0x9078,
10678c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
10688c2ecf20Sopenharmony_ci	.clkr = {
10698c2ecf20Sopenharmony_ci		.enable_reg = 0x9078,
10708c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
10718c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
10728c2ecf20Sopenharmony_ci			.name = "cam_cc_ife_0_cphy_rx_clk",
10738c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
10748c2ecf20Sopenharmony_ci				"cam_cc_cphy_rx_clk_src",
10758c2ecf20Sopenharmony_ci			},
10768c2ecf20Sopenharmony_ci			.num_parents = 1,
10778c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
10788c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
10798c2ecf20Sopenharmony_ci		},
10808c2ecf20Sopenharmony_ci	},
10818c2ecf20Sopenharmony_ci};
10828c2ecf20Sopenharmony_ci
10838c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ife_0_csid_clk = {
10848c2ecf20Sopenharmony_ci	.halt_reg = 0x9050,
10858c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
10868c2ecf20Sopenharmony_ci	.clkr = {
10878c2ecf20Sopenharmony_ci		.enable_reg = 0x9050,
10888c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
10898c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
10908c2ecf20Sopenharmony_ci			.name = "cam_cc_ife_0_csid_clk",
10918c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
10928c2ecf20Sopenharmony_ci				"cam_cc_ife_0_csid_clk_src",
10938c2ecf20Sopenharmony_ci			},
10948c2ecf20Sopenharmony_ci			.num_parents = 1,
10958c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
10968c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
10978c2ecf20Sopenharmony_ci		},
10988c2ecf20Sopenharmony_ci	},
10998c2ecf20Sopenharmony_ci};
11008c2ecf20Sopenharmony_ci
11018c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ife_0_dsp_clk = {
11028c2ecf20Sopenharmony_ci	.halt_reg = 0x9034,
11038c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
11048c2ecf20Sopenharmony_ci	.clkr = {
11058c2ecf20Sopenharmony_ci		.enable_reg = 0x9034,
11068c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
11078c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
11088c2ecf20Sopenharmony_ci			.name = "cam_cc_ife_0_dsp_clk",
11098c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
11108c2ecf20Sopenharmony_ci				"cam_cc_ife_0_clk_src",
11118c2ecf20Sopenharmony_ci			},
11128c2ecf20Sopenharmony_ci			.num_parents = 1,
11138c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
11148c2ecf20Sopenharmony_ci		},
11158c2ecf20Sopenharmony_ci	},
11168c2ecf20Sopenharmony_ci};
11178c2ecf20Sopenharmony_ci
11188c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ife_1_axi_clk = {
11198c2ecf20Sopenharmony_ci	.halt_reg = 0xa054,
11208c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
11218c2ecf20Sopenharmony_ci	.clkr = {
11228c2ecf20Sopenharmony_ci		.enable_reg = 0xa054,
11238c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
11248c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
11258c2ecf20Sopenharmony_ci			.name = "cam_cc_ife_1_axi_clk",
11268c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
11278c2ecf20Sopenharmony_ci		},
11288c2ecf20Sopenharmony_ci	},
11298c2ecf20Sopenharmony_ci};
11308c2ecf20Sopenharmony_ci
11318c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ife_1_clk = {
11328c2ecf20Sopenharmony_ci	.halt_reg = 0xa024,
11338c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
11348c2ecf20Sopenharmony_ci	.clkr = {
11358c2ecf20Sopenharmony_ci		.enable_reg = 0xa024,
11368c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
11378c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
11388c2ecf20Sopenharmony_ci			.name = "cam_cc_ife_1_clk",
11398c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
11408c2ecf20Sopenharmony_ci				"cam_cc_ife_1_clk_src",
11418c2ecf20Sopenharmony_ci			},
11428c2ecf20Sopenharmony_ci			.num_parents = 1,
11438c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
11448c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
11458c2ecf20Sopenharmony_ci		},
11468c2ecf20Sopenharmony_ci	},
11478c2ecf20Sopenharmony_ci};
11488c2ecf20Sopenharmony_ci
11498c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ife_1_cphy_rx_clk = {
11508c2ecf20Sopenharmony_ci	.halt_reg = 0xa050,
11518c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
11528c2ecf20Sopenharmony_ci	.clkr = {
11538c2ecf20Sopenharmony_ci		.enable_reg = 0xa050,
11548c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
11558c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
11568c2ecf20Sopenharmony_ci			.name = "cam_cc_ife_1_cphy_rx_clk",
11578c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
11588c2ecf20Sopenharmony_ci				"cam_cc_cphy_rx_clk_src",
11598c2ecf20Sopenharmony_ci			},
11608c2ecf20Sopenharmony_ci			.num_parents = 1,
11618c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
11628c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
11638c2ecf20Sopenharmony_ci		},
11648c2ecf20Sopenharmony_ci	},
11658c2ecf20Sopenharmony_ci};
11668c2ecf20Sopenharmony_ci
11678c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ife_1_csid_clk = {
11688c2ecf20Sopenharmony_ci	.halt_reg = 0xa048,
11698c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
11708c2ecf20Sopenharmony_ci	.clkr = {
11718c2ecf20Sopenharmony_ci		.enable_reg = 0xa048,
11728c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
11738c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
11748c2ecf20Sopenharmony_ci			.name = "cam_cc_ife_1_csid_clk",
11758c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
11768c2ecf20Sopenharmony_ci				"cam_cc_ife_1_csid_clk_src",
11778c2ecf20Sopenharmony_ci			},
11788c2ecf20Sopenharmony_ci			.num_parents = 1,
11798c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
11808c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
11818c2ecf20Sopenharmony_ci		},
11828c2ecf20Sopenharmony_ci	},
11838c2ecf20Sopenharmony_ci};
11848c2ecf20Sopenharmony_ci
11858c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ife_1_dsp_clk = {
11868c2ecf20Sopenharmony_ci	.halt_reg = 0xa02c,
11878c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
11888c2ecf20Sopenharmony_ci	.clkr = {
11898c2ecf20Sopenharmony_ci		.enable_reg = 0xa02c,
11908c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
11918c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
11928c2ecf20Sopenharmony_ci			.name = "cam_cc_ife_1_dsp_clk",
11938c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
11948c2ecf20Sopenharmony_ci				"cam_cc_ife_1_clk_src",
11958c2ecf20Sopenharmony_ci			},
11968c2ecf20Sopenharmony_ci			.num_parents = 1,
11978c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
11988c2ecf20Sopenharmony_ci		},
11998c2ecf20Sopenharmony_ci	},
12008c2ecf20Sopenharmony_ci};
12018c2ecf20Sopenharmony_ci
12028c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ife_lite_clk = {
12038c2ecf20Sopenharmony_ci	.halt_reg = 0xb01c,
12048c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
12058c2ecf20Sopenharmony_ci	.clkr = {
12068c2ecf20Sopenharmony_ci		.enable_reg = 0xb01c,
12078c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
12088c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
12098c2ecf20Sopenharmony_ci			.name = "cam_cc_ife_lite_clk",
12108c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
12118c2ecf20Sopenharmony_ci				"cam_cc_ife_lite_clk_src",
12128c2ecf20Sopenharmony_ci			},
12138c2ecf20Sopenharmony_ci			.num_parents = 1,
12148c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
12158c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
12168c2ecf20Sopenharmony_ci		},
12178c2ecf20Sopenharmony_ci	},
12188c2ecf20Sopenharmony_ci};
12198c2ecf20Sopenharmony_ci
12208c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ife_lite_cphy_rx_clk = {
12218c2ecf20Sopenharmony_ci	.halt_reg = 0xb044,
12228c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
12238c2ecf20Sopenharmony_ci	.clkr = {
12248c2ecf20Sopenharmony_ci		.enable_reg = 0xb044,
12258c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
12268c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
12278c2ecf20Sopenharmony_ci			.name = "cam_cc_ife_lite_cphy_rx_clk",
12288c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
12298c2ecf20Sopenharmony_ci				"cam_cc_cphy_rx_clk_src",
12308c2ecf20Sopenharmony_ci			},
12318c2ecf20Sopenharmony_ci			.num_parents = 1,
12328c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
12338c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
12348c2ecf20Sopenharmony_ci		},
12358c2ecf20Sopenharmony_ci	},
12368c2ecf20Sopenharmony_ci};
12378c2ecf20Sopenharmony_ci
12388c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ife_lite_csid_clk = {
12398c2ecf20Sopenharmony_ci	.halt_reg = 0xb03c,
12408c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
12418c2ecf20Sopenharmony_ci	.clkr = {
12428c2ecf20Sopenharmony_ci		.enable_reg = 0xb03c,
12438c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
12448c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
12458c2ecf20Sopenharmony_ci			.name = "cam_cc_ife_lite_csid_clk",
12468c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
12478c2ecf20Sopenharmony_ci				"cam_cc_ife_lite_csid_clk_src",
12488c2ecf20Sopenharmony_ci			},
12498c2ecf20Sopenharmony_ci			.num_parents = 1,
12508c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
12518c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
12528c2ecf20Sopenharmony_ci		},
12538c2ecf20Sopenharmony_ci	},
12548c2ecf20Sopenharmony_ci};
12558c2ecf20Sopenharmony_ci
12568c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ipe_0_ahb_clk = {
12578c2ecf20Sopenharmony_ci	.halt_reg = 0x703c,
12588c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
12598c2ecf20Sopenharmony_ci	.clkr = {
12608c2ecf20Sopenharmony_ci		.enable_reg = 0x703c,
12618c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
12628c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
12638c2ecf20Sopenharmony_ci			.name = "cam_cc_ipe_0_ahb_clk",
12648c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
12658c2ecf20Sopenharmony_ci				"cam_cc_slow_ahb_clk_src",
12668c2ecf20Sopenharmony_ci			},
12678c2ecf20Sopenharmony_ci			.num_parents = 1,
12688c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
12698c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
12708c2ecf20Sopenharmony_ci		},
12718c2ecf20Sopenharmony_ci	},
12728c2ecf20Sopenharmony_ci};
12738c2ecf20Sopenharmony_ci
12748c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ipe_0_areg_clk = {
12758c2ecf20Sopenharmony_ci	.halt_reg = 0x7038,
12768c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
12778c2ecf20Sopenharmony_ci	.clkr = {
12788c2ecf20Sopenharmony_ci		.enable_reg = 0x7038,
12798c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
12808c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
12818c2ecf20Sopenharmony_ci			.name = "cam_cc_ipe_0_areg_clk",
12828c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
12838c2ecf20Sopenharmony_ci				"cam_cc_fast_ahb_clk_src",
12848c2ecf20Sopenharmony_ci			},
12858c2ecf20Sopenharmony_ci			.num_parents = 1,
12868c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
12878c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
12888c2ecf20Sopenharmony_ci		},
12898c2ecf20Sopenharmony_ci	},
12908c2ecf20Sopenharmony_ci};
12918c2ecf20Sopenharmony_ci
12928c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ipe_0_axi_clk = {
12938c2ecf20Sopenharmony_ci	.halt_reg = 0x7034,
12948c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
12958c2ecf20Sopenharmony_ci	.clkr = {
12968c2ecf20Sopenharmony_ci		.enable_reg = 0x7034,
12978c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
12988c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
12998c2ecf20Sopenharmony_ci			.name = "cam_cc_ipe_0_axi_clk",
13008c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
13018c2ecf20Sopenharmony_ci		},
13028c2ecf20Sopenharmony_ci	},
13038c2ecf20Sopenharmony_ci};
13048c2ecf20Sopenharmony_ci
13058c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ipe_0_clk = {
13068c2ecf20Sopenharmony_ci	.halt_reg = 0x7024,
13078c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
13088c2ecf20Sopenharmony_ci	.clkr = {
13098c2ecf20Sopenharmony_ci		.enable_reg = 0x7024,
13108c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
13118c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
13128c2ecf20Sopenharmony_ci			.name = "cam_cc_ipe_0_clk",
13138c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
13148c2ecf20Sopenharmony_ci				"cam_cc_ipe_0_clk_src",
13158c2ecf20Sopenharmony_ci			},
13168c2ecf20Sopenharmony_ci			.num_parents = 1,
13178c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
13188c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
13198c2ecf20Sopenharmony_ci		},
13208c2ecf20Sopenharmony_ci	},
13218c2ecf20Sopenharmony_ci};
13228c2ecf20Sopenharmony_ci
13238c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ipe_1_ahb_clk = {
13248c2ecf20Sopenharmony_ci	.halt_reg = 0x803c,
13258c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
13268c2ecf20Sopenharmony_ci	.clkr = {
13278c2ecf20Sopenharmony_ci		.enable_reg = 0x803c,
13288c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
13298c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
13308c2ecf20Sopenharmony_ci			.name = "cam_cc_ipe_1_ahb_clk",
13318c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
13328c2ecf20Sopenharmony_ci				"cam_cc_slow_ahb_clk_src",
13338c2ecf20Sopenharmony_ci			},
13348c2ecf20Sopenharmony_ci			.num_parents = 1,
13358c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
13368c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
13378c2ecf20Sopenharmony_ci		},
13388c2ecf20Sopenharmony_ci	},
13398c2ecf20Sopenharmony_ci};
13408c2ecf20Sopenharmony_ci
13418c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ipe_1_areg_clk = {
13428c2ecf20Sopenharmony_ci	.halt_reg = 0x8038,
13438c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
13448c2ecf20Sopenharmony_ci	.clkr = {
13458c2ecf20Sopenharmony_ci		.enable_reg = 0x8038,
13468c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
13478c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
13488c2ecf20Sopenharmony_ci			.name = "cam_cc_ipe_1_areg_clk",
13498c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
13508c2ecf20Sopenharmony_ci				"cam_cc_fast_ahb_clk_src",
13518c2ecf20Sopenharmony_ci			},
13528c2ecf20Sopenharmony_ci			.num_parents = 1,
13538c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
13548c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
13558c2ecf20Sopenharmony_ci		},
13568c2ecf20Sopenharmony_ci	},
13578c2ecf20Sopenharmony_ci};
13588c2ecf20Sopenharmony_ci
13598c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ipe_1_axi_clk = {
13608c2ecf20Sopenharmony_ci	.halt_reg = 0x8034,
13618c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
13628c2ecf20Sopenharmony_ci	.clkr = {
13638c2ecf20Sopenharmony_ci		.enable_reg = 0x8034,
13648c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
13658c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
13668c2ecf20Sopenharmony_ci			.name = "cam_cc_ipe_1_axi_clk",
13678c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
13688c2ecf20Sopenharmony_ci		},
13698c2ecf20Sopenharmony_ci	},
13708c2ecf20Sopenharmony_ci};
13718c2ecf20Sopenharmony_ci
13728c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_ipe_1_clk = {
13738c2ecf20Sopenharmony_ci	.halt_reg = 0x8024,
13748c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
13758c2ecf20Sopenharmony_ci	.clkr = {
13768c2ecf20Sopenharmony_ci		.enable_reg = 0x8024,
13778c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
13788c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
13798c2ecf20Sopenharmony_ci			.name = "cam_cc_ipe_1_clk",
13808c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
13818c2ecf20Sopenharmony_ci				"cam_cc_ipe_1_clk_src",
13828c2ecf20Sopenharmony_ci			},
13838c2ecf20Sopenharmony_ci			.num_parents = 1,
13848c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
13858c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
13868c2ecf20Sopenharmony_ci		},
13878c2ecf20Sopenharmony_ci	},
13888c2ecf20Sopenharmony_ci};
13898c2ecf20Sopenharmony_ci
13908c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_jpeg_clk = {
13918c2ecf20Sopenharmony_ci	.halt_reg = 0xb064,
13928c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
13938c2ecf20Sopenharmony_ci	.clkr = {
13948c2ecf20Sopenharmony_ci		.enable_reg = 0xb064,
13958c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
13968c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
13978c2ecf20Sopenharmony_ci			.name = "cam_cc_jpeg_clk",
13988c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
13998c2ecf20Sopenharmony_ci				"cam_cc_jpeg_clk_src",
14008c2ecf20Sopenharmony_ci			},
14018c2ecf20Sopenharmony_ci			.num_parents = 1,
14028c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
14038c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
14048c2ecf20Sopenharmony_ci		},
14058c2ecf20Sopenharmony_ci	},
14068c2ecf20Sopenharmony_ci};
14078c2ecf20Sopenharmony_ci
14088c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_lrme_clk = {
14098c2ecf20Sopenharmony_ci	.halt_reg = 0xb110,
14108c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
14118c2ecf20Sopenharmony_ci	.clkr = {
14128c2ecf20Sopenharmony_ci		.enable_reg = 0xb110,
14138c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
14148c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
14158c2ecf20Sopenharmony_ci			.name = "cam_cc_lrme_clk",
14168c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
14178c2ecf20Sopenharmony_ci				"cam_cc_lrme_clk_src",
14188c2ecf20Sopenharmony_ci			},
14198c2ecf20Sopenharmony_ci			.num_parents = 1,
14208c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
14218c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
14228c2ecf20Sopenharmony_ci		},
14238c2ecf20Sopenharmony_ci	},
14248c2ecf20Sopenharmony_ci};
14258c2ecf20Sopenharmony_ci
14268c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_mclk0_clk = {
14278c2ecf20Sopenharmony_ci	.halt_reg = 0x401c,
14288c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
14298c2ecf20Sopenharmony_ci	.clkr = {
14308c2ecf20Sopenharmony_ci		.enable_reg = 0x401c,
14318c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
14328c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
14338c2ecf20Sopenharmony_ci			.name = "cam_cc_mclk0_clk",
14348c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
14358c2ecf20Sopenharmony_ci				"cam_cc_mclk0_clk_src",
14368c2ecf20Sopenharmony_ci			},
14378c2ecf20Sopenharmony_ci			.num_parents = 1,
14388c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
14398c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
14408c2ecf20Sopenharmony_ci		},
14418c2ecf20Sopenharmony_ci	},
14428c2ecf20Sopenharmony_ci};
14438c2ecf20Sopenharmony_ci
14448c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_mclk1_clk = {
14458c2ecf20Sopenharmony_ci	.halt_reg = 0x403c,
14468c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
14478c2ecf20Sopenharmony_ci	.clkr = {
14488c2ecf20Sopenharmony_ci		.enable_reg = 0x403c,
14498c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
14508c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
14518c2ecf20Sopenharmony_ci			.name = "cam_cc_mclk1_clk",
14528c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
14538c2ecf20Sopenharmony_ci				"cam_cc_mclk1_clk_src",
14548c2ecf20Sopenharmony_ci			},
14558c2ecf20Sopenharmony_ci			.num_parents = 1,
14568c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
14578c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
14588c2ecf20Sopenharmony_ci		},
14598c2ecf20Sopenharmony_ci	},
14608c2ecf20Sopenharmony_ci};
14618c2ecf20Sopenharmony_ci
14628c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_mclk2_clk = {
14638c2ecf20Sopenharmony_ci	.halt_reg = 0x405c,
14648c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
14658c2ecf20Sopenharmony_ci	.clkr = {
14668c2ecf20Sopenharmony_ci		.enable_reg = 0x405c,
14678c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
14688c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
14698c2ecf20Sopenharmony_ci			.name = "cam_cc_mclk2_clk",
14708c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
14718c2ecf20Sopenharmony_ci				"cam_cc_mclk2_clk_src",
14728c2ecf20Sopenharmony_ci			},
14738c2ecf20Sopenharmony_ci			.num_parents = 1,
14748c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
14758c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
14768c2ecf20Sopenharmony_ci		},
14778c2ecf20Sopenharmony_ci	},
14788c2ecf20Sopenharmony_ci};
14798c2ecf20Sopenharmony_ci
14808c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_mclk3_clk = {
14818c2ecf20Sopenharmony_ci	.halt_reg = 0x407c,
14828c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
14838c2ecf20Sopenharmony_ci	.clkr = {
14848c2ecf20Sopenharmony_ci		.enable_reg = 0x407c,
14858c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
14868c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
14878c2ecf20Sopenharmony_ci			.name = "cam_cc_mclk3_clk",
14888c2ecf20Sopenharmony_ci			.parent_names = (const char *[]){
14898c2ecf20Sopenharmony_ci				"cam_cc_mclk3_clk_src",
14908c2ecf20Sopenharmony_ci			},
14918c2ecf20Sopenharmony_ci			.num_parents = 1,
14928c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
14938c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
14948c2ecf20Sopenharmony_ci		},
14958c2ecf20Sopenharmony_ci	},
14968c2ecf20Sopenharmony_ci};
14978c2ecf20Sopenharmony_ci
14988c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_soc_ahb_clk = {
14998c2ecf20Sopenharmony_ci	.halt_reg = 0xb13c,
15008c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
15018c2ecf20Sopenharmony_ci	.clkr = {
15028c2ecf20Sopenharmony_ci		.enable_reg = 0xb13c,
15038c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
15048c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
15058c2ecf20Sopenharmony_ci			.name = "cam_cc_soc_ahb_clk",
15068c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
15078c2ecf20Sopenharmony_ci		},
15088c2ecf20Sopenharmony_ci	},
15098c2ecf20Sopenharmony_ci};
15108c2ecf20Sopenharmony_ci
15118c2ecf20Sopenharmony_cistatic struct clk_branch cam_cc_sys_tmr_clk = {
15128c2ecf20Sopenharmony_ci	.halt_reg = 0xb0a8,
15138c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
15148c2ecf20Sopenharmony_ci	.clkr = {
15158c2ecf20Sopenharmony_ci		.enable_reg = 0xb0a8,
15168c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
15178c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
15188c2ecf20Sopenharmony_ci			.name = "cam_cc_sys_tmr_clk",
15198c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
15208c2ecf20Sopenharmony_ci		},
15218c2ecf20Sopenharmony_ci	},
15228c2ecf20Sopenharmony_ci};
15238c2ecf20Sopenharmony_ci
15248c2ecf20Sopenharmony_cistatic struct gdsc titan_top_gdsc;
15258c2ecf20Sopenharmony_ci
15268c2ecf20Sopenharmony_cistatic struct gdsc bps_gdsc = {
15278c2ecf20Sopenharmony_ci	.gdscr = 0x6004,
15288c2ecf20Sopenharmony_ci	.pd = {
15298c2ecf20Sopenharmony_ci		.name = "bps_gdsc",
15308c2ecf20Sopenharmony_ci	},
15318c2ecf20Sopenharmony_ci	.flags = HW_CTRL | POLL_CFG_GDSCR,
15328c2ecf20Sopenharmony_ci	.pwrsts = PWRSTS_OFF_ON,
15338c2ecf20Sopenharmony_ci};
15348c2ecf20Sopenharmony_ci
15358c2ecf20Sopenharmony_cistatic struct gdsc ipe_0_gdsc = {
15368c2ecf20Sopenharmony_ci	.gdscr = 0x7004,
15378c2ecf20Sopenharmony_ci	.pd = {
15388c2ecf20Sopenharmony_ci		.name = "ipe_0_gdsc",
15398c2ecf20Sopenharmony_ci	},
15408c2ecf20Sopenharmony_ci	.flags = HW_CTRL | POLL_CFG_GDSCR,
15418c2ecf20Sopenharmony_ci	.pwrsts = PWRSTS_OFF_ON,
15428c2ecf20Sopenharmony_ci};
15438c2ecf20Sopenharmony_ci
15448c2ecf20Sopenharmony_cistatic struct gdsc ipe_1_gdsc = {
15458c2ecf20Sopenharmony_ci	.gdscr = 0x8004,
15468c2ecf20Sopenharmony_ci	.pd = {
15478c2ecf20Sopenharmony_ci		.name = "ipe_1_gdsc",
15488c2ecf20Sopenharmony_ci	},
15498c2ecf20Sopenharmony_ci	.flags = HW_CTRL | POLL_CFG_GDSCR,
15508c2ecf20Sopenharmony_ci	.pwrsts = PWRSTS_OFF_ON,
15518c2ecf20Sopenharmony_ci};
15528c2ecf20Sopenharmony_ci
15538c2ecf20Sopenharmony_cistatic struct gdsc ife_0_gdsc = {
15548c2ecf20Sopenharmony_ci	.gdscr = 0x9004,
15558c2ecf20Sopenharmony_ci	.pd = {
15568c2ecf20Sopenharmony_ci		.name = "ife_0_gdsc",
15578c2ecf20Sopenharmony_ci	},
15588c2ecf20Sopenharmony_ci	.flags = POLL_CFG_GDSCR,
15598c2ecf20Sopenharmony_ci	.parent = &titan_top_gdsc.pd,
15608c2ecf20Sopenharmony_ci	.pwrsts = PWRSTS_OFF_ON,
15618c2ecf20Sopenharmony_ci};
15628c2ecf20Sopenharmony_ci
15638c2ecf20Sopenharmony_cistatic struct gdsc ife_1_gdsc = {
15648c2ecf20Sopenharmony_ci	.gdscr = 0xa004,
15658c2ecf20Sopenharmony_ci	.pd = {
15668c2ecf20Sopenharmony_ci		.name = "ife_1_gdsc",
15678c2ecf20Sopenharmony_ci	},
15688c2ecf20Sopenharmony_ci	.flags = POLL_CFG_GDSCR,
15698c2ecf20Sopenharmony_ci	.parent = &titan_top_gdsc.pd,
15708c2ecf20Sopenharmony_ci	.pwrsts = PWRSTS_OFF_ON,
15718c2ecf20Sopenharmony_ci};
15728c2ecf20Sopenharmony_ci
15738c2ecf20Sopenharmony_cistatic struct gdsc titan_top_gdsc = {
15748c2ecf20Sopenharmony_ci	.gdscr = 0xb134,
15758c2ecf20Sopenharmony_ci	.pd = {
15768c2ecf20Sopenharmony_ci		.name = "titan_top_gdsc",
15778c2ecf20Sopenharmony_ci	},
15788c2ecf20Sopenharmony_ci	.flags = POLL_CFG_GDSCR,
15798c2ecf20Sopenharmony_ci	.pwrsts = PWRSTS_OFF_ON,
15808c2ecf20Sopenharmony_ci};
15818c2ecf20Sopenharmony_ci
15828c2ecf20Sopenharmony_cistatic struct clk_regmap *cam_cc_sdm845_clocks[] = {
15838c2ecf20Sopenharmony_ci	[CAM_CC_BPS_AHB_CLK] = &cam_cc_bps_ahb_clk.clkr,
15848c2ecf20Sopenharmony_ci	[CAM_CC_BPS_AREG_CLK] = &cam_cc_bps_areg_clk.clkr,
15858c2ecf20Sopenharmony_ci	[CAM_CC_BPS_AXI_CLK] = &cam_cc_bps_axi_clk.clkr,
15868c2ecf20Sopenharmony_ci	[CAM_CC_BPS_CLK] = &cam_cc_bps_clk.clkr,
15878c2ecf20Sopenharmony_ci	[CAM_CC_BPS_CLK_SRC] = &cam_cc_bps_clk_src.clkr,
15888c2ecf20Sopenharmony_ci	[CAM_CC_CAMNOC_ATB_CLK] = &cam_cc_camnoc_atb_clk.clkr,
15898c2ecf20Sopenharmony_ci	[CAM_CC_CAMNOC_AXI_CLK] = &cam_cc_camnoc_axi_clk.clkr,
15908c2ecf20Sopenharmony_ci	[CAM_CC_CCI_CLK] = &cam_cc_cci_clk.clkr,
15918c2ecf20Sopenharmony_ci	[CAM_CC_CCI_CLK_SRC] = &cam_cc_cci_clk_src.clkr,
15928c2ecf20Sopenharmony_ci	[CAM_CC_CPAS_AHB_CLK] = &cam_cc_cpas_ahb_clk.clkr,
15938c2ecf20Sopenharmony_ci	[CAM_CC_CPHY_RX_CLK_SRC] = &cam_cc_cphy_rx_clk_src.clkr,
15948c2ecf20Sopenharmony_ci	[CAM_CC_CSI0PHYTIMER_CLK] = &cam_cc_csi0phytimer_clk.clkr,
15958c2ecf20Sopenharmony_ci	[CAM_CC_CSI0PHYTIMER_CLK_SRC] = &cam_cc_csi0phytimer_clk_src.clkr,
15968c2ecf20Sopenharmony_ci	[CAM_CC_CSI1PHYTIMER_CLK] = &cam_cc_csi1phytimer_clk.clkr,
15978c2ecf20Sopenharmony_ci	[CAM_CC_CSI1PHYTIMER_CLK_SRC] = &cam_cc_csi1phytimer_clk_src.clkr,
15988c2ecf20Sopenharmony_ci	[CAM_CC_CSI2PHYTIMER_CLK] = &cam_cc_csi2phytimer_clk.clkr,
15998c2ecf20Sopenharmony_ci	[CAM_CC_CSI2PHYTIMER_CLK_SRC] = &cam_cc_csi2phytimer_clk_src.clkr,
16008c2ecf20Sopenharmony_ci	[CAM_CC_CSI3PHYTIMER_CLK] = &cam_cc_csi3phytimer_clk.clkr,
16018c2ecf20Sopenharmony_ci	[CAM_CC_CSI3PHYTIMER_CLK_SRC] = &cam_cc_csi3phytimer_clk_src.clkr,
16028c2ecf20Sopenharmony_ci	[CAM_CC_CSIPHY0_CLK] = &cam_cc_csiphy0_clk.clkr,
16038c2ecf20Sopenharmony_ci	[CAM_CC_CSIPHY1_CLK] = &cam_cc_csiphy1_clk.clkr,
16048c2ecf20Sopenharmony_ci	[CAM_CC_CSIPHY2_CLK] = &cam_cc_csiphy2_clk.clkr,
16058c2ecf20Sopenharmony_ci	[CAM_CC_CSIPHY3_CLK] = &cam_cc_csiphy3_clk.clkr,
16068c2ecf20Sopenharmony_ci	[CAM_CC_FAST_AHB_CLK_SRC] = &cam_cc_fast_ahb_clk_src.clkr,
16078c2ecf20Sopenharmony_ci	[CAM_CC_FD_CORE_CLK] = &cam_cc_fd_core_clk.clkr,
16088c2ecf20Sopenharmony_ci	[CAM_CC_FD_CORE_CLK_SRC] = &cam_cc_fd_core_clk_src.clkr,
16098c2ecf20Sopenharmony_ci	[CAM_CC_FD_CORE_UAR_CLK] = &cam_cc_fd_core_uar_clk.clkr,
16108c2ecf20Sopenharmony_ci	[CAM_CC_ICP_APB_CLK] = &cam_cc_icp_apb_clk.clkr,
16118c2ecf20Sopenharmony_ci	[CAM_CC_ICP_ATB_CLK] = &cam_cc_icp_atb_clk.clkr,
16128c2ecf20Sopenharmony_ci	[CAM_CC_ICP_CLK] = &cam_cc_icp_clk.clkr,
16138c2ecf20Sopenharmony_ci	[CAM_CC_ICP_CLK_SRC] = &cam_cc_icp_clk_src.clkr,
16148c2ecf20Sopenharmony_ci	[CAM_CC_ICP_CTI_CLK] = &cam_cc_icp_cti_clk.clkr,
16158c2ecf20Sopenharmony_ci	[CAM_CC_ICP_TS_CLK] = &cam_cc_icp_ts_clk.clkr,
16168c2ecf20Sopenharmony_ci	[CAM_CC_IFE_0_AXI_CLK] = &cam_cc_ife_0_axi_clk.clkr,
16178c2ecf20Sopenharmony_ci	[CAM_CC_IFE_0_CLK] = &cam_cc_ife_0_clk.clkr,
16188c2ecf20Sopenharmony_ci	[CAM_CC_IFE_0_CLK_SRC] = &cam_cc_ife_0_clk_src.clkr,
16198c2ecf20Sopenharmony_ci	[CAM_CC_IFE_0_CPHY_RX_CLK] = &cam_cc_ife_0_cphy_rx_clk.clkr,
16208c2ecf20Sopenharmony_ci	[CAM_CC_IFE_0_CSID_CLK] = &cam_cc_ife_0_csid_clk.clkr,
16218c2ecf20Sopenharmony_ci	[CAM_CC_IFE_0_CSID_CLK_SRC] = &cam_cc_ife_0_csid_clk_src.clkr,
16228c2ecf20Sopenharmony_ci	[CAM_CC_IFE_0_DSP_CLK] = &cam_cc_ife_0_dsp_clk.clkr,
16238c2ecf20Sopenharmony_ci	[CAM_CC_IFE_1_AXI_CLK] = &cam_cc_ife_1_axi_clk.clkr,
16248c2ecf20Sopenharmony_ci	[CAM_CC_IFE_1_CLK] = &cam_cc_ife_1_clk.clkr,
16258c2ecf20Sopenharmony_ci	[CAM_CC_IFE_1_CLK_SRC] = &cam_cc_ife_1_clk_src.clkr,
16268c2ecf20Sopenharmony_ci	[CAM_CC_IFE_1_CPHY_RX_CLK] = &cam_cc_ife_1_cphy_rx_clk.clkr,
16278c2ecf20Sopenharmony_ci	[CAM_CC_IFE_1_CSID_CLK] = &cam_cc_ife_1_csid_clk.clkr,
16288c2ecf20Sopenharmony_ci	[CAM_CC_IFE_1_CSID_CLK_SRC] = &cam_cc_ife_1_csid_clk_src.clkr,
16298c2ecf20Sopenharmony_ci	[CAM_CC_IFE_1_DSP_CLK] = &cam_cc_ife_1_dsp_clk.clkr,
16308c2ecf20Sopenharmony_ci	[CAM_CC_IFE_LITE_CLK] = &cam_cc_ife_lite_clk.clkr,
16318c2ecf20Sopenharmony_ci	[CAM_CC_IFE_LITE_CLK_SRC] = &cam_cc_ife_lite_clk_src.clkr,
16328c2ecf20Sopenharmony_ci	[CAM_CC_IFE_LITE_CPHY_RX_CLK] = &cam_cc_ife_lite_cphy_rx_clk.clkr,
16338c2ecf20Sopenharmony_ci	[CAM_CC_IFE_LITE_CSID_CLK] = &cam_cc_ife_lite_csid_clk.clkr,
16348c2ecf20Sopenharmony_ci	[CAM_CC_IFE_LITE_CSID_CLK_SRC] = &cam_cc_ife_lite_csid_clk_src.clkr,
16358c2ecf20Sopenharmony_ci	[CAM_CC_IPE_0_AHB_CLK] = &cam_cc_ipe_0_ahb_clk.clkr,
16368c2ecf20Sopenharmony_ci	[CAM_CC_IPE_0_AREG_CLK] = &cam_cc_ipe_0_areg_clk.clkr,
16378c2ecf20Sopenharmony_ci	[CAM_CC_IPE_0_AXI_CLK] = &cam_cc_ipe_0_axi_clk.clkr,
16388c2ecf20Sopenharmony_ci	[CAM_CC_IPE_0_CLK] = &cam_cc_ipe_0_clk.clkr,
16398c2ecf20Sopenharmony_ci	[CAM_CC_IPE_0_CLK_SRC] = &cam_cc_ipe_0_clk_src.clkr,
16408c2ecf20Sopenharmony_ci	[CAM_CC_IPE_1_AHB_CLK] = &cam_cc_ipe_1_ahb_clk.clkr,
16418c2ecf20Sopenharmony_ci	[CAM_CC_IPE_1_AREG_CLK] = &cam_cc_ipe_1_areg_clk.clkr,
16428c2ecf20Sopenharmony_ci	[CAM_CC_IPE_1_AXI_CLK] = &cam_cc_ipe_1_axi_clk.clkr,
16438c2ecf20Sopenharmony_ci	[CAM_CC_IPE_1_CLK] = &cam_cc_ipe_1_clk.clkr,
16448c2ecf20Sopenharmony_ci	[CAM_CC_IPE_1_CLK_SRC] = &cam_cc_ipe_1_clk_src.clkr,
16458c2ecf20Sopenharmony_ci	[CAM_CC_JPEG_CLK] = &cam_cc_jpeg_clk.clkr,
16468c2ecf20Sopenharmony_ci	[CAM_CC_JPEG_CLK_SRC] = &cam_cc_jpeg_clk_src.clkr,
16478c2ecf20Sopenharmony_ci	[CAM_CC_LRME_CLK] = &cam_cc_lrme_clk.clkr,
16488c2ecf20Sopenharmony_ci	[CAM_CC_LRME_CLK_SRC] = &cam_cc_lrme_clk_src.clkr,
16498c2ecf20Sopenharmony_ci	[CAM_CC_MCLK0_CLK] = &cam_cc_mclk0_clk.clkr,
16508c2ecf20Sopenharmony_ci	[CAM_CC_MCLK0_CLK_SRC] = &cam_cc_mclk0_clk_src.clkr,
16518c2ecf20Sopenharmony_ci	[CAM_CC_MCLK1_CLK] = &cam_cc_mclk1_clk.clkr,
16528c2ecf20Sopenharmony_ci	[CAM_CC_MCLK1_CLK_SRC] = &cam_cc_mclk1_clk_src.clkr,
16538c2ecf20Sopenharmony_ci	[CAM_CC_MCLK2_CLK] = &cam_cc_mclk2_clk.clkr,
16548c2ecf20Sopenharmony_ci	[CAM_CC_MCLK2_CLK_SRC] = &cam_cc_mclk2_clk_src.clkr,
16558c2ecf20Sopenharmony_ci	[CAM_CC_MCLK3_CLK] = &cam_cc_mclk3_clk.clkr,
16568c2ecf20Sopenharmony_ci	[CAM_CC_MCLK3_CLK_SRC] = &cam_cc_mclk3_clk_src.clkr,
16578c2ecf20Sopenharmony_ci	[CAM_CC_PLL0] = &cam_cc_pll0.clkr,
16588c2ecf20Sopenharmony_ci	[CAM_CC_PLL0_OUT_EVEN] = &cam_cc_pll0_out_even.clkr,
16598c2ecf20Sopenharmony_ci	[CAM_CC_PLL1] = &cam_cc_pll1.clkr,
16608c2ecf20Sopenharmony_ci	[CAM_CC_PLL1_OUT_EVEN] = &cam_cc_pll1_out_even.clkr,
16618c2ecf20Sopenharmony_ci	[CAM_CC_PLL2] = &cam_cc_pll2.clkr,
16628c2ecf20Sopenharmony_ci	[CAM_CC_PLL2_OUT_EVEN] = &cam_cc_pll2_out_even.clkr,
16638c2ecf20Sopenharmony_ci	[CAM_CC_PLL3] = &cam_cc_pll3.clkr,
16648c2ecf20Sopenharmony_ci	[CAM_CC_PLL3_OUT_EVEN] = &cam_cc_pll3_out_even.clkr,
16658c2ecf20Sopenharmony_ci	[CAM_CC_SLOW_AHB_CLK_SRC] = &cam_cc_slow_ahb_clk_src.clkr,
16668c2ecf20Sopenharmony_ci	[CAM_CC_SOC_AHB_CLK] = &cam_cc_soc_ahb_clk.clkr,
16678c2ecf20Sopenharmony_ci	[CAM_CC_SYS_TMR_CLK] = &cam_cc_sys_tmr_clk.clkr,
16688c2ecf20Sopenharmony_ci};
16698c2ecf20Sopenharmony_ci
16708c2ecf20Sopenharmony_cistatic struct gdsc *cam_cc_sdm845_gdscs[] = {
16718c2ecf20Sopenharmony_ci	[BPS_GDSC] = &bps_gdsc,
16728c2ecf20Sopenharmony_ci	[IPE_0_GDSC] = &ipe_0_gdsc,
16738c2ecf20Sopenharmony_ci	[IPE_1_GDSC] = &ipe_1_gdsc,
16748c2ecf20Sopenharmony_ci	[IFE_0_GDSC] = &ife_0_gdsc,
16758c2ecf20Sopenharmony_ci	[IFE_1_GDSC] = &ife_1_gdsc,
16768c2ecf20Sopenharmony_ci	[TITAN_TOP_GDSC] = &titan_top_gdsc,
16778c2ecf20Sopenharmony_ci};
16788c2ecf20Sopenharmony_ci
16798c2ecf20Sopenharmony_cistatic const struct regmap_config cam_cc_sdm845_regmap_config = {
16808c2ecf20Sopenharmony_ci	.reg_bits	= 32,
16818c2ecf20Sopenharmony_ci	.reg_stride	= 4,
16828c2ecf20Sopenharmony_ci	.val_bits	= 32,
16838c2ecf20Sopenharmony_ci	.max_register	= 0xd004,
16848c2ecf20Sopenharmony_ci	.fast_io	= true,
16858c2ecf20Sopenharmony_ci};
16868c2ecf20Sopenharmony_ci
16878c2ecf20Sopenharmony_cistatic const struct qcom_cc_desc cam_cc_sdm845_desc = {
16888c2ecf20Sopenharmony_ci	.config = &cam_cc_sdm845_regmap_config,
16898c2ecf20Sopenharmony_ci	.clks = cam_cc_sdm845_clocks,
16908c2ecf20Sopenharmony_ci	.num_clks = ARRAY_SIZE(cam_cc_sdm845_clocks),
16918c2ecf20Sopenharmony_ci	.gdscs = cam_cc_sdm845_gdscs,
16928c2ecf20Sopenharmony_ci	.num_gdscs = ARRAY_SIZE(cam_cc_sdm845_gdscs),
16938c2ecf20Sopenharmony_ci};
16948c2ecf20Sopenharmony_ci
16958c2ecf20Sopenharmony_cistatic const struct of_device_id cam_cc_sdm845_match_table[] = {
16968c2ecf20Sopenharmony_ci	{ .compatible = "qcom,sdm845-camcc" },
16978c2ecf20Sopenharmony_ci	{ }
16988c2ecf20Sopenharmony_ci};
16998c2ecf20Sopenharmony_ciMODULE_DEVICE_TABLE(of, cam_cc_sdm845_match_table);
17008c2ecf20Sopenharmony_ci
17018c2ecf20Sopenharmony_cistatic int cam_cc_sdm845_probe(struct platform_device *pdev)
17028c2ecf20Sopenharmony_ci{
17038c2ecf20Sopenharmony_ci	struct regmap *regmap;
17048c2ecf20Sopenharmony_ci	struct alpha_pll_config cam_cc_pll_config = { };
17058c2ecf20Sopenharmony_ci
17068c2ecf20Sopenharmony_ci	regmap = qcom_cc_map(pdev, &cam_cc_sdm845_desc);
17078c2ecf20Sopenharmony_ci	if (IS_ERR(regmap))
17088c2ecf20Sopenharmony_ci		return PTR_ERR(regmap);
17098c2ecf20Sopenharmony_ci
17108c2ecf20Sopenharmony_ci	cam_cc_pll_config.l = 0x1f;
17118c2ecf20Sopenharmony_ci	cam_cc_pll_config.alpha = 0x4000;
17128c2ecf20Sopenharmony_ci	clk_fabia_pll_configure(&cam_cc_pll0, regmap, &cam_cc_pll_config);
17138c2ecf20Sopenharmony_ci
17148c2ecf20Sopenharmony_ci	cam_cc_pll_config.l = 0x2a;
17158c2ecf20Sopenharmony_ci	cam_cc_pll_config.alpha = 0x1556;
17168c2ecf20Sopenharmony_ci	clk_fabia_pll_configure(&cam_cc_pll1, regmap, &cam_cc_pll_config);
17178c2ecf20Sopenharmony_ci
17188c2ecf20Sopenharmony_ci	cam_cc_pll_config.l = 0x32;
17198c2ecf20Sopenharmony_ci	cam_cc_pll_config.alpha = 0x0;
17208c2ecf20Sopenharmony_ci	clk_fabia_pll_configure(&cam_cc_pll2, regmap, &cam_cc_pll_config);
17218c2ecf20Sopenharmony_ci
17228c2ecf20Sopenharmony_ci	cam_cc_pll_config.l = 0x14;
17238c2ecf20Sopenharmony_ci	clk_fabia_pll_configure(&cam_cc_pll3, regmap, &cam_cc_pll_config);
17248c2ecf20Sopenharmony_ci
17258c2ecf20Sopenharmony_ci	return qcom_cc_really_probe(pdev, &cam_cc_sdm845_desc, regmap);
17268c2ecf20Sopenharmony_ci}
17278c2ecf20Sopenharmony_ci
17288c2ecf20Sopenharmony_cistatic struct platform_driver cam_cc_sdm845_driver = {
17298c2ecf20Sopenharmony_ci	.probe	= cam_cc_sdm845_probe,
17308c2ecf20Sopenharmony_ci	.driver	= {
17318c2ecf20Sopenharmony_ci		.name = "sdm845-camcc",
17328c2ecf20Sopenharmony_ci		.of_match_table = cam_cc_sdm845_match_table,
17338c2ecf20Sopenharmony_ci	},
17348c2ecf20Sopenharmony_ci};
17358c2ecf20Sopenharmony_ci
17368c2ecf20Sopenharmony_cistatic int __init cam_cc_sdm845_init(void)
17378c2ecf20Sopenharmony_ci{
17388c2ecf20Sopenharmony_ci	return platform_driver_register(&cam_cc_sdm845_driver);
17398c2ecf20Sopenharmony_ci}
17408c2ecf20Sopenharmony_cisubsys_initcall(cam_cc_sdm845_init);
17418c2ecf20Sopenharmony_ci
17428c2ecf20Sopenharmony_cistatic void __exit cam_cc_sdm845_exit(void)
17438c2ecf20Sopenharmony_ci{
17448c2ecf20Sopenharmony_ci	platform_driver_unregister(&cam_cc_sdm845_driver);
17458c2ecf20Sopenharmony_ci}
17468c2ecf20Sopenharmony_cimodule_exit(cam_cc_sdm845_exit);
17478c2ecf20Sopenharmony_ci
17488c2ecf20Sopenharmony_ciMODULE_DESCRIPTION("QTI CAM_CC SDM845 Driver");
17498c2ecf20Sopenharmony_ciMODULE_LICENSE("GPL v2");
1750