diff mbox series

[v2,8/9] soc: qcom: rpmpd: Hook up VDDMX as parent of SM6375 VDDGX

Message ID 20230213143524.1943754-9-konrad.dybcio@linaro.org
State New
Headers show
Series [v2,1/9] soc: qcom: rpmpd: Bring all definitions to the top | expand

Commit Message

Konrad Dybcio Feb. 13, 2023, 2:35 p.m. UTC
The GPU core clock requires that both VDDGX and VDDMX domains are scaled
at the same rate at the same time (well, MX just before GX but you get
the idea). Set MX as parent of GX to take care of that.

Suggested-by: Bjorn Andersson <andersson@kernel.org>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org>
---
 drivers/soc/qcom/rpmpd.c | 3 +++
 1 file changed, 3 insertions(+)

Comments

Konrad Dybcio Feb. 20, 2023, 7:03 p.m. UTC | #1
On 13.02.2023 15:35, Konrad Dybcio wrote:
> The GPU core clock requires that both VDDGX and VDDMX domains are scaled
> at the same rate at the same time (well, MX just before GX but you get
> the idea). Set MX as parent of GX to take care of that.
> 
> Suggested-by: Bjorn Andersson <andersson@kernel.org>
> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
> Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org>
> ---
>  drivers/soc/qcom/rpmpd.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c
> index 2027c820caa7..2669c9210754 100644
> --- a/drivers/soc/qcom/rpmpd.c
> +++ b/drivers/soc/qcom/rpmpd.c
> @@ -216,11 +216,13 @@ static struct rpmpd gfx_s2b_vfc = {
>  	.key = KEY_FLOOR_CORNER,
>  };
>  
> +static struct rpmpd mx_rwmx0_lvl;
>  static struct rpmpd gx_rwgx0_lvl_ao;
>  static struct rpmpd gx_rwgx0_lvl = {
>  	.pd = { .name = "gx", },
>  	.peer = &gx_rwgx0_lvl_ao,
>  	.res_type = RPMPD_RWGX,
> +	.parent = &mx_rwmx0_lvl.pd,
>  	.res_id = 0,
>  	.key = KEY_LEVEL,
>  };
> @@ -228,6 +230,7 @@ static struct rpmpd gx_rwgx0_lvl = {
>  static struct rpmpd gx_rwgx0_lvl_ao = {
>  	.pd = { .name = "gx_ao", },
>  	.peer = &gx_rwgx0_lvl,
> +	.parent = &mx_rwmx0_lvl.pd,
This should have been mx_rwmx0_lvl_ao.pd.

Konrad
>  	.active_only = true,
>  	.res_type = RPMPD_RWGX,
>  	.res_id = 0,
diff mbox series

Patch

diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c
index 2027c820caa7..2669c9210754 100644
--- a/drivers/soc/qcom/rpmpd.c
+++ b/drivers/soc/qcom/rpmpd.c
@@ -216,11 +216,13 @@  static struct rpmpd gfx_s2b_vfc = {
 	.key = KEY_FLOOR_CORNER,
 };
 
+static struct rpmpd mx_rwmx0_lvl;
 static struct rpmpd gx_rwgx0_lvl_ao;
 static struct rpmpd gx_rwgx0_lvl = {
 	.pd = { .name = "gx", },
 	.peer = &gx_rwgx0_lvl_ao,
 	.res_type = RPMPD_RWGX,
+	.parent = &mx_rwmx0_lvl.pd,
 	.res_id = 0,
 	.key = KEY_LEVEL,
 };
@@ -228,6 +230,7 @@  static struct rpmpd gx_rwgx0_lvl = {
 static struct rpmpd gx_rwgx0_lvl_ao = {
 	.pd = { .name = "gx_ao", },
 	.peer = &gx_rwgx0_lvl,
+	.parent = &mx_rwmx0_lvl.pd,
 	.active_only = true,
 	.res_type = RPMPD_RWGX,
 	.res_id = 0,