2023-03-13 20:00:15

by Konrad Dybcio

[permalink] [raw]
Subject: [PATCH v3 00/10] RPMPD cleanup + parent PD

v2 -> v3:
- Correctly include the missing first patch (this is very embarassing)
- Fix the _ao parent for SM6375_VDDGX
- Use b4, hopefully everybody gets all the patches now..

v2: https://lore.kernel.org/lkml/[email protected]/T/#m829f7bfcf911f5e16d9f83aefe810e5dedc7453d

Signed-off-by: Konrad Dybcio <[email protected]>
---
Konrad Dybcio (10):
soc: qcom: rpmpd: Remove SoC names from RPMPD definitions
soc: qcom: rpmpd: Bring all definitions to the top
soc: qcom: rpmpd: Unify Low Power Island definitions
soc: qcom: rpmpd: Remove vdd* from struct names
soc: qcom: rpmpd: Expand struct definition macros
soc: qcom: rpmpd: Improve the naming
soc: qcom: rpmpd: Make bindings assignments consistent
soc: qcom: rpmpd: Add parent PD support
soc: qcom: rpmpd: Hook up VDDMX as parent of SM6375 VDDGX
soc: qcom: rpmpd: Remove useless comments

drivers/soc/qcom/rpmpd.c | 833 ++++++++++++++++++++++++++++++++---------------
1 file changed, 565 insertions(+), 268 deletions(-)
---
base-commit: 24469a0e5052ba01a35a15f104717a82b7a4798b
change-id: 20230313-topic-rpmpd-6e13a86c01a6

Best regards,
--
Konrad Dybcio <[email protected]>



2023-03-13 20:00:18

by Konrad Dybcio

[permalink] [raw]
Subject: [PATCH v3 01/10] soc: qcom: rpmpd: Remove SoC names from RPMPD definitions

Replace the SoC names with type+id_key (or type+id+..name..+key for
fixed-key definitions) and remove duplicate entries.

Signed-off-by: Konrad Dybcio <[email protected]>
---
drivers/soc/qcom/rpmpd.c | 360 +++++++++++++++++++++--------------------------
1 file changed, 164 insertions(+), 196 deletions(-)

diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c
index 337b1ad1cd3b..d99a56509e33 100644
--- a/drivers/soc/qcom/rpmpd.c
+++ b/drivers/soc/qcom/rpmpd.c
@@ -40,51 +40,50 @@

#define MAX_CORNER_RPMPD_STATE 6

-#define DEFINE_RPMPD_PAIR(_platform, _name, _active, r_type, r_key, \
- r_id) \
- static struct rpmpd _platform##_##_active; \
- static struct rpmpd _platform##_##_name = { \
+#define DEFINE_RPMPD_PAIR(_name, _active, r_type, r_key, r_id) \
+ static struct rpmpd r_type##r_id##_##r_key##_##_active; \
+ static struct rpmpd r_type##r_id##_##r_key##_##_name = { \
.pd = { .name = #_name, }, \
- .peer = &_platform##_##_active, \
+ .peer = &r_type##r_id##_##r_key##_##_active, \
.res_type = RPMPD_##r_type, \
.res_id = r_id, \
.key = KEY_##r_key, \
}; \
- static struct rpmpd _platform##_##_active = { \
+ static struct rpmpd r_type##r_id##_##r_key##_##_active = { \
.pd = { .name = #_active, }, \
- .peer = &_platform##_##_name, \
+ .peer = &r_type##r_id##_##r_key##_##_name, \
.active_only = true, \
.res_type = RPMPD_##r_type, \
.res_id = r_id, \
.key = KEY_##r_key, \
}

-#define DEFINE_RPMPD_CORNER(_platform, _name, r_type, r_id) \
- static struct rpmpd _platform##_##_name = { \
+#define DEFINE_RPMPD_CORNER(_name, r_type, r_id) \
+ static struct rpmpd r_type##r_id##_##_name##_corner = { \
.pd = { .name = #_name, }, \
.res_type = RPMPD_##r_type, \
.res_id = r_id, \
.key = KEY_CORNER, \
}

-#define DEFINE_RPMPD_LEVEL(_platform, _name, r_type, r_id) \
- static struct rpmpd _platform##_##_name = { \
+#define DEFINE_RPMPD_LEVEL(_name, r_type, r_id) \
+ static struct rpmpd r_type##r_id##_##_name##_lvl = { \
.pd = { .name = #_name, }, \
.res_type = RPMPD_##r_type, \
.res_id = r_id, \
.key = KEY_LEVEL, \
}

-#define DEFINE_RPMPD_VFC(_platform, _name, r_type, r_id) \
- static struct rpmpd _platform##_##_name = { \
+#define DEFINE_RPMPD_VFC(_name, r_type, r_id) \
+ static struct rpmpd r_type##r_id##_##_name = { \
.pd = { .name = #_name, }, \
.res_type = RPMPD_##r_type, \
.res_id = r_id, \
.key = KEY_FLOOR_CORNER, \
}

-#define DEFINE_RPMPD_VFL(_platform, _name, r_type, r_id) \
- static struct rpmpd _platform##_##_name = { \
+#define DEFINE_RPMPD_VFL(_name, r_type, r_id) \
+ static struct rpmpd r_type##r_id##_##_name = { \
.pd = { .name = #_name, }, \
.res_type = RPMPD_##r_type, \
.res_id = r_id, \
@@ -119,18 +118,18 @@ struct rpmpd_desc {
static DEFINE_MUTEX(rpmpd_lock);

/* mdm9607 RPM Power Domains */
-DEFINE_RPMPD_PAIR(mdm9607, vddcx, vddcx_ao, SMPA, LEVEL, 3);
-DEFINE_RPMPD_VFL(mdm9607, vddcx_vfl, SMPA, 3);
+DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, LEVEL, 3);
+DEFINE_RPMPD_VFL(vddcx_vfl, SMPA, 3);

-DEFINE_RPMPD_PAIR(mdm9607, vddmx, vddmx_ao, LDOA, LEVEL, 12);
-DEFINE_RPMPD_VFL(mdm9607, vddmx_vfl, LDOA, 12);
+DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, LDOA, LEVEL, 12);
+DEFINE_RPMPD_VFL(vddmx_vfl, LDOA, 12);
static struct rpmpd *mdm9607_rpmpds[] = {
- [MDM9607_VDDCX] = &mdm9607_vddcx,
- [MDM9607_VDDCX_AO] = &mdm9607_vddcx_ao,
- [MDM9607_VDDCX_VFL] = &mdm9607_vddcx_vfl,
- [MDM9607_VDDMX] = &mdm9607_vddmx,
- [MDM9607_VDDMX_AO] = &mdm9607_vddmx_ao,
- [MDM9607_VDDMX_VFL] = &mdm9607_vddmx_vfl,
+ [MDM9607_VDDCX] = &SMPA3_LEVEL_vddcx,
+ [MDM9607_VDDCX_AO] = &SMPA3_LEVEL_vddcx_ao,
+ [MDM9607_VDDCX_VFL] = &SMPA3_vddcx_vfl,
+ [MDM9607_VDDMX] = &LDOA12_LEVEL_vddmx,
+ [MDM9607_VDDMX_AO] = &LDOA12_LEVEL_vddmx_ao,
+ [MDM9607_VDDMX_VFL] = &LDOA12_vddmx_vfl,
};

static const struct rpmpd_desc mdm9607_desc = {
@@ -140,13 +139,13 @@ static const struct rpmpd_desc mdm9607_desc = {
};

/* msm8226 RPM Power Domains */
-DEFINE_RPMPD_PAIR(msm8226, vddcx, vddcx_ao, SMPA, CORNER, 1);
-DEFINE_RPMPD_VFC(msm8226, vddcx_vfc, SMPA, 1);
+DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, CORNER, 1);
+DEFINE_RPMPD_VFC(vddcx_vfc, SMPA, 1);

static struct rpmpd *msm8226_rpmpds[] = {
- [MSM8226_VDDCX] = &msm8226_vddcx,
- [MSM8226_VDDCX_AO] = &msm8226_vddcx_ao,
- [MSM8226_VDDCX_VFC] = &msm8226_vddcx_vfc,
+ [MSM8226_VDDCX] = &SMPA1_CORNER_vddcx,
+ [MSM8226_VDDCX_AO] = &SMPA1_CORNER_vddcx_ao,
+ [MSM8226_VDDCX_VFC] = &SMPA1_vddcx_vfc,
};

static const struct rpmpd_desc msm8226_desc = {
@@ -156,23 +155,23 @@ static const struct rpmpd_desc msm8226_desc = {
};

/* msm8939 RPM Power Domains */
-DEFINE_RPMPD_PAIR(msm8939, vddmd, vddmd_ao, SMPA, CORNER, 1);
-DEFINE_RPMPD_VFC(msm8939, vddmd_vfc, SMPA, 1);
+DEFINE_RPMPD_PAIR(vddmd, vddmd_ao, SMPA, CORNER, 1);
+DEFINE_RPMPD_VFC(vddmd_vfc, SMPA, 1);

-DEFINE_RPMPD_PAIR(msm8939, vddcx, vddcx_ao, SMPA, CORNER, 2);
-DEFINE_RPMPD_VFC(msm8939, vddcx_vfc, SMPA, 2);
+DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, CORNER, 2);
+DEFINE_RPMPD_VFC(vddcx_vfc, SMPA, 2);

-DEFINE_RPMPD_PAIR(msm8939, vddmx, vddmx_ao, LDOA, CORNER, 3);
+DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, LDOA, CORNER, 3);

static struct rpmpd *msm8939_rpmpds[] = {
- [MSM8939_VDDMDCX] = &msm8939_vddmd,
- [MSM8939_VDDMDCX_AO] = &msm8939_vddmd_ao,
- [MSM8939_VDDMDCX_VFC] = &msm8939_vddmd_vfc,
- [MSM8939_VDDCX] = &msm8939_vddcx,
- [MSM8939_VDDCX_AO] = &msm8939_vddcx_ao,
- [MSM8939_VDDCX_VFC] = &msm8939_vddcx_vfc,
- [MSM8939_VDDMX] = &msm8939_vddmx,
- [MSM8939_VDDMX_AO] = &msm8939_vddmx_ao,
+ [MSM8939_VDDMDCX] = &SMPA1_CORNER_vddmd,
+ [MSM8939_VDDMDCX_AO] = &SMPA1_CORNER_vddmd_ao,
+ [MSM8939_VDDMDCX_VFC] = &SMPA1_vddmd_vfc,
+ [MSM8939_VDDCX] = &SMPA2_CORNER_vddcx,
+ [MSM8939_VDDCX_AO] = &SMPA2_CORNER_vddcx_ao,
+ [MSM8939_VDDCX_VFC] = &SMPA2_vddcx_vfc,
+ [MSM8939_VDDMX] = &LDOA3_CORNER_vddmx,
+ [MSM8939_VDDMX_AO] = &LDOA3_CORNER_vddmx_ao,
};

static const struct rpmpd_desc msm8939_desc = {
@@ -182,17 +181,12 @@ static const struct rpmpd_desc msm8939_desc = {
};

/* msm8916 RPM Power Domains */
-DEFINE_RPMPD_PAIR(msm8916, vddcx, vddcx_ao, SMPA, CORNER, 1);
-DEFINE_RPMPD_PAIR(msm8916, vddmx, vddmx_ao, LDOA, CORNER, 3);
-
-DEFINE_RPMPD_VFC(msm8916, vddcx_vfc, SMPA, 1);
-
static struct rpmpd *msm8916_rpmpds[] = {
- [MSM8916_VDDCX] = &msm8916_vddcx,
- [MSM8916_VDDCX_AO] = &msm8916_vddcx_ao,
- [MSM8916_VDDCX_VFC] = &msm8916_vddcx_vfc,
- [MSM8916_VDDMX] = &msm8916_vddmx,
- [MSM8916_VDDMX_AO] = &msm8916_vddmx_ao,
+ [MSM8916_VDDCX] = &SMPA1_CORNER_vddcx,
+ [MSM8916_VDDCX_AO] = &SMPA1_CORNER_vddcx_ao,
+ [MSM8916_VDDCX_VFC] = &SMPA1_vddcx_vfc,
+ [MSM8916_VDDMX] = &LDOA3_CORNER_vddmx,
+ [MSM8916_VDDMX_AO] = &LDOA3_CORNER_vddmx_ao,
};

static const struct rpmpd_desc msm8916_desc = {
@@ -202,20 +196,20 @@ static const struct rpmpd_desc msm8916_desc = {
};

/* msm8953 RPM Power Domains */
-DEFINE_RPMPD_PAIR(msm8953, vddmd, vddmd_ao, SMPA, LEVEL, 1);
-DEFINE_RPMPD_PAIR(msm8953, vddcx, vddcx_ao, SMPA, LEVEL, 2);
-DEFINE_RPMPD_PAIR(msm8953, vddmx, vddmx_ao, SMPA, LEVEL, 7);
+DEFINE_RPMPD_PAIR(vddmd, vddmd_ao, SMPA, LEVEL, 1);
+DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, LEVEL, 2);
+DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, SMPA, LEVEL, 7);

-DEFINE_RPMPD_VFL(msm8953, vddcx_vfl, SMPA, 2);
+DEFINE_RPMPD_VFL(vddcx_vfl, SMPA, 2);

static struct rpmpd *msm8953_rpmpds[] = {
- [MSM8953_VDDMD] = &msm8953_vddmd,
- [MSM8953_VDDMD_AO] = &msm8953_vddmd_ao,
- [MSM8953_VDDCX] = &msm8953_vddcx,
- [MSM8953_VDDCX_AO] = &msm8953_vddcx_ao,
- [MSM8953_VDDCX_VFL] = &msm8953_vddcx_vfl,
- [MSM8953_VDDMX] = &msm8953_vddmx,
- [MSM8953_VDDMX_AO] = &msm8953_vddmx_ao,
+ [MSM8953_VDDMD] = &SMPA1_LEVEL_vddmd,
+ [MSM8953_VDDMD_AO] = &SMPA1_LEVEL_vddmd_ao,
+ [MSM8953_VDDCX] = &SMPA2_LEVEL_vddcx,
+ [MSM8953_VDDCX_AO] = &SMPA2_LEVEL_vddcx_ao,
+ [MSM8953_VDDCX_VFL] = &SMPA2_vddcx_vfl,
+ [MSM8953_VDDMX] = &SMPA7_LEVEL_vddmx,
+ [MSM8953_VDDMX_AO] = &SMPA7_LEVEL_vddmx_ao,
};

static const struct rpmpd_desc msm8953_desc = {
@@ -225,19 +219,18 @@ static const struct rpmpd_desc msm8953_desc = {
};

/* msm8976 RPM Power Domains */
-DEFINE_RPMPD_PAIR(msm8976, vddcx, vddcx_ao, SMPA, LEVEL, 2);
-DEFINE_RPMPD_PAIR(msm8976, vddmx, vddmx_ao, SMPA, LEVEL, 6);
+DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, SMPA, LEVEL, 6);

-DEFINE_RPMPD_VFL(msm8976, vddcx_vfl, RWSC, 2);
-DEFINE_RPMPD_VFL(msm8976, vddmx_vfl, RWSM, 6);
+DEFINE_RPMPD_VFL(vddcx_vfl, RWSC, 2);
+DEFINE_RPMPD_VFL(vddmx_vfl, RWSM, 6);

static struct rpmpd *msm8976_rpmpds[] = {
- [MSM8976_VDDCX] = &msm8976_vddcx,
- [MSM8976_VDDCX_AO] = &msm8976_vddcx_ao,
- [MSM8976_VDDCX_VFL] = &msm8976_vddcx_vfl,
- [MSM8976_VDDMX] = &msm8976_vddmx,
- [MSM8976_VDDMX_AO] = &msm8976_vddmx_ao,
- [MSM8976_VDDMX_VFL] = &msm8976_vddmx_vfl,
+ [MSM8976_VDDCX] = &SMPA2_LEVEL_vddcx,
+ [MSM8976_VDDCX_AO] = &SMPA2_LEVEL_vddcx_ao,
+ [MSM8976_VDDCX_VFL] = &RWSC2_vddcx_vfl,
+ [MSM8976_VDDMX] = &SMPA6_LEVEL_vddmx,
+ [MSM8976_VDDMX_AO] = &SMPA6_LEVEL_vddmx_ao,
+ [MSM8976_VDDMX_VFL] = &RWSM6_vddmx_vfl,
};

static const struct rpmpd_desc msm8976_desc = {
@@ -247,22 +240,20 @@ static const struct rpmpd_desc msm8976_desc = {
};

/* msm8994 RPM Power domains */
-DEFINE_RPMPD_PAIR(msm8994, vddcx, vddcx_ao, SMPA, CORNER, 1);
-DEFINE_RPMPD_PAIR(msm8994, vddmx, vddmx_ao, SMPA, CORNER, 2);
+DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, SMPA, CORNER, 2);
/* Attention! *Some* 8994 boards with pm8004 may use SMPC here! */
-DEFINE_RPMPD_CORNER(msm8994, vddgfx, SMPB, 2);
+DEFINE_RPMPD_CORNER(vddgfx, SMPB, 2);

-DEFINE_RPMPD_VFC(msm8994, vddcx_vfc, SMPA, 1);
-DEFINE_RPMPD_VFC(msm8994, vddgfx_vfc, SMPB, 2);
+DEFINE_RPMPD_VFC(vddgfx_vfc, SMPB, 2);

static struct rpmpd *msm8994_rpmpds[] = {
- [MSM8994_VDDCX] = &msm8994_vddcx,
- [MSM8994_VDDCX_AO] = &msm8994_vddcx_ao,
- [MSM8994_VDDCX_VFC] = &msm8994_vddcx_vfc,
- [MSM8994_VDDMX] = &msm8994_vddmx,
- [MSM8994_VDDMX_AO] = &msm8994_vddmx_ao,
- [MSM8994_VDDGFX] = &msm8994_vddgfx,
- [MSM8994_VDDGFX_VFC] = &msm8994_vddgfx_vfc,
+ [MSM8994_VDDCX] = &SMPA1_CORNER_vddcx,
+ [MSM8994_VDDCX_AO] = &SMPA1_CORNER_vddcx_ao,
+ [MSM8994_VDDCX_VFC] = &SMPA1_vddcx_vfc,
+ [MSM8994_VDDMX] = &SMPA2_CORNER_vddmx,
+ [MSM8994_VDDMX_AO] = &SMPA2_CORNER_vddmx_ao,
+ [MSM8994_VDDGFX] = &SMPB2_vddgfx_corner,
+ [MSM8994_VDDGFX_VFC] = &SMPB2_vddgfx_vfc,
};

static const struct rpmpd_desc msm8994_desc = {
@@ -272,21 +263,18 @@ static const struct rpmpd_desc msm8994_desc = {
};

/* msm8996 RPM Power domains */
-DEFINE_RPMPD_PAIR(msm8996, vddcx, vddcx_ao, SMPA, CORNER, 1);
-DEFINE_RPMPD_PAIR(msm8996, vddmx, vddmx_ao, SMPA, CORNER, 2);
-DEFINE_RPMPD_CORNER(msm8996, vddsscx, LDOA, 26);
+DEFINE_RPMPD_CORNER(vddsscx, LDOA, 26);

-DEFINE_RPMPD_VFC(msm8996, vddcx_vfc, SMPA, 1);
-DEFINE_RPMPD_VFC(msm8996, vddsscx_vfc, LDOA, 26);
+DEFINE_RPMPD_VFC(vddsscx_vfc, LDOA, 26);

static struct rpmpd *msm8996_rpmpds[] = {
- [MSM8996_VDDCX] = &msm8996_vddcx,
- [MSM8996_VDDCX_AO] = &msm8996_vddcx_ao,
- [MSM8996_VDDCX_VFC] = &msm8996_vddcx_vfc,
- [MSM8996_VDDMX] = &msm8996_vddmx,
- [MSM8996_VDDMX_AO] = &msm8996_vddmx_ao,
- [MSM8996_VDDSSCX] = &msm8996_vddsscx,
- [MSM8996_VDDSSCX_VFC] = &msm8996_vddsscx_vfc,
+ [MSM8996_VDDCX] = &SMPA1_CORNER_vddcx,
+ [MSM8996_VDDCX_AO] = &SMPA1_CORNER_vddcx_ao,
+ [MSM8996_VDDCX_VFC] = &SMPA1_vddcx_vfc,
+ [MSM8996_VDDMX] = &SMPA2_CORNER_vddmx,
+ [MSM8996_VDDMX_AO] = &SMPA2_CORNER_vddmx_ao,
+ [MSM8996_VDDSSCX] = &LDOA26_vddsscx_corner,
+ [MSM8996_VDDSSCX_VFC] = &LDOA26_vddsscx_vfc,
};

static const struct rpmpd_desc msm8996_desc = {
@@ -296,29 +284,29 @@ static const struct rpmpd_desc msm8996_desc = {
};

/* msm8998 RPM Power domains */
-DEFINE_RPMPD_PAIR(msm8998, vddcx, vddcx_ao, RWCX, LEVEL, 0);
-DEFINE_RPMPD_VFL(msm8998, vddcx_vfl, RWCX, 0);
+DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, RWCX, LEVEL, 0);
+DEFINE_RPMPD_VFL(vddcx_vfl, RWCX, 0);

-DEFINE_RPMPD_PAIR(msm8998, vddmx, vddmx_ao, RWMX, LEVEL, 0);
-DEFINE_RPMPD_VFL(msm8998, vddmx_vfl, RWMX, 0);
+DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, RWMX, LEVEL, 0);
+DEFINE_RPMPD_VFL(vddmx_vfl, RWMX, 0);

-DEFINE_RPMPD_LEVEL(msm8998, vdd_ssccx, RWSC, 0);
-DEFINE_RPMPD_VFL(msm8998, vdd_ssccx_vfl, RWSC, 0);
+DEFINE_RPMPD_LEVEL(vdd_ssccx, RWSC, 0);
+DEFINE_RPMPD_VFL(vdd_ssccx_vfl, RWSC, 0);

-DEFINE_RPMPD_LEVEL(msm8998, vdd_sscmx, RWSM, 0);
-DEFINE_RPMPD_VFL(msm8998, vdd_sscmx_vfl, RWSM, 0);
+DEFINE_RPMPD_LEVEL(vdd_sscmx, RWSM, 0);
+DEFINE_RPMPD_VFL(vdd_sscmx_vfl, RWSM, 0);

static struct rpmpd *msm8998_rpmpds[] = {
- [MSM8998_VDDCX] = &msm8998_vddcx,
- [MSM8998_VDDCX_AO] = &msm8998_vddcx_ao,
- [MSM8998_VDDCX_VFL] = &msm8998_vddcx_vfl,
- [MSM8998_VDDMX] = &msm8998_vddmx,
- [MSM8998_VDDMX_AO] = &msm8998_vddmx_ao,
- [MSM8998_VDDMX_VFL] = &msm8998_vddmx_vfl,
- [MSM8998_SSCCX] = &msm8998_vdd_ssccx,
- [MSM8998_SSCCX_VFL] = &msm8998_vdd_ssccx_vfl,
- [MSM8998_SSCMX] = &msm8998_vdd_sscmx,
- [MSM8998_SSCMX_VFL] = &msm8998_vdd_sscmx_vfl,
+ [MSM8998_VDDCX] = &RWCX0_LEVEL_vddcx,
+ [MSM8998_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
+ [MSM8998_VDDCX_VFL] = &RWCX0_vddcx_vfl,
+ [MSM8998_VDDMX] = &RWMX0_LEVEL_vddmx,
+ [MSM8998_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
+ [MSM8998_VDDMX_VFL] = &RWMX0_vddmx_vfl,
+ [MSM8998_SSCCX] = &RWSC0_vdd_ssccx_lvl,
+ [MSM8998_SSCCX_VFL] = &RWSC0_vdd_ssccx_vfl,
+ [MSM8998_SSCMX] = &RWSM0_vdd_sscmx_lvl,
+ [MSM8998_SSCMX_VFL] = &RWSM0_vdd_sscmx_vfl,
};

static const struct rpmpd_desc msm8998_desc = {
@@ -328,23 +316,20 @@ static const struct rpmpd_desc msm8998_desc = {
};

/* qcs404 RPM Power domains */
-DEFINE_RPMPD_PAIR(qcs404, vddmx, vddmx_ao, RWMX, LEVEL, 0);
-DEFINE_RPMPD_VFL(qcs404, vddmx_vfl, RWMX, 0);
+DEFINE_RPMPD_LEVEL(vdd_lpicx, RWLC, 0);
+DEFINE_RPMPD_VFL(vdd_lpicx_vfl, RWLC, 0);

-DEFINE_RPMPD_LEVEL(qcs404, vdd_lpicx, RWLC, 0);
-DEFINE_RPMPD_VFL(qcs404, vdd_lpicx_vfl, RWLC, 0);
-
-DEFINE_RPMPD_LEVEL(qcs404, vdd_lpimx, RWLM, 0);
-DEFINE_RPMPD_VFL(qcs404, vdd_lpimx_vfl, RWLM, 0);
+DEFINE_RPMPD_LEVEL(vdd_lpimx, RWLM, 0);
+DEFINE_RPMPD_VFL(vdd_lpimx_vfl, RWLM, 0);

static struct rpmpd *qcs404_rpmpds[] = {
- [QCS404_VDDMX] = &qcs404_vddmx,
- [QCS404_VDDMX_AO] = &qcs404_vddmx_ao,
- [QCS404_VDDMX_VFL] = &qcs404_vddmx_vfl,
- [QCS404_LPICX] = &qcs404_vdd_lpicx,
- [QCS404_LPICX_VFL] = &qcs404_vdd_lpicx_vfl,
- [QCS404_LPIMX] = &qcs404_vdd_lpimx,
- [QCS404_LPIMX_VFL] = &qcs404_vdd_lpimx_vfl,
+ [QCS404_VDDMX] = &RWMX0_LEVEL_vddmx,
+ [QCS404_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
+ [QCS404_VDDMX_VFL] = &RWMX0_vddmx_vfl,
+ [QCS404_LPICX] = &RWLC0_vdd_lpicx_lvl,
+ [QCS404_LPICX_VFL] = &RWLC0_vdd_lpicx_vfl,
+ [QCS404_LPIMX] = &RWLM0_vdd_lpimx_lvl,
+ [QCS404_LPIMX_VFL] = &RWLM0_vdd_lpimx_vfl,
};

static const struct rpmpd_desc qcs404_desc = {
@@ -354,29 +339,24 @@ static const struct rpmpd_desc qcs404_desc = {
};

/* sdm660 RPM Power domains */
-DEFINE_RPMPD_PAIR(sdm660, vddcx, vddcx_ao, RWCX, LEVEL, 0);
-DEFINE_RPMPD_VFL(sdm660, vddcx_vfl, RWCX, 0);
-
-DEFINE_RPMPD_PAIR(sdm660, vddmx, vddmx_ao, RWMX, LEVEL, 0);
-DEFINE_RPMPD_VFL(sdm660, vddmx_vfl, RWMX, 0);

-DEFINE_RPMPD_LEVEL(sdm660, vdd_ssccx, RWLC, 0);
-DEFINE_RPMPD_VFL(sdm660, vdd_ssccx_vfl, RWLC, 0);
+DEFINE_RPMPD_LEVEL(vdd_ssccx, RWLC, 0);
+DEFINE_RPMPD_VFL(vdd_ssccx_vfl, RWLC, 0);

-DEFINE_RPMPD_LEVEL(sdm660, vdd_sscmx, RWLM, 0);
-DEFINE_RPMPD_VFL(sdm660, vdd_sscmx_vfl, RWLM, 0);
+DEFINE_RPMPD_LEVEL(vdd_sscmx, RWLM, 0);
+DEFINE_RPMPD_VFL(vdd_sscmx_vfl, RWLM, 0);

static struct rpmpd *sdm660_rpmpds[] = {
- [SDM660_VDDCX] = &sdm660_vddcx,
- [SDM660_VDDCX_AO] = &sdm660_vddcx_ao,
- [SDM660_VDDCX_VFL] = &sdm660_vddcx_vfl,
- [SDM660_VDDMX] = &sdm660_vddmx,
- [SDM660_VDDMX_AO] = &sdm660_vddmx_ao,
- [SDM660_VDDMX_VFL] = &sdm660_vddmx_vfl,
- [SDM660_SSCCX] = &sdm660_vdd_ssccx,
- [SDM660_SSCCX_VFL] = &sdm660_vdd_ssccx_vfl,
- [SDM660_SSCMX] = &sdm660_vdd_sscmx,
- [SDM660_SSCMX_VFL] = &sdm660_vdd_sscmx_vfl,
+ [SDM660_VDDCX] = &RWCX0_LEVEL_vddcx,
+ [SDM660_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
+ [SDM660_VDDCX_VFL] = &RWCX0_vddcx_vfl,
+ [SDM660_VDDMX] = &RWMX0_LEVEL_vddmx,
+ [SDM660_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
+ [SDM660_VDDMX_VFL] = &RWMX0_vddmx_vfl,
+ [SDM660_SSCCX] = &RWLC0_vdd_ssccx_lvl,
+ [SDM660_SSCCX_VFL] = &RWLC0_vdd_ssccx_vfl,
+ [SDM660_SSCMX] = &RWLM0_vdd_sscmx_lvl,
+ [SDM660_SSCMX_VFL] = &RWLM0_vdd_sscmx_vfl,
};

static const struct rpmpd_desc sdm660_desc = {
@@ -386,24 +366,18 @@ static const struct rpmpd_desc sdm660_desc = {
};

/* sm4250/6115 RPM Power domains */
-DEFINE_RPMPD_PAIR(sm6115, vddcx, vddcx_ao, RWCX, LEVEL, 0);
-DEFINE_RPMPD_VFL(sm6115, vddcx_vfl, RWCX, 0);
-
-DEFINE_RPMPD_PAIR(sm6115, vddmx, vddmx_ao, RWMX, LEVEL, 0);
-DEFINE_RPMPD_VFL(sm6115, vddmx_vfl, RWMX, 0);
-
-DEFINE_RPMPD_LEVEL(sm6115, vdd_lpi_cx, RWLC, 0);
-DEFINE_RPMPD_LEVEL(sm6115, vdd_lpi_mx, RWLM, 0);
+DEFINE_RPMPD_LEVEL(vdd_lpi_cx, RWLC, 0);
+DEFINE_RPMPD_LEVEL(vdd_lpi_mx, RWLM, 0);

static struct rpmpd *sm6115_rpmpds[] = {
- [SM6115_VDDCX] = &sm6115_vddcx,
- [SM6115_VDDCX_AO] = &sm6115_vddcx_ao,
- [SM6115_VDDCX_VFL] = &sm6115_vddcx_vfl,
- [SM6115_VDDMX] = &sm6115_vddmx,
- [SM6115_VDDMX_AO] = &sm6115_vddmx_ao,
- [SM6115_VDDMX_VFL] = &sm6115_vddmx_vfl,
- [SM6115_VDD_LPI_CX] = &sm6115_vdd_lpi_cx,
- [SM6115_VDD_LPI_MX] = &sm6115_vdd_lpi_mx,
+ [SM6115_VDDCX] = &RWCX0_LEVEL_vddcx,
+ [SM6115_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
+ [SM6115_VDDCX_VFL] = &RWCX0_vddcx_vfl,
+ [SM6115_VDDMX] = &RWMX0_LEVEL_vddmx,
+ [SM6115_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
+ [SM6115_VDDMX_VFL] = &RWMX0_vddmx_vfl,
+ [SM6115_VDD_LPI_CX] = &RWLC0_vdd_lpi_cx_lvl,
+ [SM6115_VDD_LPI_MX] = &RWLM0_vdd_lpi_mx_lvl,
};

static const struct rpmpd_desc sm6115_desc = {
@@ -413,19 +387,13 @@ static const struct rpmpd_desc sm6115_desc = {
};

/* sm6125 RPM Power domains */
-DEFINE_RPMPD_PAIR(sm6125, vddcx, vddcx_ao, RWCX, LEVEL, 0);
-DEFINE_RPMPD_VFL(sm6125, vddcx_vfl, RWCX, 0);
-
-DEFINE_RPMPD_PAIR(sm6125, vddmx, vddmx_ao, RWMX, LEVEL, 0);
-DEFINE_RPMPD_VFL(sm6125, vddmx_vfl, RWMX, 0);
-
static struct rpmpd *sm6125_rpmpds[] = {
- [SM6125_VDDCX] = &sm6125_vddcx,
- [SM6125_VDDCX_AO] = &sm6125_vddcx_ao,
- [SM6125_VDDCX_VFL] = &sm6125_vddcx_vfl,
- [SM6125_VDDMX] = &sm6125_vddmx,
- [SM6125_VDDMX_AO] = &sm6125_vddmx_ao,
- [SM6125_VDDMX_VFL] = &sm6125_vddmx_vfl,
+ [SM6125_VDDCX] = &RWCX0_LEVEL_vddcx,
+ [SM6125_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
+ [SM6125_VDDCX_VFL] = &RWCX0_vddcx_vfl,
+ [SM6125_VDDMX] = &RWMX0_LEVEL_vddmx,
+ [SM6125_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
+ [SM6125_VDDMX_VFL] = &RWMX0_vddmx_vfl,
};

static const struct rpmpd_desc sm6125_desc = {
@@ -434,18 +402,18 @@ static const struct rpmpd_desc sm6125_desc = {
.max_state = RPM_SMD_LEVEL_BINNING,
};

-DEFINE_RPMPD_PAIR(sm6375, vddgx, vddgx_ao, RWGX, LEVEL, 0);
+DEFINE_RPMPD_PAIR(vddgx, vddgx_ao, RWGX, LEVEL, 0);
static struct rpmpd *sm6375_rpmpds[] = {
- [SM6375_VDDCX] = &sm6125_vddcx,
- [SM6375_VDDCX_AO] = &sm6125_vddcx_ao,
- [SM6375_VDDCX_VFL] = &sm6125_vddcx_vfl,
- [SM6375_VDDMX] = &sm6125_vddmx,
- [SM6375_VDDMX_AO] = &sm6125_vddmx_ao,
- [SM6375_VDDMX_VFL] = &sm6125_vddmx_vfl,
- [SM6375_VDDGX] = &sm6375_vddgx,
- [SM6375_VDDGX_AO] = &sm6375_vddgx_ao,
- [SM6375_VDD_LPI_CX] = &sm6115_vdd_lpi_cx,
- [SM6375_VDD_LPI_MX] = &sm6115_vdd_lpi_mx,
+ [SM6375_VDDCX] = &RWCX0_LEVEL_vddcx,
+ [SM6375_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
+ [SM6375_VDDCX_VFL] = &RWCX0_vddcx_vfl,
+ [SM6375_VDDMX] = &RWMX0_LEVEL_vddmx,
+ [SM6375_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
+ [SM6375_VDDMX_VFL] = &RWMX0_vddmx_vfl,
+ [SM6375_VDDGX] = &RWGX0_LEVEL_vddgx,
+ [SM6375_VDDGX_AO] = &RWGX0_LEVEL_vddgx_ao,
+ [SM6375_VDD_LPI_CX] = &RWLC0_vdd_lpi_cx_lvl,
+ [SM6375_VDD_LPI_MX] = &RWLM0_vdd_lpi_mx_lvl,
};

static const struct rpmpd_desc sm6375_desc = {
@@ -455,14 +423,14 @@ static const struct rpmpd_desc sm6375_desc = {
};

static struct rpmpd *qcm2290_rpmpds[] = {
- [QCM2290_VDDCX] = &sm6115_vddcx,
- [QCM2290_VDDCX_AO] = &sm6115_vddcx_ao,
- [QCM2290_VDDCX_VFL] = &sm6115_vddcx_vfl,
- [QCM2290_VDDMX] = &sm6115_vddmx,
- [QCM2290_VDDMX_AO] = &sm6115_vddmx_ao,
- [QCM2290_VDDMX_VFL] = &sm6115_vddmx_vfl,
- [QCM2290_VDD_LPI_CX] = &sm6115_vdd_lpi_cx,
- [QCM2290_VDD_LPI_MX] = &sm6115_vdd_lpi_mx,
+ [QCM2290_VDDCX] = &RWCX0_LEVEL_vddcx,
+ [QCM2290_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
+ [QCM2290_VDDCX_VFL] = &RWCX0_vddcx_vfl,
+ [QCM2290_VDDMX] = &RWMX0_LEVEL_vddmx,
+ [QCM2290_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
+ [QCM2290_VDDMX_VFL] = &RWMX0_vddmx_vfl,
+ [QCM2290_VDD_LPI_CX] = &RWLC0_vdd_lpi_cx_lvl,
+ [QCM2290_VDD_LPI_MX] = &RWLM0_vdd_lpi_mx_lvl,
};

static const struct rpmpd_desc qcm2290_desc = {

--
2.39.2


2023-03-13 20:00:22

by Konrad Dybcio

[permalink] [raw]
Subject: [PATCH v3 03/10] soc: qcom: rpmpd: Unify Low Power Island definitions

Up until now, we had 2 separate entries for VDD_LPI[CM]X and
VDD_LPI_[CM]X which both pointed to the same RPM resource. Fix it.

Signed-off-by: Konrad Dybcio <[email protected]>
---
drivers/soc/qcom/rpmpd.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c
index 7d9e762232ea..8ba025c4eca3 100644
--- a/drivers/soc/qcom/rpmpd.c
+++ b/drivers/soc/qcom/rpmpd.c
@@ -149,11 +149,9 @@ DEFINE_RPMPD_PAIR(vddmd, vddmd_ao, SMPA, LEVEL, 1);
DEFINE_RPMPD_VFC(vddmd_vfc, SMPA, 1);

DEFINE_RPMPD_LEVEL(vdd_lpi_cx, RWLC, 0);
-DEFINE_RPMPD_LEVEL(vdd_lpicx, RWLC, 0);
DEFINE_RPMPD_VFL(vdd_lpicx_vfl, RWLC, 0);

DEFINE_RPMPD_LEVEL(vdd_lpi_mx, RWLM, 0);
-DEFINE_RPMPD_LEVEL(vdd_lpimx, RWLM, 0);
DEFINE_RPMPD_VFL(vdd_lpimx_vfl, RWLM, 0);

DEFINE_RPMPD_CORNER(vddsscx, LDOA, 26);
@@ -324,9 +322,9 @@ static struct rpmpd *qcs404_rpmpds[] = {
[QCS404_VDDMX] = &RWMX0_LEVEL_vddmx,
[QCS404_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
[QCS404_VDDMX_VFL] = &RWMX0_vddmx_vfl,
- [QCS404_LPICX] = &RWLC0_vdd_lpicx_lvl,
+ [QCS404_LPICX] = &RWLC0_vdd_lpi_cx_lvl,
[QCS404_LPICX_VFL] = &RWLC0_vdd_lpicx_vfl,
- [QCS404_LPIMX] = &RWLM0_vdd_lpimx_lvl,
+ [QCS404_LPIMX] = &RWLM0_vdd_lpi_mx_lvl,
[QCS404_LPIMX_VFL] = &RWLM0_vdd_lpimx_vfl,
};


--
2.39.2


2023-03-13 20:00:24

by Konrad Dybcio

[permalink] [raw]
Subject: [PATCH v3 02/10] soc: qcom: rpmpd: Bring all definitions to the top

Keep all definitions in one place in preparation for a cleanup to make
things tidier.

Signed-off-by: Konrad Dybcio <[email protected]>
---
drivers/soc/qcom/rpmpd.c | 111 +++++++++++++++++++++--------------------------
1 file changed, 49 insertions(+), 62 deletions(-)

diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c
index d99a56509e33..7d9e762232ea 100644
--- a/drivers/soc/qcom/rpmpd.c
+++ b/drivers/soc/qcom/rpmpd.c
@@ -117,12 +117,58 @@ struct rpmpd_desc {

static DEFINE_MUTEX(rpmpd_lock);

-/* mdm9607 RPM Power Domains */
+DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, RWCX, LEVEL, 0);
+DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, CORNER, 1);
+DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, CORNER, 2);
+DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, LEVEL, 2);
DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, LEVEL, 3);
+DEFINE_RPMPD_VFL(vddcx_vfl, RWCX, 0);
+DEFINE_RPMPD_VFL(vddcx_vfl, RWSC, 2);
+DEFINE_RPMPD_VFC(vddcx_vfc, SMPA, 1);
+DEFINE_RPMPD_VFC(vddcx_vfc, SMPA, 2);
+DEFINE_RPMPD_VFL(vddcx_vfl, SMPA, 2);
DEFINE_RPMPD_VFL(vddcx_vfl, SMPA, 3);

+DEFINE_RPMPD_CORNER(vddgfx, SMPB, 2);
+DEFINE_RPMPD_VFC(vddgfx_vfc, SMPB, 2);
+
+DEFINE_RPMPD_PAIR(vddgx, vddgx_ao, RWGX, LEVEL, 0);
+
+DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, LDOA, CORNER, 3);
DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, LDOA, LEVEL, 12);
+DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, SMPA, CORNER, 2);
+DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, RWMX, LEVEL, 0);
+DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, SMPA, LEVEL, 6);
+DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, SMPA, LEVEL, 7);
DEFINE_RPMPD_VFL(vddmx_vfl, LDOA, 12);
+DEFINE_RPMPD_VFL(vddmx_vfl, RWMX, 0);
+DEFINE_RPMPD_VFL(vddmx_vfl, RWSM, 6);
+
+DEFINE_RPMPD_PAIR(vddmd, vddmd_ao, SMPA, CORNER, 1);
+DEFINE_RPMPD_PAIR(vddmd, vddmd_ao, SMPA, LEVEL, 1);
+DEFINE_RPMPD_VFC(vddmd_vfc, SMPA, 1);
+
+DEFINE_RPMPD_LEVEL(vdd_lpi_cx, RWLC, 0);
+DEFINE_RPMPD_LEVEL(vdd_lpicx, RWLC, 0);
+DEFINE_RPMPD_VFL(vdd_lpicx_vfl, RWLC, 0);
+
+DEFINE_RPMPD_LEVEL(vdd_lpi_mx, RWLM, 0);
+DEFINE_RPMPD_LEVEL(vdd_lpimx, RWLM, 0);
+DEFINE_RPMPD_VFL(vdd_lpimx_vfl, RWLM, 0);
+
+DEFINE_RPMPD_CORNER(vddsscx, LDOA, 26);
+DEFINE_RPMPD_LEVEL(vdd_ssccx, RWLC, 0);
+DEFINE_RPMPD_LEVEL(vdd_ssccx, RWSC, 0);
+DEFINE_RPMPD_VFC(vddsscx_vfc, LDOA, 26);
+DEFINE_RPMPD_VFL(vdd_ssccx_vfl, RWLC, 0);
+DEFINE_RPMPD_VFL(vdd_ssccx_vfl, RWSC, 0);
+
+DEFINE_RPMPD_LEVEL(vdd_sscmx, RWLM, 0);
+DEFINE_RPMPD_LEVEL(vdd_sscmx, RWSM, 0);
+DEFINE_RPMPD_VFL(vdd_sscmx_vfl, RWLM, 0);
+DEFINE_RPMPD_VFL(vdd_sscmx_vfl, RWSM, 0);
+
+/* mdm9607 RPM Power Domains */
static struct rpmpd *mdm9607_rpmpds[] = {
[MDM9607_VDDCX] = &SMPA3_LEVEL_vddcx,
[MDM9607_VDDCX_AO] = &SMPA3_LEVEL_vddcx_ao,
@@ -139,9 +185,6 @@ static const struct rpmpd_desc mdm9607_desc = {
};

/* msm8226 RPM Power Domains */
-DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, CORNER, 1);
-DEFINE_RPMPD_VFC(vddcx_vfc, SMPA, 1);
-
static struct rpmpd *msm8226_rpmpds[] = {
[MSM8226_VDDCX] = &SMPA1_CORNER_vddcx,
[MSM8226_VDDCX_AO] = &SMPA1_CORNER_vddcx_ao,
@@ -155,14 +198,6 @@ static const struct rpmpd_desc msm8226_desc = {
};

/* msm8939 RPM Power Domains */
-DEFINE_RPMPD_PAIR(vddmd, vddmd_ao, SMPA, CORNER, 1);
-DEFINE_RPMPD_VFC(vddmd_vfc, SMPA, 1);
-
-DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, CORNER, 2);
-DEFINE_RPMPD_VFC(vddcx_vfc, SMPA, 2);
-
-DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, LDOA, CORNER, 3);
-
static struct rpmpd *msm8939_rpmpds[] = {
[MSM8939_VDDMDCX] = &SMPA1_CORNER_vddmd,
[MSM8939_VDDMDCX_AO] = &SMPA1_CORNER_vddmd_ao,
@@ -196,12 +231,6 @@ static const struct rpmpd_desc msm8916_desc = {
};

/* msm8953 RPM Power Domains */
-DEFINE_RPMPD_PAIR(vddmd, vddmd_ao, SMPA, LEVEL, 1);
-DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, LEVEL, 2);
-DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, SMPA, LEVEL, 7);
-
-DEFINE_RPMPD_VFL(vddcx_vfl, SMPA, 2);
-
static struct rpmpd *msm8953_rpmpds[] = {
[MSM8953_VDDMD] = &SMPA1_LEVEL_vddmd,
[MSM8953_VDDMD_AO] = &SMPA1_LEVEL_vddmd_ao,
@@ -219,11 +248,6 @@ static const struct rpmpd_desc msm8953_desc = {
};

/* msm8976 RPM Power Domains */
-DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, SMPA, LEVEL, 6);
-
-DEFINE_RPMPD_VFL(vddcx_vfl, RWSC, 2);
-DEFINE_RPMPD_VFL(vddmx_vfl, RWSM, 6);
-
static struct rpmpd *msm8976_rpmpds[] = {
[MSM8976_VDDCX] = &SMPA2_LEVEL_vddcx,
[MSM8976_VDDCX_AO] = &SMPA2_LEVEL_vddcx_ao,
@@ -240,18 +264,14 @@ static const struct rpmpd_desc msm8976_desc = {
};

/* msm8994 RPM Power domains */
-DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, SMPA, CORNER, 2);
-/* Attention! *Some* 8994 boards with pm8004 may use SMPC here! */
-DEFINE_RPMPD_CORNER(vddgfx, SMPB, 2);
-
-DEFINE_RPMPD_VFC(vddgfx_vfc, SMPB, 2);
-
static struct rpmpd *msm8994_rpmpds[] = {
[MSM8994_VDDCX] = &SMPA1_CORNER_vddcx,
[MSM8994_VDDCX_AO] = &SMPA1_CORNER_vddcx_ao,
[MSM8994_VDDCX_VFC] = &SMPA1_vddcx_vfc,
[MSM8994_VDDMX] = &SMPA2_CORNER_vddmx,
[MSM8994_VDDMX_AO] = &SMPA2_CORNER_vddmx_ao,
+
+ /* Attention! *Some* 8994 boards with pm8004 may use SMPC here! */
[MSM8994_VDDGFX] = &SMPB2_vddgfx_corner,
[MSM8994_VDDGFX_VFC] = &SMPB2_vddgfx_vfc,
};
@@ -263,10 +283,6 @@ static const struct rpmpd_desc msm8994_desc = {
};

/* msm8996 RPM Power domains */
-DEFINE_RPMPD_CORNER(vddsscx, LDOA, 26);
-
-DEFINE_RPMPD_VFC(vddsscx_vfc, LDOA, 26);
-
static struct rpmpd *msm8996_rpmpds[] = {
[MSM8996_VDDCX] = &SMPA1_CORNER_vddcx,
[MSM8996_VDDCX_AO] = &SMPA1_CORNER_vddcx_ao,
@@ -284,18 +300,6 @@ static const struct rpmpd_desc msm8996_desc = {
};

/* msm8998 RPM Power domains */
-DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, RWCX, LEVEL, 0);
-DEFINE_RPMPD_VFL(vddcx_vfl, RWCX, 0);
-
-DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, RWMX, LEVEL, 0);
-DEFINE_RPMPD_VFL(vddmx_vfl, RWMX, 0);
-
-DEFINE_RPMPD_LEVEL(vdd_ssccx, RWSC, 0);
-DEFINE_RPMPD_VFL(vdd_ssccx_vfl, RWSC, 0);
-
-DEFINE_RPMPD_LEVEL(vdd_sscmx, RWSM, 0);
-DEFINE_RPMPD_VFL(vdd_sscmx_vfl, RWSM, 0);
-
static struct rpmpd *msm8998_rpmpds[] = {
[MSM8998_VDDCX] = &RWCX0_LEVEL_vddcx,
[MSM8998_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
@@ -316,12 +320,6 @@ static const struct rpmpd_desc msm8998_desc = {
};

/* qcs404 RPM Power domains */
-DEFINE_RPMPD_LEVEL(vdd_lpicx, RWLC, 0);
-DEFINE_RPMPD_VFL(vdd_lpicx_vfl, RWLC, 0);
-
-DEFINE_RPMPD_LEVEL(vdd_lpimx, RWLM, 0);
-DEFINE_RPMPD_VFL(vdd_lpimx_vfl, RWLM, 0);
-
static struct rpmpd *qcs404_rpmpds[] = {
[QCS404_VDDMX] = &RWMX0_LEVEL_vddmx,
[QCS404_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
@@ -339,13 +337,6 @@ static const struct rpmpd_desc qcs404_desc = {
};

/* sdm660 RPM Power domains */
-
-DEFINE_RPMPD_LEVEL(vdd_ssccx, RWLC, 0);
-DEFINE_RPMPD_VFL(vdd_ssccx_vfl, RWLC, 0);
-
-DEFINE_RPMPD_LEVEL(vdd_sscmx, RWLM, 0);
-DEFINE_RPMPD_VFL(vdd_sscmx_vfl, RWLM, 0);
-
static struct rpmpd *sdm660_rpmpds[] = {
[SDM660_VDDCX] = &RWCX0_LEVEL_vddcx,
[SDM660_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
@@ -366,9 +357,6 @@ static const struct rpmpd_desc sdm660_desc = {
};

/* sm4250/6115 RPM Power domains */
-DEFINE_RPMPD_LEVEL(vdd_lpi_cx, RWLC, 0);
-DEFINE_RPMPD_LEVEL(vdd_lpi_mx, RWLM, 0);
-
static struct rpmpd *sm6115_rpmpds[] = {
[SM6115_VDDCX] = &RWCX0_LEVEL_vddcx,
[SM6115_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
@@ -402,7 +390,6 @@ static const struct rpmpd_desc sm6125_desc = {
.max_state = RPM_SMD_LEVEL_BINNING,
};

-DEFINE_RPMPD_PAIR(vddgx, vddgx_ao, RWGX, LEVEL, 0);
static struct rpmpd *sm6375_rpmpds[] = {
[SM6375_VDDCX] = &RWCX0_LEVEL_vddcx,
[SM6375_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,

--
2.39.2


2023-03-13 20:00:27

by Konrad Dybcio

[permalink] [raw]
Subject: [PATCH v3 04/10] soc: qcom: rpmpd: Remove vdd* from struct names

It's rather obvious by the characteristic of these resources that
they correspond to some voltage lines governed by RPM. Remove the
"vdd" unnecessary prefix from them.

Signed-off-by: Konrad Dybcio <[email protected]>
---
drivers/soc/qcom/rpmpd.c | 312 +++++++++++++++++++++++------------------------
1 file changed, 156 insertions(+), 156 deletions(-)

diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c
index 8ba025c4eca3..8f145663af9a 100644
--- a/drivers/soc/qcom/rpmpd.c
+++ b/drivers/soc/qcom/rpmpd.c
@@ -117,63 +117,63 @@ struct rpmpd_desc {

static DEFINE_MUTEX(rpmpd_lock);

-DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, RWCX, LEVEL, 0);
-DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, CORNER, 1);
-DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, CORNER, 2);
-DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, LEVEL, 2);
-DEFINE_RPMPD_PAIR(vddcx, vddcx_ao, SMPA, LEVEL, 3);
-DEFINE_RPMPD_VFL(vddcx_vfl, RWCX, 0);
-DEFINE_RPMPD_VFL(vddcx_vfl, RWSC, 2);
-DEFINE_RPMPD_VFC(vddcx_vfc, SMPA, 1);
-DEFINE_RPMPD_VFC(vddcx_vfc, SMPA, 2);
-DEFINE_RPMPD_VFL(vddcx_vfl, SMPA, 2);
-DEFINE_RPMPD_VFL(vddcx_vfl, SMPA, 3);
-
-DEFINE_RPMPD_CORNER(vddgfx, SMPB, 2);
-DEFINE_RPMPD_VFC(vddgfx_vfc, SMPB, 2);
-
-DEFINE_RPMPD_PAIR(vddgx, vddgx_ao, RWGX, LEVEL, 0);
-
-DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, LDOA, CORNER, 3);
-DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, LDOA, LEVEL, 12);
-DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, SMPA, CORNER, 2);
-DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, RWMX, LEVEL, 0);
-DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, SMPA, LEVEL, 6);
-DEFINE_RPMPD_PAIR(vddmx, vddmx_ao, SMPA, LEVEL, 7);
-DEFINE_RPMPD_VFL(vddmx_vfl, LDOA, 12);
-DEFINE_RPMPD_VFL(vddmx_vfl, RWMX, 0);
-DEFINE_RPMPD_VFL(vddmx_vfl, RWSM, 6);
-
-DEFINE_RPMPD_PAIR(vddmd, vddmd_ao, SMPA, CORNER, 1);
-DEFINE_RPMPD_PAIR(vddmd, vddmd_ao, SMPA, LEVEL, 1);
-DEFINE_RPMPD_VFC(vddmd_vfc, SMPA, 1);
-
-DEFINE_RPMPD_LEVEL(vdd_lpi_cx, RWLC, 0);
-DEFINE_RPMPD_VFL(vdd_lpicx_vfl, RWLC, 0);
-
-DEFINE_RPMPD_LEVEL(vdd_lpi_mx, RWLM, 0);
-DEFINE_RPMPD_VFL(vdd_lpimx_vfl, RWLM, 0);
-
-DEFINE_RPMPD_CORNER(vddsscx, LDOA, 26);
-DEFINE_RPMPD_LEVEL(vdd_ssccx, RWLC, 0);
-DEFINE_RPMPD_LEVEL(vdd_ssccx, RWSC, 0);
-DEFINE_RPMPD_VFC(vddsscx_vfc, LDOA, 26);
-DEFINE_RPMPD_VFL(vdd_ssccx_vfl, RWLC, 0);
-DEFINE_RPMPD_VFL(vdd_ssccx_vfl, RWSC, 0);
-
-DEFINE_RPMPD_LEVEL(vdd_sscmx, RWLM, 0);
-DEFINE_RPMPD_LEVEL(vdd_sscmx, RWSM, 0);
-DEFINE_RPMPD_VFL(vdd_sscmx_vfl, RWLM, 0);
-DEFINE_RPMPD_VFL(vdd_sscmx_vfl, RWSM, 0);
+DEFINE_RPMPD_PAIR(cx, cx_ao, RWCX, LEVEL, 0);
+DEFINE_RPMPD_PAIR(cx, cx_ao, SMPA, CORNER, 1);
+DEFINE_RPMPD_PAIR(cx, cx_ao, SMPA, CORNER, 2);
+DEFINE_RPMPD_PAIR(cx, cx_ao, SMPA, LEVEL, 2);
+DEFINE_RPMPD_PAIR(cx, cx_ao, SMPA, LEVEL, 3);
+DEFINE_RPMPD_VFL(cx_vfl, RWCX, 0);
+DEFINE_RPMPD_VFL(cx_vfl, RWSC, 2);
+DEFINE_RPMPD_VFC(cx_vfc, SMPA, 1);
+DEFINE_RPMPD_VFC(cx_vfc, SMPA, 2);
+DEFINE_RPMPD_VFL(cx_vfl, SMPA, 2);
+DEFINE_RPMPD_VFL(cx_vfl, SMPA, 3);
+
+DEFINE_RPMPD_CORNER(gfx, SMPB, 2);
+DEFINE_RPMPD_VFC(gfx_vfc, SMPB, 2);
+
+DEFINE_RPMPD_PAIR(gx, gx_ao, RWGX, LEVEL, 0);
+
+DEFINE_RPMPD_PAIR(mx, mx_ao, LDOA, CORNER, 3);
+DEFINE_RPMPD_PAIR(mx, mx_ao, LDOA, LEVEL, 12);
+DEFINE_RPMPD_PAIR(mx, mx_ao, SMPA, CORNER, 2);
+DEFINE_RPMPD_PAIR(mx, mx_ao, RWMX, LEVEL, 0);
+DEFINE_RPMPD_PAIR(mx, mx_ao, SMPA, LEVEL, 6);
+DEFINE_RPMPD_PAIR(mx, mx_ao, SMPA, LEVEL, 7);
+DEFINE_RPMPD_VFL(mx_vfl, LDOA, 12);
+DEFINE_RPMPD_VFL(mx_vfl, RWMX, 0);
+DEFINE_RPMPD_VFL(mx_vfl, RWSM, 6);
+
+DEFINE_RPMPD_PAIR(md, md_ao, SMPA, CORNER, 1);
+DEFINE_RPMPD_PAIR(md, md_ao, SMPA, LEVEL, 1);
+DEFINE_RPMPD_VFC(md_vfc, SMPA, 1);
+
+DEFINE_RPMPD_LEVEL(lpi_cx, RWLC, 0);
+DEFINE_RPMPD_VFL(lpicx_vfl, RWLC, 0);
+
+DEFINE_RPMPD_LEVEL(lpi_mx, RWLM, 0);
+DEFINE_RPMPD_VFL(lpimx_vfl, RWLM, 0);
+
+DEFINE_RPMPD_CORNER(sscx, LDOA, 26);
+DEFINE_RPMPD_LEVEL(ssccx, RWLC, 0);
+DEFINE_RPMPD_LEVEL(ssccx, RWSC, 0);
+DEFINE_RPMPD_VFC(sscx_vfc, LDOA, 26);
+DEFINE_RPMPD_VFL(ssccx_vfl, RWLC, 0);
+DEFINE_RPMPD_VFL(ssccx_vfl, RWSC, 0);
+
+DEFINE_RPMPD_LEVEL(sscmx, RWLM, 0);
+DEFINE_RPMPD_LEVEL(sscmx, RWSM, 0);
+DEFINE_RPMPD_VFL(sscmx_vfl, RWLM, 0);
+DEFINE_RPMPD_VFL(sscmx_vfl, RWSM, 0);

/* mdm9607 RPM Power Domains */
static struct rpmpd *mdm9607_rpmpds[] = {
- [MDM9607_VDDCX] = &SMPA3_LEVEL_vddcx,
- [MDM9607_VDDCX_AO] = &SMPA3_LEVEL_vddcx_ao,
- [MDM9607_VDDCX_VFL] = &SMPA3_vddcx_vfl,
- [MDM9607_VDDMX] = &LDOA12_LEVEL_vddmx,
- [MDM9607_VDDMX_AO] = &LDOA12_LEVEL_vddmx_ao,
- [MDM9607_VDDMX_VFL] = &LDOA12_vddmx_vfl,
+ [MDM9607_VDDCX] = &SMPA3_LEVEL_cx,
+ [MDM9607_VDDCX_AO] = &SMPA3_LEVEL_cx_ao,
+ [MDM9607_VDDCX_VFL] = &SMPA3_cx_vfl,
+ [MDM9607_VDDMX] = &LDOA12_LEVEL_mx,
+ [MDM9607_VDDMX_AO] = &LDOA12_LEVEL_mx_ao,
+ [MDM9607_VDDMX_VFL] = &LDOA12_mx_vfl,
};

static const struct rpmpd_desc mdm9607_desc = {
@@ -184,9 +184,9 @@ static const struct rpmpd_desc mdm9607_desc = {

/* msm8226 RPM Power Domains */
static struct rpmpd *msm8226_rpmpds[] = {
- [MSM8226_VDDCX] = &SMPA1_CORNER_vddcx,
- [MSM8226_VDDCX_AO] = &SMPA1_CORNER_vddcx_ao,
- [MSM8226_VDDCX_VFC] = &SMPA1_vddcx_vfc,
+ [MSM8226_VDDCX] = &SMPA1_CORNER_cx,
+ [MSM8226_VDDCX_AO] = &SMPA1_CORNER_cx_ao,
+ [MSM8226_VDDCX_VFC] = &SMPA1_cx_vfc,
};

static const struct rpmpd_desc msm8226_desc = {
@@ -197,14 +197,14 @@ static const struct rpmpd_desc msm8226_desc = {

/* msm8939 RPM Power Domains */
static struct rpmpd *msm8939_rpmpds[] = {
- [MSM8939_VDDMDCX] = &SMPA1_CORNER_vddmd,
- [MSM8939_VDDMDCX_AO] = &SMPA1_CORNER_vddmd_ao,
- [MSM8939_VDDMDCX_VFC] = &SMPA1_vddmd_vfc,
- [MSM8939_VDDCX] = &SMPA2_CORNER_vddcx,
- [MSM8939_VDDCX_AO] = &SMPA2_CORNER_vddcx_ao,
- [MSM8939_VDDCX_VFC] = &SMPA2_vddcx_vfc,
- [MSM8939_VDDMX] = &LDOA3_CORNER_vddmx,
- [MSM8939_VDDMX_AO] = &LDOA3_CORNER_vddmx_ao,
+ [MSM8939_VDDMDCX] = &SMPA1_CORNER_md,
+ [MSM8939_VDDMDCX_AO] = &SMPA1_CORNER_md_ao,
+ [MSM8939_VDDMDCX_VFC] = &SMPA1_md_vfc,
+ [MSM8939_VDDCX] = &SMPA2_CORNER_cx,
+ [MSM8939_VDDCX_AO] = &SMPA2_CORNER_cx_ao,
+ [MSM8939_VDDCX_VFC] = &SMPA2_cx_vfc,
+ [MSM8939_VDDMX] = &LDOA3_CORNER_mx,
+ [MSM8939_VDDMX_AO] = &LDOA3_CORNER_mx_ao,
};

static const struct rpmpd_desc msm8939_desc = {
@@ -215,11 +215,11 @@ static const struct rpmpd_desc msm8939_desc = {

/* msm8916 RPM Power Domains */
static struct rpmpd *msm8916_rpmpds[] = {
- [MSM8916_VDDCX] = &SMPA1_CORNER_vddcx,
- [MSM8916_VDDCX_AO] = &SMPA1_CORNER_vddcx_ao,
- [MSM8916_VDDCX_VFC] = &SMPA1_vddcx_vfc,
- [MSM8916_VDDMX] = &LDOA3_CORNER_vddmx,
- [MSM8916_VDDMX_AO] = &LDOA3_CORNER_vddmx_ao,
+ [MSM8916_VDDCX] = &SMPA1_CORNER_cx,
+ [MSM8916_VDDCX_AO] = &SMPA1_CORNER_cx_ao,
+ [MSM8916_VDDCX_VFC] = &SMPA1_cx_vfc,
+ [MSM8916_VDDMX] = &LDOA3_CORNER_mx,
+ [MSM8916_VDDMX_AO] = &LDOA3_CORNER_mx_ao,
};

static const struct rpmpd_desc msm8916_desc = {
@@ -230,13 +230,13 @@ static const struct rpmpd_desc msm8916_desc = {

/* msm8953 RPM Power Domains */
static struct rpmpd *msm8953_rpmpds[] = {
- [MSM8953_VDDMD] = &SMPA1_LEVEL_vddmd,
- [MSM8953_VDDMD_AO] = &SMPA1_LEVEL_vddmd_ao,
- [MSM8953_VDDCX] = &SMPA2_LEVEL_vddcx,
- [MSM8953_VDDCX_AO] = &SMPA2_LEVEL_vddcx_ao,
- [MSM8953_VDDCX_VFL] = &SMPA2_vddcx_vfl,
- [MSM8953_VDDMX] = &SMPA7_LEVEL_vddmx,
- [MSM8953_VDDMX_AO] = &SMPA7_LEVEL_vddmx_ao,
+ [MSM8953_VDDMD] = &SMPA1_LEVEL_md,
+ [MSM8953_VDDMD_AO] = &SMPA1_LEVEL_md_ao,
+ [MSM8953_VDDCX] = &SMPA2_LEVEL_cx,
+ [MSM8953_VDDCX_AO] = &SMPA2_LEVEL_cx_ao,
+ [MSM8953_VDDCX_VFL] = &SMPA2_cx_vfl,
+ [MSM8953_VDDMX] = &SMPA7_LEVEL_mx,
+ [MSM8953_VDDMX_AO] = &SMPA7_LEVEL_mx_ao,
};

static const struct rpmpd_desc msm8953_desc = {
@@ -247,12 +247,12 @@ static const struct rpmpd_desc msm8953_desc = {

/* msm8976 RPM Power Domains */
static struct rpmpd *msm8976_rpmpds[] = {
- [MSM8976_VDDCX] = &SMPA2_LEVEL_vddcx,
- [MSM8976_VDDCX_AO] = &SMPA2_LEVEL_vddcx_ao,
- [MSM8976_VDDCX_VFL] = &RWSC2_vddcx_vfl,
- [MSM8976_VDDMX] = &SMPA6_LEVEL_vddmx,
- [MSM8976_VDDMX_AO] = &SMPA6_LEVEL_vddmx_ao,
- [MSM8976_VDDMX_VFL] = &RWSM6_vddmx_vfl,
+ [MSM8976_VDDCX] = &SMPA2_LEVEL_cx,
+ [MSM8976_VDDCX_AO] = &SMPA2_LEVEL_cx_ao,
+ [MSM8976_VDDCX_VFL] = &RWSC2_cx_vfl,
+ [MSM8976_VDDMX] = &SMPA6_LEVEL_mx,
+ [MSM8976_VDDMX_AO] = &SMPA6_LEVEL_mx_ao,
+ [MSM8976_VDDMX_VFL] = &RWSM6_mx_vfl,
};

static const struct rpmpd_desc msm8976_desc = {
@@ -263,15 +263,15 @@ static const struct rpmpd_desc msm8976_desc = {

/* msm8994 RPM Power domains */
static struct rpmpd *msm8994_rpmpds[] = {
- [MSM8994_VDDCX] = &SMPA1_CORNER_vddcx,
- [MSM8994_VDDCX_AO] = &SMPA1_CORNER_vddcx_ao,
- [MSM8994_VDDCX_VFC] = &SMPA1_vddcx_vfc,
- [MSM8994_VDDMX] = &SMPA2_CORNER_vddmx,
- [MSM8994_VDDMX_AO] = &SMPA2_CORNER_vddmx_ao,
+ [MSM8994_VDDCX] = &SMPA1_CORNER_cx,
+ [MSM8994_VDDCX_AO] = &SMPA1_CORNER_cx_ao,
+ [MSM8994_VDDCX_VFC] = &SMPA1_cx_vfc,
+ [MSM8994_VDDMX] = &SMPA2_CORNER_mx,
+ [MSM8994_VDDMX_AO] = &SMPA2_CORNER_mx_ao,

/* Attention! *Some* 8994 boards with pm8004 may use SMPC here! */
- [MSM8994_VDDGFX] = &SMPB2_vddgfx_corner,
- [MSM8994_VDDGFX_VFC] = &SMPB2_vddgfx_vfc,
+ [MSM8994_VDDGFX] = &SMPB2_gfx_corner,
+ [MSM8994_VDDGFX_VFC] = &SMPB2_gfx_vfc,
};

static const struct rpmpd_desc msm8994_desc = {
@@ -282,13 +282,13 @@ static const struct rpmpd_desc msm8994_desc = {

/* msm8996 RPM Power domains */
static struct rpmpd *msm8996_rpmpds[] = {
- [MSM8996_VDDCX] = &SMPA1_CORNER_vddcx,
- [MSM8996_VDDCX_AO] = &SMPA1_CORNER_vddcx_ao,
- [MSM8996_VDDCX_VFC] = &SMPA1_vddcx_vfc,
- [MSM8996_VDDMX] = &SMPA2_CORNER_vddmx,
- [MSM8996_VDDMX_AO] = &SMPA2_CORNER_vddmx_ao,
- [MSM8996_VDDSSCX] = &LDOA26_vddsscx_corner,
- [MSM8996_VDDSSCX_VFC] = &LDOA26_vddsscx_vfc,
+ [MSM8996_VDDCX] = &SMPA1_CORNER_cx,
+ [MSM8996_VDDCX_AO] = &SMPA1_CORNER_cx_ao,
+ [MSM8996_VDDCX_VFC] = &SMPA1_cx_vfc,
+ [MSM8996_VDDMX] = &SMPA2_CORNER_mx,
+ [MSM8996_VDDMX_AO] = &SMPA2_CORNER_mx_ao,
+ [MSM8996_VDDSSCX] = &LDOA26_sscx_corner,
+ [MSM8996_VDDSSCX_VFC] = &LDOA26_sscx_vfc,
};

static const struct rpmpd_desc msm8996_desc = {
@@ -299,16 +299,16 @@ static const struct rpmpd_desc msm8996_desc = {

/* msm8998 RPM Power domains */
static struct rpmpd *msm8998_rpmpds[] = {
- [MSM8998_VDDCX] = &RWCX0_LEVEL_vddcx,
- [MSM8998_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
- [MSM8998_VDDCX_VFL] = &RWCX0_vddcx_vfl,
- [MSM8998_VDDMX] = &RWMX0_LEVEL_vddmx,
- [MSM8998_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
- [MSM8998_VDDMX_VFL] = &RWMX0_vddmx_vfl,
- [MSM8998_SSCCX] = &RWSC0_vdd_ssccx_lvl,
- [MSM8998_SSCCX_VFL] = &RWSC0_vdd_ssccx_vfl,
- [MSM8998_SSCMX] = &RWSM0_vdd_sscmx_lvl,
- [MSM8998_SSCMX_VFL] = &RWSM0_vdd_sscmx_vfl,
+ [MSM8998_VDDCX] = &RWCX0_LEVEL_cx,
+ [MSM8998_VDDCX_AO] = &RWCX0_LEVEL_cx_ao,
+ [MSM8998_VDDCX_VFL] = &RWCX0_cx_vfl,
+ [MSM8998_VDDMX] = &RWMX0_LEVEL_mx,
+ [MSM8998_VDDMX_AO] = &RWMX0_LEVEL_mx_ao,
+ [MSM8998_VDDMX_VFL] = &RWMX0_mx_vfl,
+ [MSM8998_SSCCX] = &RWSC0_ssccx_lvl,
+ [MSM8998_SSCCX_VFL] = &RWSC0_ssccx_vfl,
+ [MSM8998_SSCMX] = &RWSM0_sscmx_lvl,
+ [MSM8998_SSCMX_VFL] = &RWSM0_sscmx_vfl,
};

static const struct rpmpd_desc msm8998_desc = {
@@ -319,13 +319,13 @@ static const struct rpmpd_desc msm8998_desc = {

/* qcs404 RPM Power domains */
static struct rpmpd *qcs404_rpmpds[] = {
- [QCS404_VDDMX] = &RWMX0_LEVEL_vddmx,
- [QCS404_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
- [QCS404_VDDMX_VFL] = &RWMX0_vddmx_vfl,
- [QCS404_LPICX] = &RWLC0_vdd_lpi_cx_lvl,
- [QCS404_LPICX_VFL] = &RWLC0_vdd_lpicx_vfl,
- [QCS404_LPIMX] = &RWLM0_vdd_lpi_mx_lvl,
- [QCS404_LPIMX_VFL] = &RWLM0_vdd_lpimx_vfl,
+ [QCS404_VDDMX] = &RWMX0_LEVEL_mx,
+ [QCS404_VDDMX_AO] = &RWMX0_LEVEL_mx_ao,
+ [QCS404_VDDMX_VFL] = &RWMX0_mx_vfl,
+ [QCS404_LPICX] = &RWLC0_lpi_cx_lvl,
+ [QCS404_LPICX_VFL] = &RWLC0_lpicx_vfl,
+ [QCS404_LPIMX] = &RWLM0_lpi_mx_lvl,
+ [QCS404_LPIMX_VFL] = &RWLM0_lpimx_vfl,
};

static const struct rpmpd_desc qcs404_desc = {
@@ -336,16 +336,16 @@ static const struct rpmpd_desc qcs404_desc = {

/* sdm660 RPM Power domains */
static struct rpmpd *sdm660_rpmpds[] = {
- [SDM660_VDDCX] = &RWCX0_LEVEL_vddcx,
- [SDM660_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
- [SDM660_VDDCX_VFL] = &RWCX0_vddcx_vfl,
- [SDM660_VDDMX] = &RWMX0_LEVEL_vddmx,
- [SDM660_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
- [SDM660_VDDMX_VFL] = &RWMX0_vddmx_vfl,
- [SDM660_SSCCX] = &RWLC0_vdd_ssccx_lvl,
- [SDM660_SSCCX_VFL] = &RWLC0_vdd_ssccx_vfl,
- [SDM660_SSCMX] = &RWLM0_vdd_sscmx_lvl,
- [SDM660_SSCMX_VFL] = &RWLM0_vdd_sscmx_vfl,
+ [SDM660_VDDCX] = &RWCX0_LEVEL_cx,
+ [SDM660_VDDCX_AO] = &RWCX0_LEVEL_cx_ao,
+ [SDM660_VDDCX_VFL] = &RWCX0_cx_vfl,
+ [SDM660_VDDMX] = &RWMX0_LEVEL_mx,
+ [SDM660_VDDMX_AO] = &RWMX0_LEVEL_mx_ao,
+ [SDM660_VDDMX_VFL] = &RWMX0_mx_vfl,
+ [SDM660_SSCCX] = &RWLC0_ssccx_lvl,
+ [SDM660_SSCCX_VFL] = &RWLC0_ssccx_vfl,
+ [SDM660_SSCMX] = &RWLM0_sscmx_lvl,
+ [SDM660_SSCMX_VFL] = &RWLM0_sscmx_vfl,
};

static const struct rpmpd_desc sdm660_desc = {
@@ -356,14 +356,14 @@ static const struct rpmpd_desc sdm660_desc = {

/* sm4250/6115 RPM Power domains */
static struct rpmpd *sm6115_rpmpds[] = {
- [SM6115_VDDCX] = &RWCX0_LEVEL_vddcx,
- [SM6115_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
- [SM6115_VDDCX_VFL] = &RWCX0_vddcx_vfl,
- [SM6115_VDDMX] = &RWMX0_LEVEL_vddmx,
- [SM6115_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
- [SM6115_VDDMX_VFL] = &RWMX0_vddmx_vfl,
- [SM6115_VDD_LPI_CX] = &RWLC0_vdd_lpi_cx_lvl,
- [SM6115_VDD_LPI_MX] = &RWLM0_vdd_lpi_mx_lvl,
+ [SM6115_VDDCX] = &RWCX0_LEVEL_cx,
+ [SM6115_VDDCX_AO] = &RWCX0_LEVEL_cx_ao,
+ [SM6115_VDDCX_VFL] = &RWCX0_cx_vfl,
+ [SM6115_VDDMX] = &RWMX0_LEVEL_mx,
+ [SM6115_VDDMX_AO] = &RWMX0_LEVEL_mx_ao,
+ [SM6115_VDDMX_VFL] = &RWMX0_mx_vfl,
+ [SM6115_VDD_LPI_CX] = &RWLC0_lpi_cx_lvl,
+ [SM6115_VDD_LPI_MX] = &RWLM0_lpi_mx_lvl,
};

static const struct rpmpd_desc sm6115_desc = {
@@ -374,12 +374,12 @@ static const struct rpmpd_desc sm6115_desc = {

/* sm6125 RPM Power domains */
static struct rpmpd *sm6125_rpmpds[] = {
- [SM6125_VDDCX] = &RWCX0_LEVEL_vddcx,
- [SM6125_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
- [SM6125_VDDCX_VFL] = &RWCX0_vddcx_vfl,
- [SM6125_VDDMX] = &RWMX0_LEVEL_vddmx,
- [SM6125_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
- [SM6125_VDDMX_VFL] = &RWMX0_vddmx_vfl,
+ [SM6125_VDDCX] = &RWCX0_LEVEL_cx,
+ [SM6125_VDDCX_AO] = &RWCX0_LEVEL_cx_ao,
+ [SM6125_VDDCX_VFL] = &RWCX0_cx_vfl,
+ [SM6125_VDDMX] = &RWMX0_LEVEL_mx,
+ [SM6125_VDDMX_AO] = &RWMX0_LEVEL_mx_ao,
+ [SM6125_VDDMX_VFL] = &RWMX0_mx_vfl,
};

static const struct rpmpd_desc sm6125_desc = {
@@ -389,16 +389,16 @@ static const struct rpmpd_desc sm6125_desc = {
};

static struct rpmpd *sm6375_rpmpds[] = {
- [SM6375_VDDCX] = &RWCX0_LEVEL_vddcx,
- [SM6375_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
- [SM6375_VDDCX_VFL] = &RWCX0_vddcx_vfl,
- [SM6375_VDDMX] = &RWMX0_LEVEL_vddmx,
- [SM6375_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
- [SM6375_VDDMX_VFL] = &RWMX0_vddmx_vfl,
- [SM6375_VDDGX] = &RWGX0_LEVEL_vddgx,
- [SM6375_VDDGX_AO] = &RWGX0_LEVEL_vddgx_ao,
- [SM6375_VDD_LPI_CX] = &RWLC0_vdd_lpi_cx_lvl,
- [SM6375_VDD_LPI_MX] = &RWLM0_vdd_lpi_mx_lvl,
+ [SM6375_VDDCX] = &RWCX0_LEVEL_cx,
+ [SM6375_VDDCX_AO] = &RWCX0_LEVEL_cx_ao,
+ [SM6375_VDDCX_VFL] = &RWCX0_cx_vfl,
+ [SM6375_VDDMX] = &RWMX0_LEVEL_mx,
+ [SM6375_VDDMX_AO] = &RWMX0_LEVEL_mx_ao,
+ [SM6375_VDDMX_VFL] = &RWMX0_mx_vfl,
+ [SM6375_VDDGX] = &RWGX0_LEVEL_gx,
+ [SM6375_VDDGX_AO] = &RWGX0_LEVEL_gx_ao,
+ [SM6375_VDD_LPI_CX] = &RWLC0_lpi_cx_lvl,
+ [SM6375_VDD_LPI_MX] = &RWLM0_lpi_mx_lvl,
};

static const struct rpmpd_desc sm6375_desc = {
@@ -408,14 +408,14 @@ static const struct rpmpd_desc sm6375_desc = {
};

static struct rpmpd *qcm2290_rpmpds[] = {
- [QCM2290_VDDCX] = &RWCX0_LEVEL_vddcx,
- [QCM2290_VDDCX_AO] = &RWCX0_LEVEL_vddcx_ao,
- [QCM2290_VDDCX_VFL] = &RWCX0_vddcx_vfl,
- [QCM2290_VDDMX] = &RWMX0_LEVEL_vddmx,
- [QCM2290_VDDMX_AO] = &RWMX0_LEVEL_vddmx_ao,
- [QCM2290_VDDMX_VFL] = &RWMX0_vddmx_vfl,
- [QCM2290_VDD_LPI_CX] = &RWLC0_vdd_lpi_cx_lvl,
- [QCM2290_VDD_LPI_MX] = &RWLM0_vdd_lpi_mx_lvl,
+ [QCM2290_VDDCX] = &RWCX0_LEVEL_cx,
+ [QCM2290_VDDCX_AO] = &RWCX0_LEVEL_cx_ao,
+ [QCM2290_VDDCX_VFL] = &RWCX0_cx_vfl,
+ [QCM2290_VDDMX] = &RWMX0_LEVEL_mx,
+ [QCM2290_VDDMX_AO] = &RWMX0_LEVEL_mx_ao,
+ [QCM2290_VDDMX_VFL] = &RWMX0_mx_vfl,
+ [QCM2290_VDD_LPI_CX] = &RWLC0_lpi_cx_lvl,
+ [QCM2290_VDD_LPI_MX] = &RWLM0_lpi_mx_lvl,
};

static const struct rpmpd_desc qcm2290_desc = {

--
2.39.2


2023-03-13 20:00:30

by Konrad Dybcio

[permalink] [raw]
Subject: [PATCH v3 08/10] soc: qcom: rpmpd: Add parent PD support

In some cases (like with the GPU core clock on GMU-less SoCs) it's
required that we scale more than one voltage domain. This can be achieved
by linking them in a parent-child relationship. Add support for specifying
a parent PD, similarly to what has been done in the RPMhPD driver.

Signed-off-by: Konrad Dybcio <[email protected]>
---
drivers/soc/qcom/rpmpd.c | 10 ++++++++++
1 file changed, 10 insertions(+)

diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c
index 946630d82b3d..2027c820caa7 100644
--- a/drivers/soc/qcom/rpmpd.c
+++ b/drivers/soc/qcom/rpmpd.c
@@ -48,6 +48,7 @@ struct rpmpd_req {

struct rpmpd {
struct generic_pm_domain pd;
+ struct generic_pm_domain *parent;
struct rpmpd *peer;
const bool active_only;
unsigned int corner;
@@ -969,6 +970,15 @@ static int rpmpd_probe(struct platform_device *pdev)
data->domains[i] = &rpmpds[i]->pd;
}

+ /* Add subdomains */
+ for (i = 0; i < num; i++) {
+ if (!rpmpds[i])
+ continue;
+
+ if (rpmpds[i]->parent)
+ pm_genpd_add_subdomain(rpmpds[i]->parent, &rpmpds[i]->pd);
+ }
+
return of_genpd_add_provider_onecell(pdev->dev.of_node, data);
}


--
2.39.2


2023-03-13 20:00:36

by Konrad Dybcio

[permalink] [raw]
Subject: [PATCH v3 05/10] soc: qcom: rpmpd: Expand struct definition macros

Expand the struct definition macros to make things easier to see and
maintain. Now that the macros are unnecessary, remove them.

Signed-off-by: Konrad Dybcio <[email protected]>
---
drivers/soc/qcom/rpmpd.c | 539 ++++++++++++++++++++++++++++++++++++++---------
1 file changed, 441 insertions(+), 98 deletions(-)

diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c
index 8f145663af9a..df4e0d8a2aa9 100644
--- a/drivers/soc/qcom/rpmpd.c
+++ b/drivers/soc/qcom/rpmpd.c
@@ -40,56 +40,6 @@

#define MAX_CORNER_RPMPD_STATE 6

-#define DEFINE_RPMPD_PAIR(_name, _active, r_type, r_key, r_id) \
- static struct rpmpd r_type##r_id##_##r_key##_##_active; \
- static struct rpmpd r_type##r_id##_##r_key##_##_name = { \
- .pd = { .name = #_name, }, \
- .peer = &r_type##r_id##_##r_key##_##_active, \
- .res_type = RPMPD_##r_type, \
- .res_id = r_id, \
- .key = KEY_##r_key, \
- }; \
- static struct rpmpd r_type##r_id##_##r_key##_##_active = { \
- .pd = { .name = #_active, }, \
- .peer = &r_type##r_id##_##r_key##_##_name, \
- .active_only = true, \
- .res_type = RPMPD_##r_type, \
- .res_id = r_id, \
- .key = KEY_##r_key, \
- }
-
-#define DEFINE_RPMPD_CORNER(_name, r_type, r_id) \
- static struct rpmpd r_type##r_id##_##_name##_corner = { \
- .pd = { .name = #_name, }, \
- .res_type = RPMPD_##r_type, \
- .res_id = r_id, \
- .key = KEY_CORNER, \
- }
-
-#define DEFINE_RPMPD_LEVEL(_name, r_type, r_id) \
- static struct rpmpd r_type##r_id##_##_name##_lvl = { \
- .pd = { .name = #_name, }, \
- .res_type = RPMPD_##r_type, \
- .res_id = r_id, \
- .key = KEY_LEVEL, \
- }
-
-#define DEFINE_RPMPD_VFC(_name, r_type, r_id) \
- static struct rpmpd r_type##r_id##_##_name = { \
- .pd = { .name = #_name, }, \
- .res_type = RPMPD_##r_type, \
- .res_id = r_id, \
- .key = KEY_FLOOR_CORNER, \
- }
-
-#define DEFINE_RPMPD_VFL(_name, r_type, r_id) \
- static struct rpmpd r_type##r_id##_##_name = { \
- .pd = { .name = #_name, }, \
- .res_type = RPMPD_##r_type, \
- .res_id = r_id, \
- .key = KEY_FLOOR_LEVEL, \
- }
-
struct rpmpd_req {
__le32 key;
__le32 nbytes;
@@ -117,54 +67,447 @@ struct rpmpd_desc {

static DEFINE_MUTEX(rpmpd_lock);

-DEFINE_RPMPD_PAIR(cx, cx_ao, RWCX, LEVEL, 0);
-DEFINE_RPMPD_PAIR(cx, cx_ao, SMPA, CORNER, 1);
-DEFINE_RPMPD_PAIR(cx, cx_ao, SMPA, CORNER, 2);
-DEFINE_RPMPD_PAIR(cx, cx_ao, SMPA, LEVEL, 2);
-DEFINE_RPMPD_PAIR(cx, cx_ao, SMPA, LEVEL, 3);
-DEFINE_RPMPD_VFL(cx_vfl, RWCX, 0);
-DEFINE_RPMPD_VFL(cx_vfl, RWSC, 2);
-DEFINE_RPMPD_VFC(cx_vfc, SMPA, 1);
-DEFINE_RPMPD_VFC(cx_vfc, SMPA, 2);
-DEFINE_RPMPD_VFL(cx_vfl, SMPA, 2);
-DEFINE_RPMPD_VFL(cx_vfl, SMPA, 3);
-
-DEFINE_RPMPD_CORNER(gfx, SMPB, 2);
-DEFINE_RPMPD_VFC(gfx_vfc, SMPB, 2);
-
-DEFINE_RPMPD_PAIR(gx, gx_ao, RWGX, LEVEL, 0);
-
-DEFINE_RPMPD_PAIR(mx, mx_ao, LDOA, CORNER, 3);
-DEFINE_RPMPD_PAIR(mx, mx_ao, LDOA, LEVEL, 12);
-DEFINE_RPMPD_PAIR(mx, mx_ao, SMPA, CORNER, 2);
-DEFINE_RPMPD_PAIR(mx, mx_ao, RWMX, LEVEL, 0);
-DEFINE_RPMPD_PAIR(mx, mx_ao, SMPA, LEVEL, 6);
-DEFINE_RPMPD_PAIR(mx, mx_ao, SMPA, LEVEL, 7);
-DEFINE_RPMPD_VFL(mx_vfl, LDOA, 12);
-DEFINE_RPMPD_VFL(mx_vfl, RWMX, 0);
-DEFINE_RPMPD_VFL(mx_vfl, RWSM, 6);
-
-DEFINE_RPMPD_PAIR(md, md_ao, SMPA, CORNER, 1);
-DEFINE_RPMPD_PAIR(md, md_ao, SMPA, LEVEL, 1);
-DEFINE_RPMPD_VFC(md_vfc, SMPA, 1);
-
-DEFINE_RPMPD_LEVEL(lpi_cx, RWLC, 0);
-DEFINE_RPMPD_VFL(lpicx_vfl, RWLC, 0);
-
-DEFINE_RPMPD_LEVEL(lpi_mx, RWLM, 0);
-DEFINE_RPMPD_VFL(lpimx_vfl, RWLM, 0);
-
-DEFINE_RPMPD_CORNER(sscx, LDOA, 26);
-DEFINE_RPMPD_LEVEL(ssccx, RWLC, 0);
-DEFINE_RPMPD_LEVEL(ssccx, RWSC, 0);
-DEFINE_RPMPD_VFC(sscx_vfc, LDOA, 26);
-DEFINE_RPMPD_VFL(ssccx_vfl, RWLC, 0);
-DEFINE_RPMPD_VFL(ssccx_vfl, RWSC, 0);
-
-DEFINE_RPMPD_LEVEL(sscmx, RWLM, 0);
-DEFINE_RPMPD_LEVEL(sscmx, RWSM, 0);
-DEFINE_RPMPD_VFL(sscmx_vfl, RWLM, 0);
-DEFINE_RPMPD_VFL(sscmx_vfl, RWSM, 0);
+/* CX */
+static struct rpmpd RWCX0_LEVEL_cx_ao;
+static struct rpmpd RWCX0_LEVEL_cx = {
+ .pd = { .name = "cx", },
+ .peer = &RWCX0_LEVEL_cx_ao,
+ .res_type = RPMPD_RWCX,
+ .res_id = 0,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd RWCX0_LEVEL_cx_ao = {
+ .pd = { .name = "cx_ao", },
+ .peer = &RWCX0_LEVEL_cx,
+ .active_only = true,
+ .res_type = RPMPD_RWCX,
+ .res_id = 0,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd SMPA1_CORNER_cx_ao;
+static struct rpmpd SMPA1_CORNER_cx = {
+ .pd = { .name = "cx", },
+ .peer = &SMPA1_CORNER_cx_ao,
+ .res_type = RPMPD_SMPA,
+ .res_id = 1,
+ .key = KEY_CORNER,
+};
+
+static struct rpmpd SMPA1_CORNER_cx_ao = {
+ .pd = { .name = "cx_ao", },
+ .peer = &SMPA1_CORNER_cx,
+ .active_only = true,
+ .res_type = RPMPD_SMPA,
+ .res_id = 1,
+ .key = KEY_CORNER,
+};
+
+static struct rpmpd SMPA2_CORNER_cx_ao;
+static struct rpmpd SMPA2_CORNER_cx = {
+ .pd = { .name = "cx", },
+ .peer = &SMPA2_CORNER_cx_ao,
+ .res_type = RPMPD_SMPA,
+ .res_id = 2,
+ .key = KEY_CORNER,
+};
+
+static struct rpmpd SMPA2_CORNER_cx_ao = {
+ .pd = { .name = "cx_ao", },
+ .peer = &SMPA2_CORNER_cx,
+ .active_only = true,
+ .res_type = RPMPD_SMPA,
+ .res_id = 2,
+ .key = KEY_CORNER,
+};
+
+static struct rpmpd SMPA2_LEVEL_cx_ao;
+static struct rpmpd SMPA2_LEVEL_cx = {
+ .pd = { .name = "cx", },
+ .peer = &SMPA2_LEVEL_cx_ao,
+ .res_type = RPMPD_SMPA,
+ .res_id = 2,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd SMPA2_LEVEL_cx_ao = {
+ .pd = { .name = "cx_ao", },
+ .peer = &SMPA2_LEVEL_cx,
+ .active_only = true,
+ .res_type = RPMPD_SMPA,
+ .res_id = 2,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd SMPA3_LEVEL_cx_ao;
+static struct rpmpd SMPA3_LEVEL_cx = {
+ .pd = { .name = "cx", },
+ .peer = &SMPA3_LEVEL_cx_ao,
+ .res_type = RPMPD_SMPA,
+ .res_id = 3,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd SMPA3_LEVEL_cx_ao = {
+ .pd = { .name = "cx_ao", },
+ .peer = &SMPA3_LEVEL_cx,
+ .active_only = true,
+ .res_type = RPMPD_SMPA,
+ .res_id = 3,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd RWCX0_cx_vfl = {
+ .pd = { .name = "cx_vfl", },
+ .res_type = RPMPD_RWCX,
+ .res_id = 0,
+ .key = KEY_FLOOR_LEVEL,
+};
+
+static struct rpmpd RWSC2_cx_vfl = {
+ .pd = { .name = "cx_vfl", },
+ .res_type = RPMPD_RWSC,
+ .res_id = 2,
+ .key = KEY_FLOOR_LEVEL,
+};
+
+static struct rpmpd SMPA1_cx_vfc = {
+ .pd = { .name = "cx_vfc", },
+ .res_type = RPMPD_SMPA,
+ .res_id = 1,
+ .key = KEY_FLOOR_CORNER,
+};
+
+static struct rpmpd SMPA2_cx_vfc = {
+ .pd = { .name = "cx_vfc", },
+ .res_type = RPMPD_SMPA,
+ .res_id = 2,
+ .key = KEY_FLOOR_CORNER,
+};
+
+static struct rpmpd SMPA2_cx_vfl = {
+ .pd = { .name = "cx_vfl", },
+ .res_type = RPMPD_SMPA,
+ .res_id = 2,
+ .key = KEY_FLOOR_LEVEL,
+};
+
+static struct rpmpd SMPA3_cx_vfl = {
+ .pd = { .name = "cx_vfl", },
+ .res_type = RPMPD_SMPA,
+ .res_id = 3,
+ .key = KEY_FLOOR_LEVEL,
+};
+
+/* G(F)X */
+static struct rpmpd SMPB2_gfx_corner = {
+ .pd = { .name = "gfx", },
+ .res_type = RPMPD_SMPB,
+ .res_id = 2,
+ .key = KEY_CORNER,
+};
+
+static struct rpmpd SMPB2_gfx_vfc = {
+ .pd = { .name = "gfx_vfc", },
+ .res_type = RPMPD_SMPB,
+ .res_id = 2,
+ .key = KEY_FLOOR_CORNER,
+};
+
+static struct rpmpd RWGX0_LEVEL_gx_ao;
+static struct rpmpd RWGX0_LEVEL_gx = {
+ .pd = { .name = "gx", },
+ .peer = &RWGX0_LEVEL_gx_ao,
+ .res_type = RPMPD_RWGX,
+ .res_id = 0,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd RWGX0_LEVEL_gx_ao = {
+ .pd = { .name = "gx_ao", },
+ .peer = &RWGX0_LEVEL_gx,
+ .active_only = true,
+ .res_type = RPMPD_RWGX,
+ .res_id = 0,
+ .key = KEY_LEVEL,
+};
+
+/* MX */
+static struct rpmpd LDOA3_CORNER_mx_ao;
+static struct rpmpd LDOA3_CORNER_mx = {
+ .pd = { .name = "mx", },
+ .peer = &LDOA3_CORNER_mx_ao,
+ .res_type = RPMPD_LDOA,
+ .res_id = 3,
+ .key = KEY_CORNER,
+};
+
+static struct rpmpd LDOA3_CORNER_mx_ao = {
+ .pd = { .name = "mx_ao", },
+ .peer = &LDOA3_CORNER_mx,
+ .active_only = true,
+ .res_type = RPMPD_LDOA,
+ .res_id = 3,
+ .key = KEY_CORNER,
+};
+
+static struct rpmpd LDOA12_LEVEL_mx_ao;
+static struct rpmpd LDOA12_LEVEL_mx = {
+ .pd = { .name = "mx", },
+ .peer = &LDOA12_LEVEL_mx_ao,
+ .res_type = RPMPD_LDOA,
+ .res_id = 12,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd LDOA12_LEVEL_mx_ao = {
+ .pd = { .name = "mx_ao", },
+ .peer = &LDOA12_LEVEL_mx,
+ .active_only = true,
+ .res_type = RPMPD_LDOA,
+ .res_id = 12,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd SMPA2_CORNER_mx_ao;
+static struct rpmpd SMPA2_CORNER_mx = {
+ .pd = { .name = "mx", },
+ .peer = &SMPA2_CORNER_mx_ao,
+ .res_type = RPMPD_SMPA,
+ .res_id = 2,
+ .key = KEY_CORNER,
+};
+
+static struct rpmpd SMPA2_CORNER_mx_ao = {
+ .pd = { .name = "mx_ao", },
+ .peer = &SMPA2_CORNER_mx,
+ .active_only = true,
+ .res_type = RPMPD_SMPA,
+ .res_id = 2,
+ .key = KEY_CORNER,
+};
+
+static struct rpmpd RWMX0_LEVEL_mx_ao;
+static struct rpmpd RWMX0_LEVEL_mx = {
+ .pd = { .name = "mx", },
+ .peer = &RWMX0_LEVEL_mx_ao,
+ .res_type = RPMPD_RWMX,
+ .res_id = 0,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd RWMX0_LEVEL_mx_ao = {
+ .pd = { .name = "mx_ao", },
+ .peer = &RWMX0_LEVEL_mx,
+ .active_only = true,
+ .res_type = RPMPD_RWMX,
+ .res_id = 0,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd SMPA6_LEVEL_mx_ao;
+static struct rpmpd SMPA6_LEVEL_mx = {
+ .pd = { .name = "mx", },
+ .peer = &SMPA6_LEVEL_mx_ao,
+ .res_type = RPMPD_SMPA,
+ .res_id = 6,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd SMPA6_LEVEL_mx_ao = {
+ .pd = { .name = "mx_ao", },
+ .peer = &SMPA6_LEVEL_mx,
+ .active_only = true,
+ .res_type = RPMPD_SMPA,
+ .res_id = 6,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd SMPA7_LEVEL_mx_ao;
+static struct rpmpd SMPA7_LEVEL_mx = {
+ .pd = { .name = "mx", },
+ .peer = &SMPA7_LEVEL_mx_ao,
+ .res_type = RPMPD_SMPA,
+ .res_id = 7,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd SMPA7_LEVEL_mx_ao = {
+ .pd = { .name = "mx_ao", },
+ .peer = &SMPA7_LEVEL_mx,
+ .active_only = true,
+ .res_type = RPMPD_SMPA,
+ .res_id = 7,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd LDOA12_mx_vfl = {
+ .pd = { .name = "mx_vfl", },
+ .res_type = RPMPD_LDOA,
+ .res_id = 12,
+ .key = KEY_FLOOR_LEVEL,
+};
+
+static struct rpmpd RWMX0_mx_vfl = {
+ .pd = { .name = "mx_vfl", },
+ .res_type = RPMPD_RWMX,
+ .res_id = 0,
+ .key = KEY_FLOOR_LEVEL,
+};
+
+static struct rpmpd RWSM6_mx_vfl = {
+ .pd = { .name = "mx_vfl", },
+ .res_type = RPMPD_RWSM,
+ .res_id = 6,
+ .key = KEY_FLOOR_LEVEL,
+};
+
+/* MD */
+static struct rpmpd SMPA1_CORNER_md_ao;
+static struct rpmpd SMPA1_CORNER_md = {
+ .pd = { .name = "md", },
+ .peer = &SMPA1_CORNER_md_ao,
+ .res_type = RPMPD_SMPA,
+ .res_id = 1,
+ .key = KEY_CORNER,
+};
+
+static struct rpmpd SMPA1_CORNER_md_ao = {
+ .pd = { .name = "md_ao", },
+ .peer = &SMPA1_CORNER_md,
+ .active_only = true,
+ .res_type = RPMPD_SMPA,
+ .res_id = 1,
+ .key = KEY_CORNER,
+};
+
+static struct rpmpd SMPA1_LEVEL_md_ao;
+static struct rpmpd SMPA1_LEVEL_md = {
+ .pd = { .name = "md", },
+ .peer = &SMPA1_LEVEL_md_ao,
+ .res_type = RPMPD_SMPA,
+ .res_id = 1,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd SMPA1_LEVEL_md_ao = {
+ .pd = { .name = "md_ao", },
+ .peer = &SMPA1_LEVEL_md,
+ .active_only = true,
+ .res_type = RPMPD_SMPA,
+ .res_id = 1,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd SMPA1_md_vfc = {
+ .pd = { .name = "md_vfc", },
+ .res_type = RPMPD_SMPA,
+ .res_id = 1,
+ .key = KEY_FLOOR_CORNER,
+};
+
+/* LPI_CX */
+static struct rpmpd RWLC0_lpi_cx_lvl = {
+ .pd = { .name = "lpi_cx", },
+ .res_type = RPMPD_RWLC,
+ .res_id = 0,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd RWLC0_lpicx_vfl = {
+ .pd = { .name = "lpicx_vfl", },
+ .res_type = RPMPD_RWLC,
+ .res_id = 0,
+ .key = KEY_FLOOR_LEVEL,
+};
+
+/* LPI_MX */
+static struct rpmpd RWLM0_lpi_mx_lvl = {
+ .pd = { .name = "lpi_mx", },
+ .res_type = RPMPD_RWLM,
+ .res_id = 0,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd RWLM0_lpimx_vfl = {
+ .pd = { .name = "lpimx_vfl", },
+ .res_type = RPMPD_RWLM,
+ .res_id = 0,
+ .key = KEY_FLOOR_LEVEL,
+};
+
+/* SSC_CX */
+static struct rpmpd LDOA26_sscx_corner = {
+ .pd = { .name = "sscx", },
+ .res_type = RPMPD_LDOA,
+ .res_id = 26,
+ .key = KEY_CORNER,
+};
+
+static struct rpmpd RWLC0_ssccx_lvl = {
+ .pd = { .name = "ssccx", },
+ .res_type = RPMPD_RWLC,
+ .res_id = 0,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd RWSC0_ssccx_lvl = {
+ .pd = { .name = "ssccx", },
+ .res_type = RPMPD_RWSC,
+ .res_id = 0,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd LDOA26_sscx_vfc = {
+ .pd = { .name = "sscx_vfc", },
+ .res_type = RPMPD_LDOA,
+ .res_id = 26,
+ .key = KEY_FLOOR_CORNER,
+};
+
+static struct rpmpd RWLC0_ssccx_vfl = {
+ .pd = { .name = "ssccx_vfl", },
+ .res_type = RPMPD_RWLC,
+ .res_id = 0,
+ .key = KEY_FLOOR_LEVEL,
+};
+
+static struct rpmpd RWSC0_ssccx_vfl = {
+ .pd = { .name = "ssccx_vfl", },
+ .res_type = RPMPD_RWSC,
+ .res_id = 0,
+ .key = KEY_FLOOR_LEVEL,
+};
+
+/* SSC_MX */
+static struct rpmpd RWLM0_sscmx_lvl = {
+ .pd = { .name = "sscmx", },
+ .res_type = RPMPD_RWLM,
+ .res_id = 0,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd RWSM0_sscmx_lvl = {
+ .pd = { .name = "sscmx", },
+ .res_type = RPMPD_RWSM,
+ .res_id = 0,
+ .key = KEY_LEVEL,
+};
+
+static struct rpmpd RWLM0_sscmx_vfl = {
+ .pd = { .name = "sscmx_vfl", },
+ .res_type = RPMPD_RWLM,
+ .res_id = 0,
+ .key = KEY_FLOOR_LEVEL,
+};
+
+static struct rpmpd RWSM0_sscmx_vfl = {
+ .pd = { .name = "sscmx_vfl", },
+ .res_type = RPMPD_RWSM,
+ .res_id = 0,
+ .key = KEY_FLOOR_LEVEL,
+};

/* mdm9607 RPM Power Domains */
static struct rpmpd *mdm9607_rpmpds[] = {

--
2.39.2


2023-03-13 20:00:42

by Konrad Dybcio

[permalink] [raw]
Subject: [PATCH v3 07/10] soc: qcom: rpmpd: Make bindings assignments consistent

Currently the whitespace between [DT_BINDING] = &struct is all over
the place.. some SoC structs have a space, others have a tab, others
have N tabs.. Make that a single tab for everybody to keep things
coherent.

Signed-off-by: Konrad Dybcio <[email protected]>
---
drivers/soc/qcom/rpmpd.c | 118 +++++++++++++++++++++++------------------------
1 file changed, 59 insertions(+), 59 deletions(-)

diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c
index 695b2fc56f40..946630d82b3d 100644
--- a/drivers/soc/qcom/rpmpd.c
+++ b/drivers/soc/qcom/rpmpd.c
@@ -642,16 +642,16 @@ static const struct rpmpd_desc msm8996_desc = {

/* msm8998 RPM Power domains */
static struct rpmpd *msm8998_rpmpds[] = {
- [MSM8998_VDDCX] = &cx_rwcx0_lvl,
- [MSM8998_VDDCX_AO] = &cx_rwcx0_lvl_ao,
- [MSM8998_VDDCX_VFL] = &cx_rwcx0_vfl,
- [MSM8998_VDDMX] = &mx_rwmx0_lvl,
- [MSM8998_VDDMX_AO] = &mx_rwmx0_lvl_ao,
- [MSM8998_VDDMX_VFL] = &mx_rwmx0_vfl,
- [MSM8998_SSCCX] = &ssc_cx_rwsc0_lvl,
- [MSM8998_SSCCX_VFL] = &ssc_cx_rwsc0_vfl,
- [MSM8998_SSCMX] = &ssc_mx_rwsm0_lvl,
- [MSM8998_SSCMX_VFL] = &ssc_mx_rwsm0_vfl,
+ [MSM8998_VDDCX] = &cx_rwcx0_lvl,
+ [MSM8998_VDDCX_AO] = &cx_rwcx0_lvl_ao,
+ [MSM8998_VDDCX_VFL] = &cx_rwcx0_vfl,
+ [MSM8998_VDDMX] = &mx_rwmx0_lvl,
+ [MSM8998_VDDMX_AO] = &mx_rwmx0_lvl_ao,
+ [MSM8998_VDDMX_VFL] = &mx_rwmx0_vfl,
+ [MSM8998_SSCCX] = &ssc_cx_rwsc0_lvl,
+ [MSM8998_SSCCX_VFL] = &ssc_cx_rwsc0_vfl,
+ [MSM8998_SSCMX] = &ssc_mx_rwsm0_lvl,
+ [MSM8998_SSCMX_VFL] = &ssc_mx_rwsm0_vfl,
};

static const struct rpmpd_desc msm8998_desc = {
@@ -662,13 +662,13 @@ static const struct rpmpd_desc msm8998_desc = {

/* qcs404 RPM Power domains */
static struct rpmpd *qcs404_rpmpds[] = {
- [QCS404_VDDMX] = &mx_rwmx0_lvl,
- [QCS404_VDDMX_AO] = &mx_rwmx0_lvl_ao,
- [QCS404_VDDMX_VFL] = &mx_rwmx0_vfl,
- [QCS404_LPICX] = &lpi_cx_rwlc0_lvl,
- [QCS404_LPICX_VFL] = &lpi_cx_rwlc0_vfl,
- [QCS404_LPIMX] = &lpi_mx_rwlm0_lvl,
- [QCS404_LPIMX_VFL] = &lpi_mx_rwlm0_vfl,
+ [QCS404_VDDMX] = &mx_rwmx0_lvl,
+ [QCS404_VDDMX_AO] = &mx_rwmx0_lvl_ao,
+ [QCS404_VDDMX_VFL] = &mx_rwmx0_vfl,
+ [QCS404_LPICX] = &lpi_cx_rwlc0_lvl,
+ [QCS404_LPICX_VFL] = &lpi_cx_rwlc0_vfl,
+ [QCS404_LPIMX] = &lpi_mx_rwlm0_lvl,
+ [QCS404_LPIMX_VFL] = &lpi_mx_rwlm0_vfl,
};

static const struct rpmpd_desc qcs404_desc = {
@@ -679,16 +679,16 @@ static const struct rpmpd_desc qcs404_desc = {

/* sdm660 RPM Power domains */
static struct rpmpd *sdm660_rpmpds[] = {
- [SDM660_VDDCX] = &cx_rwcx0_lvl,
- [SDM660_VDDCX_AO] = &cx_rwcx0_lvl_ao,
- [SDM660_VDDCX_VFL] = &cx_rwcx0_vfl,
- [SDM660_VDDMX] = &mx_rwmx0_lvl,
- [SDM660_VDDMX_AO] = &mx_rwmx0_lvl_ao,
- [SDM660_VDDMX_VFL] = &mx_rwmx0_vfl,
- [SDM660_SSCCX] = &ssc_cx_rwlc0_lvl,
- [SDM660_SSCCX_VFL] = &ssc_cx_rwlc0_vfl,
- [SDM660_SSCMX] = &ssc_mx_rwlm0_lvl,
- [SDM660_SSCMX_VFL] = &ssc_mx_rwlm0_vfl,
+ [SDM660_VDDCX] = &cx_rwcx0_lvl,
+ [SDM660_VDDCX_AO] = &cx_rwcx0_lvl_ao,
+ [SDM660_VDDCX_VFL] = &cx_rwcx0_vfl,
+ [SDM660_VDDMX] = &mx_rwmx0_lvl,
+ [SDM660_VDDMX_AO] = &mx_rwmx0_lvl_ao,
+ [SDM660_VDDMX_VFL] = &mx_rwmx0_vfl,
+ [SDM660_SSCCX] = &ssc_cx_rwlc0_lvl,
+ [SDM660_SSCCX_VFL] = &ssc_cx_rwlc0_vfl,
+ [SDM660_SSCMX] = &ssc_mx_rwlm0_lvl,
+ [SDM660_SSCMX_VFL] = &ssc_mx_rwlm0_vfl,
};

static const struct rpmpd_desc sdm660_desc = {
@@ -699,14 +699,14 @@ static const struct rpmpd_desc sdm660_desc = {

/* sm4250/6115 RPM Power domains */
static struct rpmpd *sm6115_rpmpds[] = {
- [SM6115_VDDCX] = &cx_rwcx0_lvl,
- [SM6115_VDDCX_AO] = &cx_rwcx0_lvl_ao,
- [SM6115_VDDCX_VFL] = &cx_rwcx0_vfl,
- [SM6115_VDDMX] = &mx_rwmx0_lvl,
- [SM6115_VDDMX_AO] = &mx_rwmx0_lvl_ao,
- [SM6115_VDDMX_VFL] = &mx_rwmx0_vfl,
- [SM6115_VDD_LPI_CX] = &lpi_cx_rwlc0_lvl,
- [SM6115_VDD_LPI_MX] = &lpi_mx_rwlm0_lvl,
+ [SM6115_VDDCX] = &cx_rwcx0_lvl,
+ [SM6115_VDDCX_AO] = &cx_rwcx0_lvl_ao,
+ [SM6115_VDDCX_VFL] = &cx_rwcx0_vfl,
+ [SM6115_VDDMX] = &mx_rwmx0_lvl,
+ [SM6115_VDDMX_AO] = &mx_rwmx0_lvl_ao,
+ [SM6115_VDDMX_VFL] = &mx_rwmx0_vfl,
+ [SM6115_VDD_LPI_CX] = &lpi_cx_rwlc0_lvl,
+ [SM6115_VDD_LPI_MX] = &lpi_mx_rwlm0_lvl,
};

static const struct rpmpd_desc sm6115_desc = {
@@ -717,12 +717,12 @@ static const struct rpmpd_desc sm6115_desc = {

/* sm6125 RPM Power domains */
static struct rpmpd *sm6125_rpmpds[] = {
- [SM6125_VDDCX] = &cx_rwcx0_lvl,
- [SM6125_VDDCX_AO] = &cx_rwcx0_lvl_ao,
- [SM6125_VDDCX_VFL] = &cx_rwcx0_vfl,
- [SM6125_VDDMX] = &mx_rwmx0_lvl,
- [SM6125_VDDMX_AO] = &mx_rwmx0_lvl_ao,
- [SM6125_VDDMX_VFL] = &mx_rwmx0_vfl,
+ [SM6125_VDDCX] = &cx_rwcx0_lvl,
+ [SM6125_VDDCX_AO] = &cx_rwcx0_lvl_ao,
+ [SM6125_VDDCX_VFL] = &cx_rwcx0_vfl,
+ [SM6125_VDDMX] = &mx_rwmx0_lvl,
+ [SM6125_VDDMX_AO] = &mx_rwmx0_lvl_ao,
+ [SM6125_VDDMX_VFL] = &mx_rwmx0_vfl,
};

static const struct rpmpd_desc sm6125_desc = {
@@ -732,16 +732,16 @@ static const struct rpmpd_desc sm6125_desc = {
};

static struct rpmpd *sm6375_rpmpds[] = {
- [SM6375_VDDCX] = &cx_rwcx0_lvl,
- [SM6375_VDDCX_AO] = &cx_rwcx0_lvl_ao,
- [SM6375_VDDCX_VFL] = &cx_rwcx0_vfl,
- [SM6375_VDDMX] = &mx_rwmx0_lvl,
- [SM6375_VDDMX_AO] = &mx_rwmx0_lvl_ao,
- [SM6375_VDDMX_VFL] = &mx_rwmx0_vfl,
- [SM6375_VDDGX] = &gx_rwgx0_lvl,
- [SM6375_VDDGX_AO] = &gx_rwgx0_lvl_ao,
- [SM6375_VDD_LPI_CX] = &lpi_cx_rwlc0_lvl,
- [SM6375_VDD_LPI_MX] = &lpi_mx_rwlm0_lvl,
+ [SM6375_VDDCX] = &cx_rwcx0_lvl,
+ [SM6375_VDDCX_AO] = &cx_rwcx0_lvl_ao,
+ [SM6375_VDDCX_VFL] = &cx_rwcx0_vfl,
+ [SM6375_VDDMX] = &mx_rwmx0_lvl,
+ [SM6375_VDDMX_AO] = &mx_rwmx0_lvl_ao,
+ [SM6375_VDDMX_VFL] = &mx_rwmx0_vfl,
+ [SM6375_VDDGX] = &gx_rwgx0_lvl,
+ [SM6375_VDDGX_AO] = &gx_rwgx0_lvl_ao,
+ [SM6375_VDD_LPI_CX] = &lpi_cx_rwlc0_lvl,
+ [SM6375_VDD_LPI_MX] = &lpi_mx_rwlm0_lvl,
};

static const struct rpmpd_desc sm6375_desc = {
@@ -751,14 +751,14 @@ static const struct rpmpd_desc sm6375_desc = {
};

static struct rpmpd *qcm2290_rpmpds[] = {
- [QCM2290_VDDCX] = &cx_rwcx0_lvl,
- [QCM2290_VDDCX_AO] = &cx_rwcx0_lvl_ao,
- [QCM2290_VDDCX_VFL] = &cx_rwcx0_vfl,
- [QCM2290_VDDMX] = &mx_rwmx0_lvl,
- [QCM2290_VDDMX_AO] = &mx_rwmx0_lvl_ao,
- [QCM2290_VDDMX_VFL] = &mx_rwmx0_vfl,
- [QCM2290_VDD_LPI_CX] = &lpi_cx_rwlc0_lvl,
- [QCM2290_VDD_LPI_MX] = &lpi_mx_rwlm0_lvl,
+ [QCM2290_VDDCX] = &cx_rwcx0_lvl,
+ [QCM2290_VDDCX_AO] = &cx_rwcx0_lvl_ao,
+ [QCM2290_VDDCX_VFL] = &cx_rwcx0_vfl,
+ [QCM2290_VDDMX] = &mx_rwmx0_lvl,
+ [QCM2290_VDDMX_AO] = &mx_rwmx0_lvl_ao,
+ [QCM2290_VDDMX_VFL] = &mx_rwmx0_vfl,
+ [QCM2290_VDD_LPI_CX] = &lpi_cx_rwlc0_lvl,
+ [QCM2290_VDD_LPI_MX] = &lpi_mx_rwlm0_lvl,
};

static const struct rpmpd_desc qcm2290_desc = {

--
2.39.2


2023-03-13 20:00:45

by Konrad Dybcio

[permalink] [raw]
Subject: [PATCH v3 09/10] soc: qcom: rpmpd: Hook up VDDMX as parent of SM6375 VDDGX

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 <[email protected]>
Reviewed-by: Dmitry Baryshkov <[email protected]>
Signed-off-by: Konrad Dybcio <[email protected]>
---
drivers/soc/qcom/rpmpd.c | 4 ++++
1 file changed, 4 insertions(+)

diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c
index 2027c820caa7..84283719853c 100644
--- a/drivers/soc/qcom/rpmpd.c
+++ b/drivers/soc/qcom/rpmpd.c
@@ -216,18 +216,22 @@ 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,
};

+static struct rpmpd mx_rwmx0_lvl_ao;
static struct rpmpd gx_rwgx0_lvl_ao = {
.pd = { .name = "gx_ao", },
.peer = &gx_rwgx0_lvl,
+ .parent = &mx_rwmx0_lvl_ao.pd,
.active_only = true,
.res_type = RPMPD_RWGX,
.res_id = 0,

--
2.39.2


2023-03-13 20:00:50

by Konrad Dybcio

[permalink] [raw]
Subject: [PATCH v3 06/10] soc: qcom: rpmpd: Improve the naming

Now that we aren't bound by the preprocessor macros, improve the naming
to be a bit less preprocessor-y and touch up some rpmpd.pd.name fields
while at it.

Signed-off-by: Konrad Dybcio <[email protected]>
---
drivers/soc/qcom/rpmpd.c | 432 +++++++++++++++++++++++------------------------
1 file changed, 216 insertions(+), 216 deletions(-)

diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c
index df4e0d8a2aa9..695b2fc56f40 100644
--- a/drivers/soc/qcom/rpmpd.c
+++ b/drivers/soc/qcom/rpmpd.c
@@ -68,132 +68,132 @@ struct rpmpd_desc {
static DEFINE_MUTEX(rpmpd_lock);

/* CX */
-static struct rpmpd RWCX0_LEVEL_cx_ao;
-static struct rpmpd RWCX0_LEVEL_cx = {
+static struct rpmpd cx_rwcx0_lvl_ao;
+static struct rpmpd cx_rwcx0_lvl = {
.pd = { .name = "cx", },
- .peer = &RWCX0_LEVEL_cx_ao,
+ .peer = &cx_rwcx0_lvl_ao,
.res_type = RPMPD_RWCX,
.res_id = 0,
.key = KEY_LEVEL,
};

-static struct rpmpd RWCX0_LEVEL_cx_ao = {
+static struct rpmpd cx_rwcx0_lvl_ao = {
.pd = { .name = "cx_ao", },
- .peer = &RWCX0_LEVEL_cx,
+ .peer = &cx_rwcx0_lvl,
.active_only = true,
.res_type = RPMPD_RWCX,
.res_id = 0,
.key = KEY_LEVEL,
};

-static struct rpmpd SMPA1_CORNER_cx_ao;
-static struct rpmpd SMPA1_CORNER_cx = {
+static struct rpmpd cx_s1a_corner_ao;
+static struct rpmpd cx_s1a_corner = {
.pd = { .name = "cx", },
- .peer = &SMPA1_CORNER_cx_ao,
+ .peer = &cx_s1a_corner_ao,
.res_type = RPMPD_SMPA,
.res_id = 1,
.key = KEY_CORNER,
};

-static struct rpmpd SMPA1_CORNER_cx_ao = {
+static struct rpmpd cx_s1a_corner_ao = {
.pd = { .name = "cx_ao", },
- .peer = &SMPA1_CORNER_cx,
+ .peer = &cx_s1a_corner,
.active_only = true,
.res_type = RPMPD_SMPA,
.res_id = 1,
.key = KEY_CORNER,
};

-static struct rpmpd SMPA2_CORNER_cx_ao;
-static struct rpmpd SMPA2_CORNER_cx = {
+static struct rpmpd cx_s2a_corner_ao;
+static struct rpmpd cx_s2a_corner = {
.pd = { .name = "cx", },
- .peer = &SMPA2_CORNER_cx_ao,
+ .peer = &cx_s2a_corner_ao,
.res_type = RPMPD_SMPA,
.res_id = 2,
.key = KEY_CORNER,
};

-static struct rpmpd SMPA2_CORNER_cx_ao = {
+static struct rpmpd cx_s2a_corner_ao = {
.pd = { .name = "cx_ao", },
- .peer = &SMPA2_CORNER_cx,
+ .peer = &cx_s2a_corner,
.active_only = true,
.res_type = RPMPD_SMPA,
.res_id = 2,
.key = KEY_CORNER,
};

-static struct rpmpd SMPA2_LEVEL_cx_ao;
-static struct rpmpd SMPA2_LEVEL_cx = {
+static struct rpmpd cx_s2a_lvl_ao;
+static struct rpmpd cx_s2a_lvl = {
.pd = { .name = "cx", },
- .peer = &SMPA2_LEVEL_cx_ao,
+ .peer = &cx_s2a_lvl_ao,
.res_type = RPMPD_SMPA,
.res_id = 2,
.key = KEY_LEVEL,
};

-static struct rpmpd SMPA2_LEVEL_cx_ao = {
+static struct rpmpd cx_s2a_lvl_ao = {
.pd = { .name = "cx_ao", },
- .peer = &SMPA2_LEVEL_cx,
+ .peer = &cx_s2a_lvl,
.active_only = true,
.res_type = RPMPD_SMPA,
.res_id = 2,
.key = KEY_LEVEL,
};

-static struct rpmpd SMPA3_LEVEL_cx_ao;
-static struct rpmpd SMPA3_LEVEL_cx = {
+static struct rpmpd cx_s3a_lvl_ao;
+static struct rpmpd cx_s3a_lvl = {
.pd = { .name = "cx", },
- .peer = &SMPA3_LEVEL_cx_ao,
+ .peer = &cx_s3a_lvl_ao,
.res_type = RPMPD_SMPA,
.res_id = 3,
.key = KEY_LEVEL,
};

-static struct rpmpd SMPA3_LEVEL_cx_ao = {
+static struct rpmpd cx_s3a_lvl_ao = {
.pd = { .name = "cx_ao", },
- .peer = &SMPA3_LEVEL_cx,
+ .peer = &cx_s3a_lvl,
.active_only = true,
.res_type = RPMPD_SMPA,
.res_id = 3,
.key = KEY_LEVEL,
};

-static struct rpmpd RWCX0_cx_vfl = {
+static struct rpmpd cx_rwcx0_vfl = {
.pd = { .name = "cx_vfl", },
.res_type = RPMPD_RWCX,
.res_id = 0,
.key = KEY_FLOOR_LEVEL,
};

-static struct rpmpd RWSC2_cx_vfl = {
+static struct rpmpd cx_rwsc2_vfl = {
.pd = { .name = "cx_vfl", },
.res_type = RPMPD_RWSC,
.res_id = 2,
.key = KEY_FLOOR_LEVEL,
};

-static struct rpmpd SMPA1_cx_vfc = {
+static struct rpmpd cx_s1a_vfc = {
.pd = { .name = "cx_vfc", },
.res_type = RPMPD_SMPA,
.res_id = 1,
.key = KEY_FLOOR_CORNER,
};

-static struct rpmpd SMPA2_cx_vfc = {
+static struct rpmpd cx_s2a_vfc = {
.pd = { .name = "cx_vfc", },
.res_type = RPMPD_SMPA,
.res_id = 2,
.key = KEY_FLOOR_CORNER,
};

-static struct rpmpd SMPA2_cx_vfl = {
+static struct rpmpd cx_s2a_vfl = {
.pd = { .name = "cx_vfl", },
.res_type = RPMPD_SMPA,
.res_id = 2,
.key = KEY_FLOOR_LEVEL,
};

-static struct rpmpd SMPA3_cx_vfl = {
+static struct rpmpd cx_s3a_vfl = {
.pd = { .name = "cx_vfl", },
.res_type = RPMPD_SMPA,
.res_id = 3,
@@ -201,32 +201,32 @@ static struct rpmpd SMPA3_cx_vfl = {
};

/* G(F)X */
-static struct rpmpd SMPB2_gfx_corner = {
+static struct rpmpd gfx_s2b_corner = {
.pd = { .name = "gfx", },
.res_type = RPMPD_SMPB,
.res_id = 2,
.key = KEY_CORNER,
};

-static struct rpmpd SMPB2_gfx_vfc = {
+static struct rpmpd gfx_s2b_vfc = {
.pd = { .name = "gfx_vfc", },
.res_type = RPMPD_SMPB,
.res_id = 2,
.key = KEY_FLOOR_CORNER,
};

-static struct rpmpd RWGX0_LEVEL_gx_ao;
-static struct rpmpd RWGX0_LEVEL_gx = {
+static struct rpmpd gx_rwgx0_lvl_ao;
+static struct rpmpd gx_rwgx0_lvl = {
.pd = { .name = "gx", },
- .peer = &RWGX0_LEVEL_gx_ao,
+ .peer = &gx_rwgx0_lvl_ao,
.res_type = RPMPD_RWGX,
.res_id = 0,
.key = KEY_LEVEL,
};

-static struct rpmpd RWGX0_LEVEL_gx_ao = {
+static struct rpmpd gx_rwgx0_lvl_ao = {
.pd = { .name = "gx_ao", },
- .peer = &RWGX0_LEVEL_gx,
+ .peer = &gx_rwgx0_lvl,
.active_only = true,
.res_type = RPMPD_RWGX,
.res_id = 0,
@@ -234,129 +234,129 @@ static struct rpmpd RWGX0_LEVEL_gx_ao = {
};

/* MX */
-static struct rpmpd LDOA3_CORNER_mx_ao;
-static struct rpmpd LDOA3_CORNER_mx = {
+static struct rpmpd mx_l3a_corner_ao;
+static struct rpmpd mx_l3a_corner = {
.pd = { .name = "mx", },
- .peer = &LDOA3_CORNER_mx_ao,
+ .peer = &mx_l3a_corner_ao,
.res_type = RPMPD_LDOA,
.res_id = 3,
.key = KEY_CORNER,
};

-static struct rpmpd LDOA3_CORNER_mx_ao = {
+static struct rpmpd mx_l3a_corner_ao = {
.pd = { .name = "mx_ao", },
- .peer = &LDOA3_CORNER_mx,
+ .peer = &mx_l3a_corner,
.active_only = true,
.res_type = RPMPD_LDOA,
.res_id = 3,
.key = KEY_CORNER,
};

-static struct rpmpd LDOA12_LEVEL_mx_ao;
-static struct rpmpd LDOA12_LEVEL_mx = {
+static struct rpmpd mx_l12a_lvl_ao;
+static struct rpmpd mx_l12a_lvl = {
.pd = { .name = "mx", },
- .peer = &LDOA12_LEVEL_mx_ao,
+ .peer = &mx_l12a_lvl_ao,
.res_type = RPMPD_LDOA,
.res_id = 12,
.key = KEY_LEVEL,
};

-static struct rpmpd LDOA12_LEVEL_mx_ao = {
+static struct rpmpd mx_l12a_lvl_ao = {
.pd = { .name = "mx_ao", },
- .peer = &LDOA12_LEVEL_mx,
+ .peer = &mx_l12a_lvl,
.active_only = true,
.res_type = RPMPD_LDOA,
.res_id = 12,
.key = KEY_LEVEL,
};

-static struct rpmpd SMPA2_CORNER_mx_ao;
-static struct rpmpd SMPA2_CORNER_mx = {
+static struct rpmpd mx_s2a_corner_ao;
+static struct rpmpd mx_s2a_corner = {
.pd = { .name = "mx", },
- .peer = &SMPA2_CORNER_mx_ao,
+ .peer = &mx_s2a_corner_ao,
.res_type = RPMPD_SMPA,
.res_id = 2,
.key = KEY_CORNER,
};

-static struct rpmpd SMPA2_CORNER_mx_ao = {
+static struct rpmpd mx_s2a_corner_ao = {
.pd = { .name = "mx_ao", },
- .peer = &SMPA2_CORNER_mx,
+ .peer = &mx_s2a_corner,
.active_only = true,
.res_type = RPMPD_SMPA,
.res_id = 2,
.key = KEY_CORNER,
};

-static struct rpmpd RWMX0_LEVEL_mx_ao;
-static struct rpmpd RWMX0_LEVEL_mx = {
+static struct rpmpd mx_rwmx0_lvl_ao;
+static struct rpmpd mx_rwmx0_lvl = {
.pd = { .name = "mx", },
- .peer = &RWMX0_LEVEL_mx_ao,
+ .peer = &mx_rwmx0_lvl_ao,
.res_type = RPMPD_RWMX,
.res_id = 0,
.key = KEY_LEVEL,
};

-static struct rpmpd RWMX0_LEVEL_mx_ao = {
+static struct rpmpd mx_rwmx0_lvl_ao = {
.pd = { .name = "mx_ao", },
- .peer = &RWMX0_LEVEL_mx,
+ .peer = &mx_rwmx0_lvl,
.active_only = true,
.res_type = RPMPD_RWMX,
.res_id = 0,
.key = KEY_LEVEL,
};

-static struct rpmpd SMPA6_LEVEL_mx_ao;
-static struct rpmpd SMPA6_LEVEL_mx = {
+static struct rpmpd mx_s6a_lvl_ao;
+static struct rpmpd mx_s6a_lvl = {
.pd = { .name = "mx", },
- .peer = &SMPA6_LEVEL_mx_ao,
+ .peer = &mx_s6a_lvl_ao,
.res_type = RPMPD_SMPA,
.res_id = 6,
.key = KEY_LEVEL,
};

-static struct rpmpd SMPA6_LEVEL_mx_ao = {
+static struct rpmpd mx_s6a_lvl_ao = {
.pd = { .name = "mx_ao", },
- .peer = &SMPA6_LEVEL_mx,
+ .peer = &mx_s6a_lvl,
.active_only = true,
.res_type = RPMPD_SMPA,
.res_id = 6,
.key = KEY_LEVEL,
};

-static struct rpmpd SMPA7_LEVEL_mx_ao;
-static struct rpmpd SMPA7_LEVEL_mx = {
+static struct rpmpd mx_s7a_lvl_ao;
+static struct rpmpd mx_s7a_lvl = {
.pd = { .name = "mx", },
- .peer = &SMPA7_LEVEL_mx_ao,
+ .peer = &mx_s7a_lvl_ao,
.res_type = RPMPD_SMPA,
.res_id = 7,
.key = KEY_LEVEL,
};

-static struct rpmpd SMPA7_LEVEL_mx_ao = {
+static struct rpmpd mx_s7a_lvl_ao = {
.pd = { .name = "mx_ao", },
- .peer = &SMPA7_LEVEL_mx,
+ .peer = &mx_s7a_lvl,
.active_only = true,
.res_type = RPMPD_SMPA,
.res_id = 7,
.key = KEY_LEVEL,
};

-static struct rpmpd LDOA12_mx_vfl = {
+static struct rpmpd mx_l12a_vfl = {
.pd = { .name = "mx_vfl", },
.res_type = RPMPD_LDOA,
.res_id = 12,
.key = KEY_FLOOR_LEVEL,
};

-static struct rpmpd RWMX0_mx_vfl = {
+static struct rpmpd mx_rwmx0_vfl = {
.pd = { .name = "mx_vfl", },
.res_type = RPMPD_RWMX,
.res_id = 0,
.key = KEY_FLOOR_LEVEL,
};

-static struct rpmpd RWSM6_mx_vfl = {
+static struct rpmpd mx_rwsm6_vfl = {
.pd = { .name = "mx_vfl", },
.res_type = RPMPD_RWSM,
.res_id = 6,
@@ -364,43 +364,43 @@ static struct rpmpd RWSM6_mx_vfl = {
};

/* MD */
-static struct rpmpd SMPA1_CORNER_md_ao;
-static struct rpmpd SMPA1_CORNER_md = {
+static struct rpmpd md_s1a_corner_ao;
+static struct rpmpd md_s1a_corner = {
.pd = { .name = "md", },
- .peer = &SMPA1_CORNER_md_ao,
+ .peer = &md_s1a_corner_ao,
.res_type = RPMPD_SMPA,
.res_id = 1,
.key = KEY_CORNER,
};

-static struct rpmpd SMPA1_CORNER_md_ao = {
+static struct rpmpd md_s1a_corner_ao = {
.pd = { .name = "md_ao", },
- .peer = &SMPA1_CORNER_md,
+ .peer = &md_s1a_corner,
.active_only = true,
.res_type = RPMPD_SMPA,
.res_id = 1,
.key = KEY_CORNER,
};

-static struct rpmpd SMPA1_LEVEL_md_ao;
-static struct rpmpd SMPA1_LEVEL_md = {
+static struct rpmpd md_s1a_lvl_ao;
+static struct rpmpd md_s1a_lvl = {
.pd = { .name = "md", },
- .peer = &SMPA1_LEVEL_md_ao,
+ .peer = &md_s1a_lvl_ao,
.res_type = RPMPD_SMPA,
.res_id = 1,
.key = KEY_LEVEL,
};

-static struct rpmpd SMPA1_LEVEL_md_ao = {
+static struct rpmpd md_s1a_lvl_ao = {
.pd = { .name = "md_ao", },
- .peer = &SMPA1_LEVEL_md,
+ .peer = &md_s1a_lvl,
.active_only = true,
.res_type = RPMPD_SMPA,
.res_id = 1,
.key = KEY_LEVEL,
};

-static struct rpmpd SMPA1_md_vfc = {
+static struct rpmpd md_s1a_vfc = {
.pd = { .name = "md_vfc", },
.res_type = RPMPD_SMPA,
.res_id = 1,
@@ -408,102 +408,102 @@ static struct rpmpd SMPA1_md_vfc = {
};

/* LPI_CX */
-static struct rpmpd RWLC0_lpi_cx_lvl = {
+static struct rpmpd lpi_cx_rwlc0_lvl = {
.pd = { .name = "lpi_cx", },
.res_type = RPMPD_RWLC,
.res_id = 0,
.key = KEY_LEVEL,
};

-static struct rpmpd RWLC0_lpicx_vfl = {
- .pd = { .name = "lpicx_vfl", },
+static struct rpmpd lpi_cx_rwlc0_vfl = {
+ .pd = { .name = "lpi_cx_vfl", },
.res_type = RPMPD_RWLC,
.res_id = 0,
.key = KEY_FLOOR_LEVEL,
};

/* LPI_MX */
-static struct rpmpd RWLM0_lpi_mx_lvl = {
+static struct rpmpd lpi_mx_rwlm0_lvl = {
.pd = { .name = "lpi_mx", },
.res_type = RPMPD_RWLM,
.res_id = 0,
.key = KEY_LEVEL,
};

-static struct rpmpd RWLM0_lpimx_vfl = {
- .pd = { .name = "lpimx_vfl", },
+static struct rpmpd lpi_mx_rwlm0_vfl = {
+ .pd = { .name = "lpi_mx_vfl", },
.res_type = RPMPD_RWLM,
.res_id = 0,
.key = KEY_FLOOR_LEVEL,
};

/* SSC_CX */
-static struct rpmpd LDOA26_sscx_corner = {
- .pd = { .name = "sscx", },
+static struct rpmpd ssc_cx_l26a_corner = {
+ .pd = { .name = "ssc_cx", },
.res_type = RPMPD_LDOA,
.res_id = 26,
.key = KEY_CORNER,
};

-static struct rpmpd RWLC0_ssccx_lvl = {
- .pd = { .name = "ssccx", },
+static struct rpmpd ssc_cx_rwlc0_lvl = {
+ .pd = { .name = "ssc_cx", },
.res_type = RPMPD_RWLC,
.res_id = 0,
.key = KEY_LEVEL,
};

-static struct rpmpd RWSC0_ssccx_lvl = {
- .pd = { .name = "ssccx", },
+static struct rpmpd ssc_cx_rwsc0_lvl = {
+ .pd = { .name = "ssc_cx", },
.res_type = RPMPD_RWSC,
.res_id = 0,
.key = KEY_LEVEL,
};

-static struct rpmpd LDOA26_sscx_vfc = {
- .pd = { .name = "sscx_vfc", },
+static struct rpmpd ssc_cx_l26a_vfc = {
+ .pd = { .name = "ssc_cx_vfc", },
.res_type = RPMPD_LDOA,
.res_id = 26,
.key = KEY_FLOOR_CORNER,
};

-static struct rpmpd RWLC0_ssccx_vfl = {
- .pd = { .name = "ssccx_vfl", },
+static struct rpmpd ssc_cx_rwlc0_vfl = {
+ .pd = { .name = "ssc_cx_vfl", },
.res_type = RPMPD_RWLC,
.res_id = 0,
.key = KEY_FLOOR_LEVEL,
};

-static struct rpmpd RWSC0_ssccx_vfl = {
- .pd = { .name = "ssccx_vfl", },
+static struct rpmpd ssc_cx_rwsc0_vfl = {
+ .pd = { .name = "ssc_cx_vfl", },
.res_type = RPMPD_RWSC,
.res_id = 0,
.key = KEY_FLOOR_LEVEL,
};

/* SSC_MX */
-static struct rpmpd RWLM0_sscmx_lvl = {
- .pd = { .name = "sscmx", },
+static struct rpmpd ssc_mx_rwlm0_lvl = {
+ .pd = { .name = "ssc_mx", },
.res_type = RPMPD_RWLM,
.res_id = 0,
.key = KEY_LEVEL,
};

-static struct rpmpd RWSM0_sscmx_lvl = {
- .pd = { .name = "sscmx", },
+static struct rpmpd ssc_mx_rwsm0_lvl = {
+ .pd = { .name = "ssc_mx", },
.res_type = RPMPD_RWSM,
.res_id = 0,
.key = KEY_LEVEL,
};

-static struct rpmpd RWLM0_sscmx_vfl = {
- .pd = { .name = "sscmx_vfl", },
+static struct rpmpd ssc_mx_rwlm0_vfl = {
+ .pd = { .name = "ssc_mx_vfl", },
.res_type = RPMPD_RWLM,
.res_id = 0,
.key = KEY_FLOOR_LEVEL,
};

-static struct rpmpd RWSM0_sscmx_vfl = {
- .pd = { .name = "sscmx_vfl", },
+static struct rpmpd ssc_mx_rwsm0_vfl = {
+ .pd = { .name = "ssc_mx_vfl", },
.res_type = RPMPD_RWSM,
.res_id = 0,
.key = KEY_FLOOR_LEVEL,
@@ -511,12 +511,12 @@ static struct rpmpd RWSM0_sscmx_vfl = {

/* mdm9607 RPM Power Domains */
static struct rpmpd *mdm9607_rpmpds[] = {
- [MDM9607_VDDCX] = &SMPA3_LEVEL_cx,
- [MDM9607_VDDCX_AO] = &SMPA3_LEVEL_cx_ao,
- [MDM9607_VDDCX_VFL] = &SMPA3_cx_vfl,
- [MDM9607_VDDMX] = &LDOA12_LEVEL_mx,
- [MDM9607_VDDMX_AO] = &LDOA12_LEVEL_mx_ao,
- [MDM9607_VDDMX_VFL] = &LDOA12_mx_vfl,
+ [MDM9607_VDDCX] = &cx_s3a_lvl,
+ [MDM9607_VDDCX_AO] = &cx_s3a_lvl_ao,
+ [MDM9607_VDDCX_VFL] = &cx_s3a_vfl,
+ [MDM9607_VDDMX] = &mx_l12a_lvl,
+ [MDM9607_VDDMX_AO] = &mx_l12a_lvl_ao,
+ [MDM9607_VDDMX_VFL] = &mx_l12a_vfl,
};

static const struct rpmpd_desc mdm9607_desc = {
@@ -527,9 +527,9 @@ static const struct rpmpd_desc mdm9607_desc = {

/* msm8226 RPM Power Domains */
static struct rpmpd *msm8226_rpmpds[] = {
- [MSM8226_VDDCX] = &SMPA1_CORNER_cx,
- [MSM8226_VDDCX_AO] = &SMPA1_CORNER_cx_ao,
- [MSM8226_VDDCX_VFC] = &SMPA1_cx_vfc,
+ [MSM8226_VDDCX] = &cx_s1a_corner,
+ [MSM8226_VDDCX_AO] = &cx_s1a_corner_ao,
+ [MSM8226_VDDCX_VFC] = &cx_s1a_vfc,
};

static const struct rpmpd_desc msm8226_desc = {
@@ -540,14 +540,14 @@ static const struct rpmpd_desc msm8226_desc = {

/* msm8939 RPM Power Domains */
static struct rpmpd *msm8939_rpmpds[] = {
- [MSM8939_VDDMDCX] = &SMPA1_CORNER_md,
- [MSM8939_VDDMDCX_AO] = &SMPA1_CORNER_md_ao,
- [MSM8939_VDDMDCX_VFC] = &SMPA1_md_vfc,
- [MSM8939_VDDCX] = &SMPA2_CORNER_cx,
- [MSM8939_VDDCX_AO] = &SMPA2_CORNER_cx_ao,
- [MSM8939_VDDCX_VFC] = &SMPA2_cx_vfc,
- [MSM8939_VDDMX] = &LDOA3_CORNER_mx,
- [MSM8939_VDDMX_AO] = &LDOA3_CORNER_mx_ao,
+ [MSM8939_VDDMDCX] = &md_s1a_corner,
+ [MSM8939_VDDMDCX_AO] = &md_s1a_corner_ao,
+ [MSM8939_VDDMDCX_VFC] = &md_s1a_vfc,
+ [MSM8939_VDDCX] = &cx_s2a_corner,
+ [MSM8939_VDDCX_AO] = &cx_s2a_corner_ao,
+ [MSM8939_VDDCX_VFC] = &cx_s2a_vfc,
+ [MSM8939_VDDMX] = &mx_l3a_corner,
+ [MSM8939_VDDMX_AO] = &mx_l3a_corner_ao,
};

static const struct rpmpd_desc msm8939_desc = {
@@ -558,11 +558,11 @@ static const struct rpmpd_desc msm8939_desc = {

/* msm8916 RPM Power Domains */
static struct rpmpd *msm8916_rpmpds[] = {
- [MSM8916_VDDCX] = &SMPA1_CORNER_cx,
- [MSM8916_VDDCX_AO] = &SMPA1_CORNER_cx_ao,
- [MSM8916_VDDCX_VFC] = &SMPA1_cx_vfc,
- [MSM8916_VDDMX] = &LDOA3_CORNER_mx,
- [MSM8916_VDDMX_AO] = &LDOA3_CORNER_mx_ao,
+ [MSM8916_VDDCX] = &cx_s1a_corner,
+ [MSM8916_VDDCX_AO] = &cx_s1a_corner_ao,
+ [MSM8916_VDDCX_VFC] = &cx_s1a_vfc,
+ [MSM8916_VDDMX] = &mx_l3a_corner,
+ [MSM8916_VDDMX_AO] = &mx_l3a_corner_ao,
};

static const struct rpmpd_desc msm8916_desc = {
@@ -573,13 +573,13 @@ static const struct rpmpd_desc msm8916_desc = {

/* msm8953 RPM Power Domains */
static struct rpmpd *msm8953_rpmpds[] = {
- [MSM8953_VDDMD] = &SMPA1_LEVEL_md,
- [MSM8953_VDDMD_AO] = &SMPA1_LEVEL_md_ao,
- [MSM8953_VDDCX] = &SMPA2_LEVEL_cx,
- [MSM8953_VDDCX_AO] = &SMPA2_LEVEL_cx_ao,
- [MSM8953_VDDCX_VFL] = &SMPA2_cx_vfl,
- [MSM8953_VDDMX] = &SMPA7_LEVEL_mx,
- [MSM8953_VDDMX_AO] = &SMPA7_LEVEL_mx_ao,
+ [MSM8953_VDDMD] = &md_s1a_lvl,
+ [MSM8953_VDDMD_AO] = &md_s1a_lvl_ao,
+ [MSM8953_VDDCX] = &cx_s2a_lvl,
+ [MSM8953_VDDCX_AO] = &cx_s2a_lvl_ao,
+ [MSM8953_VDDCX_VFL] = &cx_s2a_vfl,
+ [MSM8953_VDDMX] = &mx_s7a_lvl,
+ [MSM8953_VDDMX_AO] = &mx_s7a_lvl_ao,
};

static const struct rpmpd_desc msm8953_desc = {
@@ -590,12 +590,12 @@ static const struct rpmpd_desc msm8953_desc = {

/* msm8976 RPM Power Domains */
static struct rpmpd *msm8976_rpmpds[] = {
- [MSM8976_VDDCX] = &SMPA2_LEVEL_cx,
- [MSM8976_VDDCX_AO] = &SMPA2_LEVEL_cx_ao,
- [MSM8976_VDDCX_VFL] = &RWSC2_cx_vfl,
- [MSM8976_VDDMX] = &SMPA6_LEVEL_mx,
- [MSM8976_VDDMX_AO] = &SMPA6_LEVEL_mx_ao,
- [MSM8976_VDDMX_VFL] = &RWSM6_mx_vfl,
+ [MSM8976_VDDCX] = &cx_s2a_lvl,
+ [MSM8976_VDDCX_AO] = &cx_s2a_lvl_ao,
+ [MSM8976_VDDCX_VFL] = &cx_rwsc2_vfl,
+ [MSM8976_VDDMX] = &mx_s6a_lvl,
+ [MSM8976_VDDMX_AO] = &mx_s6a_lvl_ao,
+ [MSM8976_VDDMX_VFL] = &mx_rwsm6_vfl,
};

static const struct rpmpd_desc msm8976_desc = {
@@ -606,15 +606,15 @@ static const struct rpmpd_desc msm8976_desc = {

/* msm8994 RPM Power domains */
static struct rpmpd *msm8994_rpmpds[] = {
- [MSM8994_VDDCX] = &SMPA1_CORNER_cx,
- [MSM8994_VDDCX_AO] = &SMPA1_CORNER_cx_ao,
- [MSM8994_VDDCX_VFC] = &SMPA1_cx_vfc,
- [MSM8994_VDDMX] = &SMPA2_CORNER_mx,
- [MSM8994_VDDMX_AO] = &SMPA2_CORNER_mx_ao,
+ [MSM8994_VDDCX] = &cx_s1a_corner,
+ [MSM8994_VDDCX_AO] = &cx_s1a_corner_ao,
+ [MSM8994_VDDCX_VFC] = &cx_s1a_vfc,
+ [MSM8994_VDDMX] = &mx_s2a_corner,
+ [MSM8994_VDDMX_AO] = &mx_s2a_corner_ao,

/* Attention! *Some* 8994 boards with pm8004 may use SMPC here! */
- [MSM8994_VDDGFX] = &SMPB2_gfx_corner,
- [MSM8994_VDDGFX_VFC] = &SMPB2_gfx_vfc,
+ [MSM8994_VDDGFX] = &gfx_s2b_corner,
+ [MSM8994_VDDGFX_VFC] = &gfx_s2b_vfc,
};

static const struct rpmpd_desc msm8994_desc = {
@@ -625,13 +625,13 @@ static const struct rpmpd_desc msm8994_desc = {

/* msm8996 RPM Power domains */
static struct rpmpd *msm8996_rpmpds[] = {
- [MSM8996_VDDCX] = &SMPA1_CORNER_cx,
- [MSM8996_VDDCX_AO] = &SMPA1_CORNER_cx_ao,
- [MSM8996_VDDCX_VFC] = &SMPA1_cx_vfc,
- [MSM8996_VDDMX] = &SMPA2_CORNER_mx,
- [MSM8996_VDDMX_AO] = &SMPA2_CORNER_mx_ao,
- [MSM8996_VDDSSCX] = &LDOA26_sscx_corner,
- [MSM8996_VDDSSCX_VFC] = &LDOA26_sscx_vfc,
+ [MSM8996_VDDCX] = &cx_s1a_corner,
+ [MSM8996_VDDCX_AO] = &cx_s1a_corner_ao,
+ [MSM8996_VDDCX_VFC] = &cx_s1a_vfc,
+ [MSM8996_VDDMX] = &mx_s2a_corner,
+ [MSM8996_VDDMX_AO] = &mx_s2a_corner_ao,
+ [MSM8996_VDDSSCX] = &ssc_cx_l26a_corner,
+ [MSM8996_VDDSSCX_VFC] = &ssc_cx_l26a_vfc,
};

static const struct rpmpd_desc msm8996_desc = {
@@ -642,16 +642,16 @@ static const struct rpmpd_desc msm8996_desc = {

/* msm8998 RPM Power domains */
static struct rpmpd *msm8998_rpmpds[] = {
- [MSM8998_VDDCX] = &RWCX0_LEVEL_cx,
- [MSM8998_VDDCX_AO] = &RWCX0_LEVEL_cx_ao,
- [MSM8998_VDDCX_VFL] = &RWCX0_cx_vfl,
- [MSM8998_VDDMX] = &RWMX0_LEVEL_mx,
- [MSM8998_VDDMX_AO] = &RWMX0_LEVEL_mx_ao,
- [MSM8998_VDDMX_VFL] = &RWMX0_mx_vfl,
- [MSM8998_SSCCX] = &RWSC0_ssccx_lvl,
- [MSM8998_SSCCX_VFL] = &RWSC0_ssccx_vfl,
- [MSM8998_SSCMX] = &RWSM0_sscmx_lvl,
- [MSM8998_SSCMX_VFL] = &RWSM0_sscmx_vfl,
+ [MSM8998_VDDCX] = &cx_rwcx0_lvl,
+ [MSM8998_VDDCX_AO] = &cx_rwcx0_lvl_ao,
+ [MSM8998_VDDCX_VFL] = &cx_rwcx0_vfl,
+ [MSM8998_VDDMX] = &mx_rwmx0_lvl,
+ [MSM8998_VDDMX_AO] = &mx_rwmx0_lvl_ao,
+ [MSM8998_VDDMX_VFL] = &mx_rwmx0_vfl,
+ [MSM8998_SSCCX] = &ssc_cx_rwsc0_lvl,
+ [MSM8998_SSCCX_VFL] = &ssc_cx_rwsc0_vfl,
+ [MSM8998_SSCMX] = &ssc_mx_rwsm0_lvl,
+ [MSM8998_SSCMX_VFL] = &ssc_mx_rwsm0_vfl,
};

static const struct rpmpd_desc msm8998_desc = {
@@ -662,13 +662,13 @@ static const struct rpmpd_desc msm8998_desc = {

/* qcs404 RPM Power domains */
static struct rpmpd *qcs404_rpmpds[] = {
- [QCS404_VDDMX] = &RWMX0_LEVEL_mx,
- [QCS404_VDDMX_AO] = &RWMX0_LEVEL_mx_ao,
- [QCS404_VDDMX_VFL] = &RWMX0_mx_vfl,
- [QCS404_LPICX] = &RWLC0_lpi_cx_lvl,
- [QCS404_LPICX_VFL] = &RWLC0_lpicx_vfl,
- [QCS404_LPIMX] = &RWLM0_lpi_mx_lvl,
- [QCS404_LPIMX_VFL] = &RWLM0_lpimx_vfl,
+ [QCS404_VDDMX] = &mx_rwmx0_lvl,
+ [QCS404_VDDMX_AO] = &mx_rwmx0_lvl_ao,
+ [QCS404_VDDMX_VFL] = &mx_rwmx0_vfl,
+ [QCS404_LPICX] = &lpi_cx_rwlc0_lvl,
+ [QCS404_LPICX_VFL] = &lpi_cx_rwlc0_vfl,
+ [QCS404_LPIMX] = &lpi_mx_rwlm0_lvl,
+ [QCS404_LPIMX_VFL] = &lpi_mx_rwlm0_vfl,
};

static const struct rpmpd_desc qcs404_desc = {
@@ -679,16 +679,16 @@ static const struct rpmpd_desc qcs404_desc = {

/* sdm660 RPM Power domains */
static struct rpmpd *sdm660_rpmpds[] = {
- [SDM660_VDDCX] = &RWCX0_LEVEL_cx,
- [SDM660_VDDCX_AO] = &RWCX0_LEVEL_cx_ao,
- [SDM660_VDDCX_VFL] = &RWCX0_cx_vfl,
- [SDM660_VDDMX] = &RWMX0_LEVEL_mx,
- [SDM660_VDDMX_AO] = &RWMX0_LEVEL_mx_ao,
- [SDM660_VDDMX_VFL] = &RWMX0_mx_vfl,
- [SDM660_SSCCX] = &RWLC0_ssccx_lvl,
- [SDM660_SSCCX_VFL] = &RWLC0_ssccx_vfl,
- [SDM660_SSCMX] = &RWLM0_sscmx_lvl,
- [SDM660_SSCMX_VFL] = &RWLM0_sscmx_vfl,
+ [SDM660_VDDCX] = &cx_rwcx0_lvl,
+ [SDM660_VDDCX_AO] = &cx_rwcx0_lvl_ao,
+ [SDM660_VDDCX_VFL] = &cx_rwcx0_vfl,
+ [SDM660_VDDMX] = &mx_rwmx0_lvl,
+ [SDM660_VDDMX_AO] = &mx_rwmx0_lvl_ao,
+ [SDM660_VDDMX_VFL] = &mx_rwmx0_vfl,
+ [SDM660_SSCCX] = &ssc_cx_rwlc0_lvl,
+ [SDM660_SSCCX_VFL] = &ssc_cx_rwlc0_vfl,
+ [SDM660_SSCMX] = &ssc_mx_rwlm0_lvl,
+ [SDM660_SSCMX_VFL] = &ssc_mx_rwlm0_vfl,
};

static const struct rpmpd_desc sdm660_desc = {
@@ -699,14 +699,14 @@ static const struct rpmpd_desc sdm660_desc = {

/* sm4250/6115 RPM Power domains */
static struct rpmpd *sm6115_rpmpds[] = {
- [SM6115_VDDCX] = &RWCX0_LEVEL_cx,
- [SM6115_VDDCX_AO] = &RWCX0_LEVEL_cx_ao,
- [SM6115_VDDCX_VFL] = &RWCX0_cx_vfl,
- [SM6115_VDDMX] = &RWMX0_LEVEL_mx,
- [SM6115_VDDMX_AO] = &RWMX0_LEVEL_mx_ao,
- [SM6115_VDDMX_VFL] = &RWMX0_mx_vfl,
- [SM6115_VDD_LPI_CX] = &RWLC0_lpi_cx_lvl,
- [SM6115_VDD_LPI_MX] = &RWLM0_lpi_mx_lvl,
+ [SM6115_VDDCX] = &cx_rwcx0_lvl,
+ [SM6115_VDDCX_AO] = &cx_rwcx0_lvl_ao,
+ [SM6115_VDDCX_VFL] = &cx_rwcx0_vfl,
+ [SM6115_VDDMX] = &mx_rwmx0_lvl,
+ [SM6115_VDDMX_AO] = &mx_rwmx0_lvl_ao,
+ [SM6115_VDDMX_VFL] = &mx_rwmx0_vfl,
+ [SM6115_VDD_LPI_CX] = &lpi_cx_rwlc0_lvl,
+ [SM6115_VDD_LPI_MX] = &lpi_mx_rwlm0_lvl,
};

static const struct rpmpd_desc sm6115_desc = {
@@ -717,12 +717,12 @@ static const struct rpmpd_desc sm6115_desc = {

/* sm6125 RPM Power domains */
static struct rpmpd *sm6125_rpmpds[] = {
- [SM6125_VDDCX] = &RWCX0_LEVEL_cx,
- [SM6125_VDDCX_AO] = &RWCX0_LEVEL_cx_ao,
- [SM6125_VDDCX_VFL] = &RWCX0_cx_vfl,
- [SM6125_VDDMX] = &RWMX0_LEVEL_mx,
- [SM6125_VDDMX_AO] = &RWMX0_LEVEL_mx_ao,
- [SM6125_VDDMX_VFL] = &RWMX0_mx_vfl,
+ [SM6125_VDDCX] = &cx_rwcx0_lvl,
+ [SM6125_VDDCX_AO] = &cx_rwcx0_lvl_ao,
+ [SM6125_VDDCX_VFL] = &cx_rwcx0_vfl,
+ [SM6125_VDDMX] = &mx_rwmx0_lvl,
+ [SM6125_VDDMX_AO] = &mx_rwmx0_lvl_ao,
+ [SM6125_VDDMX_VFL] = &mx_rwmx0_vfl,
};

static const struct rpmpd_desc sm6125_desc = {
@@ -732,16 +732,16 @@ static const struct rpmpd_desc sm6125_desc = {
};

static struct rpmpd *sm6375_rpmpds[] = {
- [SM6375_VDDCX] = &RWCX0_LEVEL_cx,
- [SM6375_VDDCX_AO] = &RWCX0_LEVEL_cx_ao,
- [SM6375_VDDCX_VFL] = &RWCX0_cx_vfl,
- [SM6375_VDDMX] = &RWMX0_LEVEL_mx,
- [SM6375_VDDMX_AO] = &RWMX0_LEVEL_mx_ao,
- [SM6375_VDDMX_VFL] = &RWMX0_mx_vfl,
- [SM6375_VDDGX] = &RWGX0_LEVEL_gx,
- [SM6375_VDDGX_AO] = &RWGX0_LEVEL_gx_ao,
- [SM6375_VDD_LPI_CX] = &RWLC0_lpi_cx_lvl,
- [SM6375_VDD_LPI_MX] = &RWLM0_lpi_mx_lvl,
+ [SM6375_VDDCX] = &cx_rwcx0_lvl,
+ [SM6375_VDDCX_AO] = &cx_rwcx0_lvl_ao,
+ [SM6375_VDDCX_VFL] = &cx_rwcx0_vfl,
+ [SM6375_VDDMX] = &mx_rwmx0_lvl,
+ [SM6375_VDDMX_AO] = &mx_rwmx0_lvl_ao,
+ [SM6375_VDDMX_VFL] = &mx_rwmx0_vfl,
+ [SM6375_VDDGX] = &gx_rwgx0_lvl,
+ [SM6375_VDDGX_AO] = &gx_rwgx0_lvl_ao,
+ [SM6375_VDD_LPI_CX] = &lpi_cx_rwlc0_lvl,
+ [SM6375_VDD_LPI_MX] = &lpi_mx_rwlm0_lvl,
};

static const struct rpmpd_desc sm6375_desc = {
@@ -751,14 +751,14 @@ static const struct rpmpd_desc sm6375_desc = {
};

static struct rpmpd *qcm2290_rpmpds[] = {
- [QCM2290_VDDCX] = &RWCX0_LEVEL_cx,
- [QCM2290_VDDCX_AO] = &RWCX0_LEVEL_cx_ao,
- [QCM2290_VDDCX_VFL] = &RWCX0_cx_vfl,
- [QCM2290_VDDMX] = &RWMX0_LEVEL_mx,
- [QCM2290_VDDMX_AO] = &RWMX0_LEVEL_mx_ao,
- [QCM2290_VDDMX_VFL] = &RWMX0_mx_vfl,
- [QCM2290_VDD_LPI_CX] = &RWLC0_lpi_cx_lvl,
- [QCM2290_VDD_LPI_MX] = &RWLM0_lpi_mx_lvl,
+ [QCM2290_VDDCX] = &cx_rwcx0_lvl,
+ [QCM2290_VDDCX_AO] = &cx_rwcx0_lvl_ao,
+ [QCM2290_VDDCX_VFL] = &cx_rwcx0_vfl,
+ [QCM2290_VDDMX] = &mx_rwmx0_lvl,
+ [QCM2290_VDDMX_AO] = &mx_rwmx0_lvl_ao,
+ [QCM2290_VDDMX_VFL] = &mx_rwmx0_vfl,
+ [QCM2290_VDD_LPI_CX] = &lpi_cx_rwlc0_lvl,
+ [QCM2290_VDD_LPI_MX] = &lpi_mx_rwlm0_lvl,
};

static const struct rpmpd_desc qcm2290_desc = {

--
2.39.2


2023-03-13 20:00:54

by Konrad Dybcio

[permalink] [raw]
Subject: [PATCH v3 10/10] soc: qcom: rpmpd: Remove useless comments

It goes without saying that socname_rpmpds[] is the array of the RPM
power domains associated with socname. Remove these comments.

Signed-off-by: Konrad Dybcio <[email protected]>
---
drivers/soc/qcom/rpmpd.c | 13 -------------
1 file changed, 13 deletions(-)

diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c
index 84283719853c..f8397dcb146c 100644
--- a/drivers/soc/qcom/rpmpd.c
+++ b/drivers/soc/qcom/rpmpd.c
@@ -514,7 +514,6 @@ static struct rpmpd ssc_mx_rwsm0_vfl = {
.key = KEY_FLOOR_LEVEL,
};

-/* mdm9607 RPM Power Domains */
static struct rpmpd *mdm9607_rpmpds[] = {
[MDM9607_VDDCX] = &cx_s3a_lvl,
[MDM9607_VDDCX_AO] = &cx_s3a_lvl_ao,
@@ -530,7 +529,6 @@ static const struct rpmpd_desc mdm9607_desc = {
.max_state = RPM_SMD_LEVEL_TURBO,
};

-/* msm8226 RPM Power Domains */
static struct rpmpd *msm8226_rpmpds[] = {
[MSM8226_VDDCX] = &cx_s1a_corner,
[MSM8226_VDDCX_AO] = &cx_s1a_corner_ao,
@@ -543,7 +541,6 @@ static const struct rpmpd_desc msm8226_desc = {
.max_state = MAX_CORNER_RPMPD_STATE,
};

-/* msm8939 RPM Power Domains */
static struct rpmpd *msm8939_rpmpds[] = {
[MSM8939_VDDMDCX] = &md_s1a_corner,
[MSM8939_VDDMDCX_AO] = &md_s1a_corner_ao,
@@ -561,7 +558,6 @@ static const struct rpmpd_desc msm8939_desc = {
.max_state = MAX_CORNER_RPMPD_STATE,
};

-/* msm8916 RPM Power Domains */
static struct rpmpd *msm8916_rpmpds[] = {
[MSM8916_VDDCX] = &cx_s1a_corner,
[MSM8916_VDDCX_AO] = &cx_s1a_corner_ao,
@@ -576,7 +572,6 @@ static const struct rpmpd_desc msm8916_desc = {
.max_state = MAX_CORNER_RPMPD_STATE,
};

-/* msm8953 RPM Power Domains */
static struct rpmpd *msm8953_rpmpds[] = {
[MSM8953_VDDMD] = &md_s1a_lvl,
[MSM8953_VDDMD_AO] = &md_s1a_lvl_ao,
@@ -593,7 +588,6 @@ static const struct rpmpd_desc msm8953_desc = {
.max_state = RPM_SMD_LEVEL_TURBO,
};

-/* msm8976 RPM Power Domains */
static struct rpmpd *msm8976_rpmpds[] = {
[MSM8976_VDDCX] = &cx_s2a_lvl,
[MSM8976_VDDCX_AO] = &cx_s2a_lvl_ao,
@@ -609,7 +603,6 @@ static const struct rpmpd_desc msm8976_desc = {
.max_state = RPM_SMD_LEVEL_TURBO_HIGH,
};

-/* msm8994 RPM Power domains */
static struct rpmpd *msm8994_rpmpds[] = {
[MSM8994_VDDCX] = &cx_s1a_corner,
[MSM8994_VDDCX_AO] = &cx_s1a_corner_ao,
@@ -628,7 +621,6 @@ static const struct rpmpd_desc msm8994_desc = {
.max_state = MAX_CORNER_RPMPD_STATE,
};

-/* msm8996 RPM Power domains */
static struct rpmpd *msm8996_rpmpds[] = {
[MSM8996_VDDCX] = &cx_s1a_corner,
[MSM8996_VDDCX_AO] = &cx_s1a_corner_ao,
@@ -645,7 +637,6 @@ static const struct rpmpd_desc msm8996_desc = {
.max_state = MAX_CORNER_RPMPD_STATE,
};

-/* msm8998 RPM Power domains */
static struct rpmpd *msm8998_rpmpds[] = {
[MSM8998_VDDCX] = &cx_rwcx0_lvl,
[MSM8998_VDDCX_AO] = &cx_rwcx0_lvl_ao,
@@ -665,7 +656,6 @@ static const struct rpmpd_desc msm8998_desc = {
.max_state = RPM_SMD_LEVEL_BINNING,
};

-/* qcs404 RPM Power domains */
static struct rpmpd *qcs404_rpmpds[] = {
[QCS404_VDDMX] = &mx_rwmx0_lvl,
[QCS404_VDDMX_AO] = &mx_rwmx0_lvl_ao,
@@ -682,7 +672,6 @@ static const struct rpmpd_desc qcs404_desc = {
.max_state = RPM_SMD_LEVEL_BINNING,
};

-/* sdm660 RPM Power domains */
static struct rpmpd *sdm660_rpmpds[] = {
[SDM660_VDDCX] = &cx_rwcx0_lvl,
[SDM660_VDDCX_AO] = &cx_rwcx0_lvl_ao,
@@ -702,7 +691,6 @@ static const struct rpmpd_desc sdm660_desc = {
.max_state = RPM_SMD_LEVEL_TURBO,
};

-/* sm4250/6115 RPM Power domains */
static struct rpmpd *sm6115_rpmpds[] = {
[SM6115_VDDCX] = &cx_rwcx0_lvl,
[SM6115_VDDCX_AO] = &cx_rwcx0_lvl_ao,
@@ -720,7 +708,6 @@ static const struct rpmpd_desc sm6115_desc = {
.max_state = RPM_SMD_LEVEL_TURBO_NO_CPR,
};

-/* sm6125 RPM Power domains */
static struct rpmpd *sm6125_rpmpds[] = {
[SM6125_VDDCX] = &cx_rwcx0_lvl,
[SM6125_VDDCX_AO] = &cx_rwcx0_lvl_ao,

--
2.39.2


2023-03-15 23:34:02

by Bjorn Andersson

[permalink] [raw]
Subject: Re: [PATCH v3 00/10] RPMPD cleanup + parent PD

On Mon, 13 Mar 2023 20:59:58 +0100, Konrad Dybcio wrote:
> v2 -> v3:
> - Correctly include the missing first patch (this is very embarassing)
> - Fix the _ao parent for SM6375_VDDGX
> - Use b4, hopefully everybody gets all the patches now..
>
> v2: https://lore.kernel.org/lkml/[email protected]/T/#m829f7bfcf911f5e16d9f83aefe810e5dedc7453d
>
> [...]

Applied, thanks!

[01/10] soc: qcom: rpmpd: Remove SoC names from RPMPD definitions
commit: f1eb5e6fc18c5e6f4ee7fd2985743f2fe7978951
[02/10] soc: qcom: rpmpd: Bring all definitions to the top
commit: a5d0e2819fd013e3629d3fedcae877777214ed34
[03/10] soc: qcom: rpmpd: Unify Low Power Island definitions
commit: d280f3d66d9a79b1bd50258ccb3fbb413216c1be
[04/10] soc: qcom: rpmpd: Remove vdd* from struct names
commit: 1c940cc42aba5b27a259634f4aedb71e5f46dac1
[05/10] soc: qcom: rpmpd: Expand struct definition macros
commit: 91c0bcef25f985fd974b6f1ba3d3d7383ac032d2
[06/10] soc: qcom: rpmpd: Improve the naming
commit: 07df05025eb4cb65c1549d392f988aa5eeb9e758
[07/10] soc: qcom: rpmpd: Make bindings assignments consistent
commit: d338fe40cf37c3f326b5cb743c6436369d452094
[08/10] soc: qcom: rpmpd: Add parent PD support
commit: decd6e77e02eff517efe11dfc181ce1b5bef3405
[09/10] soc: qcom: rpmpd: Hook up VDDMX as parent of SM6375 VDDGX
commit: ec90637c9946cc8e37afa4c1feb33fdb1fa15b68
[10/10] soc: qcom: rpmpd: Remove useless comments
commit: e556c94e8c20bcfb6c910e93a0cfd2d0cce5adc8

Best regards,
--
Bjorn Andersson <[email protected]>