Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

clk: qcom: gcc-sdm845: Add missing flag to votable GDSCs

On sdm845 devices, during boot we see the following warnings (unless we
have added 'pd_ignore_unused' to the kernel command line):
hlos1_vote_mmnoc_mmu_tbu_sf_gdsc status stuck at 'on'
hlos1_vote_mmnoc_mmu_tbu_hf1_gdsc status stuck at 'on'
hlos1_vote_mmnoc_mmu_tbu_hf0_gdsc status stuck at 'on'
hlos1_vote_aggre_noc_mmu_tbu2_gdsc status stuck at 'on'
hlos1_vote_aggre_noc_mmu_tbu1_gdsc status stuck at 'on'
hlos1_vote_aggre_noc_mmu_pcie_tbu_gdsc status stuck at 'on'
hlos1_vote_aggre_noc_mmu_audio_tbu_gdsc status stuck at 'on'

As the name of these GDSCs suggests, they are "votable" and in downstream
DT, they all have the property "qcom,no-status-check-on-disable", which
means that we should not poll the status bit when we disable them.

Luckily the VOTABLE flag already exists and it does exactly what we need,
so let's make use of it to make the warnings disappear.

Fixes: 06391eddb60a ("clk: qcom: Add Global Clock controller (GCC) driver for SDM845")
Reported-by: Rob Clark <robdclark@gmail.com>
Signed-off-by: Georgi Djakov <georgi.djakov@linaro.org>
Link: https://lkml.kernel.org/r/20191126153437.11808-1-georgi.djakov@linaro.org
Tested-by: Rob Clark <robdclark@gmail.com>
Signed-off-by: Stephen Boyd <sboyd@kernel.org>

authored by

Georgi Djakov and committed by
Stephen Boyd
5e82548e 12ead774

+7
+7
drivers/clk/qcom/gcc-sdm845.c
··· 3255 3255 .name = "hlos1_vote_aggre_noc_mmu_audio_tbu_gdsc", 3256 3256 }, 3257 3257 .pwrsts = PWRSTS_OFF_ON, 3258 + .flags = VOTABLE, 3258 3259 }; 3259 3260 3260 3261 static struct gdsc hlos1_vote_aggre_noc_mmu_pcie_tbu_gdsc = { ··· 3264 3263 .name = "hlos1_vote_aggre_noc_mmu_pcie_tbu_gdsc", 3265 3264 }, 3266 3265 .pwrsts = PWRSTS_OFF_ON, 3266 + .flags = VOTABLE, 3267 3267 }; 3268 3268 3269 3269 static struct gdsc hlos1_vote_aggre_noc_mmu_tbu1_gdsc = { ··· 3273 3271 .name = "hlos1_vote_aggre_noc_mmu_tbu1_gdsc", 3274 3272 }, 3275 3273 .pwrsts = PWRSTS_OFF_ON, 3274 + .flags = VOTABLE, 3276 3275 }; 3277 3276 3278 3277 static struct gdsc hlos1_vote_aggre_noc_mmu_tbu2_gdsc = { ··· 3282 3279 .name = "hlos1_vote_aggre_noc_mmu_tbu2_gdsc", 3283 3280 }, 3284 3281 .pwrsts = PWRSTS_OFF_ON, 3282 + .flags = VOTABLE, 3285 3283 }; 3286 3284 3287 3285 static struct gdsc hlos1_vote_mmnoc_mmu_tbu_hf0_gdsc = { ··· 3291 3287 .name = "hlos1_vote_mmnoc_mmu_tbu_hf0_gdsc", 3292 3288 }, 3293 3289 .pwrsts = PWRSTS_OFF_ON, 3290 + .flags = VOTABLE, 3294 3291 }; 3295 3292 3296 3293 static struct gdsc hlos1_vote_mmnoc_mmu_tbu_hf1_gdsc = { ··· 3300 3295 .name = "hlos1_vote_mmnoc_mmu_tbu_hf1_gdsc", 3301 3296 }, 3302 3297 .pwrsts = PWRSTS_OFF_ON, 3298 + .flags = VOTABLE, 3303 3299 }; 3304 3300 3305 3301 static struct gdsc hlos1_vote_mmnoc_mmu_tbu_sf_gdsc = { ··· 3309 3303 .name = "hlos1_vote_mmnoc_mmu_tbu_sf_gdsc", 3310 3304 }, 3311 3305 .pwrsts = PWRSTS_OFF_ON, 3306 + .flags = VOTABLE, 3312 3307 }; 3313 3308 3314 3309 static struct clk_regmap *gcc_sdm845_clocks[] = {