[PATCH] pmdomain: rockchip: inform about missing subdomain support when in use

Sascha Hauer s.hauer at pengutronix.de
Thu Mar 19 00:02:16 PDT 2026


On RK3588 the Rockchip power domain driver comes up with several
messages informing about missing subdomain support. Make this less
verbose by printing these messages only when power domains with
subdomains are actually used.

Signed-off-by: Sascha Hauer <s.hauer at pengutronix.de>
---
 drivers/pmdomain/rockchip/pm-domains.c | 31 +++++++++++++++++---------
 1 file changed, 21 insertions(+), 10 deletions(-)

diff --git a/drivers/pmdomain/rockchip/pm-domains.c b/drivers/pmdomain/rockchip/pm-domains.c
index 4916515f27..1e735dfe34 100644
--- a/drivers/pmdomain/rockchip/pm-domains.c
+++ b/drivers/pmdomain/rockchip/pm-domains.c
@@ -644,6 +644,23 @@ static int rockchip_pd_regulator_enable(struct rockchip_pm_domain *pd)
 	return regulator_enable(pd->supply);
 }
 
+static void rockchip_pm_power_on_subdomain(struct rockchip_pm_domain *pd)
+{
+	struct device_node *np;
+	int ngpd = 0;
+
+	for_each_child_of_node(pd->node, np)
+		ngpd++;
+
+	/*
+	 * TODO: implement pm_genpd_add_subdomain() support for barebox.
+	 * Until we need to, just let the user know about it
+	 */
+	if (ngpd)
+		dev_info(pd->pmu->dev, "%s: skipping %u nested power domains\n",
+			 pd->node->name, ngpd);
+}
+
 static int rockchip_pd_power_on(struct generic_pm_domain *domain)
 {
 	struct rockchip_pm_domain *pd = to_rockchip_pd(domain);
@@ -661,6 +678,8 @@ static int rockchip_pd_power_on(struct generic_pm_domain *domain)
 	if (ret)
 		rockchip_pd_regulator_disable(pd);
 
+	rockchip_pm_power_on_subdomain(pd);
+
 	return ret;
 }
 
@@ -873,19 +892,11 @@ static void rockchip_configure_pd_cnt(struct rockchip_pmu *pmu,
 static int rockchip_pm_add_subdomain(struct rockchip_pmu *pmu,
 				     struct device_node *parent)
 {
-	struct device_node *np;
-	int ngpd = 0;
-
-	for_each_child_of_node(parent, np)
-		ngpd++;
-
 	/*
 	 * TODO: implement pm_genpd_add_subdomain() support for barebox.
-	 * Until we need to, just let the user know about it
+	 * Until we need to, just let the user know about it when power domains
+	 * with subdomains are used.
 	 */
-	if (ngpd)
-		dev_info(pmu->dev, "%s: skipping %u nested power domains\n",
-			 parent->name, ngpd);
 
 	return 0;
 }
-- 
2.47.3




More information about the barebox mailing list