[PATCH 2/2] pmdomain: qcom: rpmhpd: Add SM8650 RPMh Power Domains
From: Neil Armstrong
Date: Wed Oct 25 2023 - 03:32:41 EST
Add RPMh Power Domains support for the SM8650 platform.
Signed-off-by: Neil Armstrong <neil.armstrong@xxxxxxxxxx>
---
drivers/pmdomain/qcom/rpmhpd.c | 30 ++++++++++++++++++++++++++++++
1 file changed, 30 insertions(+)
diff --git a/drivers/pmdomain/qcom/rpmhpd.c b/drivers/pmdomain/qcom/rpmhpd.c
index a631fe1f9a06..cf25ba1cac66 100644
--- a/drivers/pmdomain/qcom/rpmhpd.c
+++ b/drivers/pmdomain/qcom/rpmhpd.c
@@ -197,6 +197,11 @@ static struct rpmhpd nsp1 = {
.res_name = "nsp1.lvl",
};
+static struct rpmhpd nsp2 = {
+ .pd = { .name = "nsp2", },
+ .res_name = "nsp2.lvl",
+};
+
static struct rpmhpd qphy = {
.pd = { .name = "qphy", },
.res_name = "qphy.lvl",
@@ -475,6 +480,30 @@ static const struct rpmhpd_desc sm8550_desc = {
.num_pds = ARRAY_SIZE(sm8550_rpmhpds),
};
+/* SM8650 RPMH powerdomains */
+static struct rpmhpd *sm8650_rpmhpds[] = {
+ [RPMHPD_CX] = &cx,
+ [RPMHPD_CX_AO] = &cx_ao,
+ [RPMHPD_EBI] = &ebi,
+ [RPMHPD_GFX] = &gfx,
+ [RPMHPD_LCX] = &lcx,
+ [RPMHPD_LMX] = &lmx,
+ [RPMHPD_MMCX] = &mmcx_w_cx_parent,
+ [RPMHPD_MMCX_AO] = &mmcx_ao_w_cx_parent,
+ [RPMHPD_MSS] = &mss,
+ [RPMHPD_MX] = &mx,
+ [RPMHPD_MX_AO] = &mx_ao,
+ [RPMHPD_MXC] = &mxc,
+ [RPMHPD_MXC_AO] = &mxc_ao,
+ [RPMHPD_NSP] = &nsp,
+ [RPMHPD_NSP2] = &nsp2,
+};
+
+static const struct rpmhpd_desc sm8650_desc = {
+ .rpmhpds = sm8650_rpmhpds,
+ .num_pds = ARRAY_SIZE(sm8650_rpmhpds),
+};
+
/* QDU1000/QRU1000 RPMH powerdomains */
static struct rpmhpd *qdu1000_rpmhpds[] = {
[QDU1000_CX] = &cx,
@@ -585,6 +614,7 @@ static const struct of_device_id rpmhpd_match_table[] = {
{ .compatible = "qcom,sm8350-rpmhpd", .data = &sm8350_desc },
{ .compatible = "qcom,sm8450-rpmhpd", .data = &sm8450_desc },
{ .compatible = "qcom,sm8550-rpmhpd", .data = &sm8550_desc },
+ { .compatible = "qcom,sm8650-rpmhpd", .data = &sm8650_desc },
{ }
};
MODULE_DEVICE_TABLE(of, rpmhpd_match_table);
--
2.34.1