From 0fec3ee37391fae19e76c9772fe4f813488c4e4b Mon Sep 17 00:00:00 2001 From: Mike Tipton Date: Tue, 21 Apr 2020 19:08:54 -0700 Subject: [PATCH] clk: qcom: lahaina: Fix stuck-off warnings during probe When clocks are registered with the framework during probe, clk_core_hold_state() will call clk_core_prepare_enable() for clocks already enabled in HW from bootloaders. Some clocks are failing to actually turn on when this is called, which results in noisy warnings printed to the kernel log. These specific GPU clocks are failing to turn on because the required GDSC isn't enabled yet. However, this isn't a functional issue since GPU isn't actually being used yet. Since these clocks aren't shared across multiple client devices, there's no need for the framework to issue a proxy vote during registration. Thus, set the CLK_DONT_HOLD_STATE flag for these to skip the clk_core_prepare_enable() during registration. Change-Id: I4679de06fa903ab68e574b0be3419cdb47a16375 Signed-off-by: Mike Tipton --- drivers/clk/qcom/gcc-lahaina.c | 2 ++ drivers/clk/qcom/gpucc-lahaina.c | 1 + 2 files changed, 3 insertions(+) diff --git a/drivers/clk/qcom/gcc-lahaina.c b/drivers/clk/qcom/gcc-lahaina.c index 2b6136c1aa76..d3c6933735b5 100644 --- a/drivers/clk/qcom/gcc-lahaina.c +++ b/drivers/clk/qcom/gcc-lahaina.c @@ -2308,6 +2308,7 @@ static struct clk_branch gcc_gpu_memnoc_gfx_clk = { .enable_mask = BIT(0), .hw.init = &(struct clk_init_data){ .name = "gcc_gpu_memnoc_gfx_clk", + .flags = CLK_DONT_HOLD_STATE, .ops = &clk_branch2_aon_ops, }, }, @@ -2321,6 +2322,7 @@ static struct clk_branch gcc_gpu_snoc_dvm_gfx_clk = { .enable_mask = BIT(0), .hw.init = &(struct clk_init_data){ .name = "gcc_gpu_snoc_dvm_gfx_clk", + .flags = CLK_DONT_HOLD_STATE, .ops = &clk_branch2_aon_ops, }, }, diff --git a/drivers/clk/qcom/gpucc-lahaina.c b/drivers/clk/qcom/gpucc-lahaina.c index 68d54306d054..bdb163662c04 100644 --- a/drivers/clk/qcom/gpucc-lahaina.c +++ b/drivers/clk/qcom/gpucc-lahaina.c @@ -390,6 +390,7 @@ static struct clk_branch gpu_cc_cxo_clk = { .enable_mask = BIT(0), .hw.init = &(struct clk_init_data){ .name = "gpu_cc_cxo_clk", + .flags = CLK_DONT_HOLD_STATE, .ops = &clk_branch2_ops, }, },