]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
clk: qcom: camcc-sc7280: Add parent dependency to all camera GDSCs
authorTaniya Das <quic_tdas@quicinc.com>
Fri, 31 May 2024 09:51:42 +0000 (15:21 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 3 Aug 2024 07:00:07 +0000 (09:00 +0200)
[ Upstream commit 63aec3e4d987fd43237f557460345bca3b51e530 ]

Camera titan top GDSC is a parent supply to all other camera GDSCs. Titan
top GDSC is required to be enabled before enabling any other camera GDSCs
and it should be disabled only after all other camera GDSCs are disabled.
Ensure this behavior by marking titan top GDSC as parent of all other
camera GDSCs.

Fixes: 1daec8cfebc2 ("clk: qcom: camcc: Add camera clock controller driver for SC7280")
Signed-off-by: Taniya Das <quic_tdas@quicinc.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
Link: https://lore.kernel.org/r/20240531095142.9688-4-quic_tdas@quicinc.com
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/clk/qcom/camcc-sc7280.c

index d89ddb2298e32d17ed9b0064ebb9c383b2609281..582fb3ba9c895c6dcd167a51be2732d1adbcff5c 100644 (file)
@@ -2260,6 +2260,7 @@ static struct gdsc cam_cc_bps_gdsc = {
                .name = "cam_cc_bps_gdsc",
        },
        .pwrsts = PWRSTS_OFF_ON,
+       .parent = &cam_cc_titan_top_gdsc.pd,
        .flags = HW_CTRL | RETAIN_FF_ENABLE,
 };
 
@@ -2269,6 +2270,7 @@ static struct gdsc cam_cc_ife_0_gdsc = {
                .name = "cam_cc_ife_0_gdsc",
        },
        .pwrsts = PWRSTS_OFF_ON,
+       .parent = &cam_cc_titan_top_gdsc.pd,
        .flags = RETAIN_FF_ENABLE,
 };
 
@@ -2278,6 +2280,7 @@ static struct gdsc cam_cc_ife_1_gdsc = {
                .name = "cam_cc_ife_1_gdsc",
        },
        .pwrsts = PWRSTS_OFF_ON,
+       .parent = &cam_cc_titan_top_gdsc.pd,
        .flags = RETAIN_FF_ENABLE,
 };
 
@@ -2287,6 +2290,7 @@ static struct gdsc cam_cc_ife_2_gdsc = {
                .name = "cam_cc_ife_2_gdsc",
        },
        .pwrsts = PWRSTS_OFF_ON,
+       .parent = &cam_cc_titan_top_gdsc.pd,
        .flags = RETAIN_FF_ENABLE,
 };
 
@@ -2296,6 +2300,7 @@ static struct gdsc cam_cc_ipe_0_gdsc = {
                .name = "cam_cc_ipe_0_gdsc",
        },
        .pwrsts = PWRSTS_OFF_ON,
+       .parent = &cam_cc_titan_top_gdsc.pd,
        .flags = HW_CTRL | RETAIN_FF_ENABLE,
 };