* arbitrary parent trees.
*/
#define CLK_PARENT_VLP_CK CLK_PARENT_INFRASYS
+#define MTK_CLK_TREE_VLP_CK MTK_CLK_TREE_INFRASYS
#define GATE_VLPCFG_AO(id, parent, shift, flags) \
GATE_FLAGS(id, parent, &vlpcfg_ao_regs, shift, flags | CLK_GATE_NO_SETCLR_INV)
.num_ext_clks = ARRAY_SIZE(ext_clock_rates),
.plls = apmixed_plls,
.num_plls = ARRAY_SIZE(apmixed_plls),
+ .type = MTK_CLK_TREE_APMIXED,
};
static const struct mtk_clk_tree mt8189_topckgen_clk_tree = {
.num_fdivs = ARRAY_SIZE(top_fixed_divs),
.num_muxes = ARRAY_SIZE(top_muxes),
.num_gates = ARRAY_SIZE(top_gates),
+ .type = MTK_CLK_TREE_TOPCKGEN,
};
static const struct mtk_clk_tree mt8189_vlpckgen_clk_tree = {
.gates = vlp_ck_gates,
.num_muxes = ARRAY_SIZE(vlp_ck_muxes),
.num_gates = ARRAY_SIZE(vlp_ck_gates),
+ .type = MTK_CLK_TREE_VLP_CK,
+};
+
+static const struct mtk_clk_tree mt8189_clk_tree = {
+ .ext_clk_rates = ext_clock_rates,
+ .num_ext_clks = ARRAY_SIZE(ext_clock_rates),
};
static const struct udevice_id mt8189_apmixed[] = {
data = (void *)dev_get_driver_data(dev);
- return mtk_common_clk_gate_init(dev, &mt8189_topckgen_clk_tree,
+ return mtk_common_clk_gate_init(dev, &mt8189_clk_tree,
data->gates, data->num_gates,
data->gates[0].id);
}
.name = "mt8189-apmixedsys",
.id = UCLASS_CLK,
.of_match = mt8189_apmixed,
+ .bind = mtk_common_clk_parent_bind,
.probe = mt8189_apmixedsys_probe,
.priv_auto = sizeof(struct mtk_clk_priv),
.ops = &mtk_clk_apmixedsys_ops,
.name = "mt8189-topckgen",
.id = UCLASS_CLK,
.of_match = mt8189_topckgen_compat,
+ .bind = mtk_common_clk_parent_bind,
.probe = mt8189_topckgen_probe,
.priv_auto = sizeof(struct mtk_clk_priv),
.ops = &mtk_clk_topckgen_ops,
.name = "mt8189-vlpckgen",
.id = UCLASS_CLK,
.of_match = mt8189_vlpckgen,
+ .bind = mtk_common_clk_parent_bind,
.probe = mt8189_infrasys_probe,
.priv_auto = sizeof(struct mtk_clk_priv),
.ops = &mtk_clk_infrasys_ops,