Commit 563528b8 authored by Douglas Anderson's avatar Douglas Anderson Committed by Stephen Boyd

clk: qcom: Use ARRAY_SIZE in videocc-sc7180 for parent clocks

It's nicer to use ARRAY_SIZE instead of hardcoding.  Had we always
been doing this it would have prevented a previous bug.  See commit
74c31ff9 ("clk: qcom: gpu_cc_gmu_clk_src has 5 parents, not 6").
Signed-off-by: default avatarDouglas Anderson <dianders@chromium.org>
Link: https://lkml.kernel.org/r/20200203103049.v4.13.If37e4b1b5553ac9db5ea51e84a6eec286cdf209e@changeidSigned-off-by: default avatarStephen Boyd <sboyd@kernel.org>
parent abc8f93f
...@@ -76,7 +76,7 @@ static struct clk_rcg2 video_cc_venus_clk_src = { ...@@ -76,7 +76,7 @@ static struct clk_rcg2 video_cc_venus_clk_src = {
.clkr.hw.init = &(struct clk_init_data){ .clkr.hw.init = &(struct clk_init_data){
.name = "video_cc_venus_clk_src", .name = "video_cc_venus_clk_src",
.parent_data = video_cc_parent_data_1, .parent_data = video_cc_parent_data_1,
.num_parents = 2, .num_parents = ARRAY_SIZE(video_cc_parent_data_1),
.flags = CLK_SET_RATE_PARENT, .flags = CLK_SET_RATE_PARENT,
.ops = &clk_rcg2_shared_ops, .ops = &clk_rcg2_shared_ops,
}, },
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment