Skip to content

Commit f68f1cb

Browse files
committed
soc: qcom: rpmhpd: add sc8280xp & sa8540p rpmh power-domains
The Qualcomm sc8280xp platform has 13 and the sa8540p platform has 11 power-domains. Add compatibles, the typically used ones power-domains and their relevant active-only variants, to the RPMh power-domain driver. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Reviewed-by: Johan Hovold <johan+linaro@kernel.org> Link: https://lore.kernel.org/r/20220426233508.1762345-4-bjorn.andersson@linaro.org
1 parent af77132 commit f68f1cb

1 file changed

Lines changed: 53 additions & 0 deletions

File tree

drivers/soc/qcom/rpmhpd.c

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -180,6 +180,36 @@ static struct rpmhpd mxc_ao = {
180180
.res_name = "mxc.lvl",
181181
};
182182

183+
static struct rpmhpd nsp = {
184+
.pd = { .name = "nsp", },
185+
.res_name = "nsp.lvl",
186+
};
187+
188+
static struct rpmhpd qphy = {
189+
.pd = { .name = "qphy", },
190+
.res_name = "qphy.lvl",
191+
};
192+
193+
/* SA8540P RPMH powerdomains */
194+
static struct rpmhpd *sa8540p_rpmhpds[] = {
195+
[SC8280XP_CX] = &cx,
196+
[SC8280XP_CX_AO] = &cx_ao,
197+
[SC8280XP_EBI] = &ebi,
198+
[SC8280XP_GFX] = &gfx,
199+
[SC8280XP_LCX] = &lcx,
200+
[SC8280XP_LMX] = &lmx,
201+
[SC8280XP_MMCX] = &mmcx,
202+
[SC8280XP_MMCX_AO] = &mmcx_ao,
203+
[SC8280XP_MX] = &mx,
204+
[SC8280XP_MX_AO] = &mx_ao,
205+
[SC8280XP_NSP] = &nsp,
206+
};
207+
208+
static const struct rpmhpd_desc sa8540p_desc = {
209+
.rpmhpds = sa8540p_rpmhpds,
210+
.num_pds = ARRAY_SIZE(sa8540p_rpmhpds),
211+
};
212+
183213
/* SDM845 RPMH powerdomains */
184214
static struct rpmhpd *sdm845_rpmhpds[] = {
185215
[SDM845_CX] = &cx_w_mx_parent,
@@ -378,10 +408,33 @@ static const struct rpmhpd_desc sc8180x_desc = {
378408
.num_pds = ARRAY_SIZE(sc8180x_rpmhpds),
379409
};
380410

411+
/* SC8280xp RPMH powerdomains */
412+
static struct rpmhpd *sc8280xp_rpmhpds[] = {
413+
[SC8280XP_CX] = &cx,
414+
[SC8280XP_CX_AO] = &cx_ao,
415+
[SC8280XP_EBI] = &ebi,
416+
[SC8280XP_GFX] = &gfx,
417+
[SC8280XP_LCX] = &lcx,
418+
[SC8280XP_LMX] = &lmx,
419+
[SC8280XP_MMCX] = &mmcx,
420+
[SC8280XP_MMCX_AO] = &mmcx_ao,
421+
[SC8280XP_MX] = &mx,
422+
[SC8280XP_MX_AO] = &mx_ao,
423+
[SC8280XP_NSP] = &nsp,
424+
[SC8280XP_QPHY] = &qphy,
425+
};
426+
427+
static const struct rpmhpd_desc sc8280xp_desc = {
428+
.rpmhpds = sc8280xp_rpmhpds,
429+
.num_pds = ARRAY_SIZE(sc8280xp_rpmhpds),
430+
};
431+
381432
static const struct of_device_id rpmhpd_match_table[] = {
433+
{ .compatible = "qcom,sa8540p-rpmhpd", .data = &sa8540p_desc },
382434
{ .compatible = "qcom,sc7180-rpmhpd", .data = &sc7180_desc },
383435
{ .compatible = "qcom,sc7280-rpmhpd", .data = &sc7280_desc },
384436
{ .compatible = "qcom,sc8180x-rpmhpd", .data = &sc8180x_desc },
437+
{ .compatible = "qcom,sc8280xp-rpmhpd", .data = &sc8280xp_desc },
385438
{ .compatible = "qcom,sdm845-rpmhpd", .data = &sdm845_desc },
386439
{ .compatible = "qcom,sdx55-rpmhpd", .data = &sdx55_desc},
387440
{ .compatible = "qcom,sdx65-rpmhpd", .data = &sdx65_desc},

0 commit comments

Comments
 (0)