linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] pmdomain: arm: Avoid polling for scmi_perf_domain
@ 2023-11-27 13:50 Ulf Hansson
  2023-11-27 15:05 ` Sudeep Holla
  0 siblings, 1 reply; 3+ messages in thread
From: Ulf Hansson @ 2023-11-27 13:50 UTC (permalink / raw)
  To: Sudeep Holla, Cristian Marussi
  Cc: Nikunj Kela, Prasad Sodagudi, Alexandre Torgue, Ulf Hansson,
	linux-pm, linux-arm-kernel, linux-kernel

It was a mistake to prefer polling based mode when setting a performance
level for a domain. Let's instead rely on the protocol to decide what is
best and thus avoid polling when possible.

Reported-by: Nikunj Kela <nkela@quicinc.com>
Fixes: 2af23ceb8624 ("pmdomain: arm: Add the SCMI performance domain")
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
---
 drivers/pmdomain/arm/scmi_perf_domain.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/pmdomain/arm/scmi_perf_domain.c b/drivers/pmdomain/arm/scmi_perf_domain.c
index bc3f78abb6da..709bbc448fad 100644
--- a/drivers/pmdomain/arm/scmi_perf_domain.c
+++ b/drivers/pmdomain/arm/scmi_perf_domain.c
@@ -35,7 +35,7 @@ scmi_pd_set_perf_state(struct generic_pm_domain *genpd, unsigned int state)
 	if (!state)
 		return -EINVAL;
 
-	ret = pd->perf_ops->level_set(pd->ph, pd->domain_id, state, true);
+	ret = pd->perf_ops->level_set(pd->ph, pd->domain_id, state, false);
 	if (ret)
 		dev_warn(&genpd->dev, "Failed with %d when trying to set %d perf level",
 			 ret, state);
-- 
2.34.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] pmdomain: arm: Avoid polling for scmi_perf_domain
  2023-11-27 13:50 [PATCH] pmdomain: arm: Avoid polling for scmi_perf_domain Ulf Hansson
@ 2023-11-27 15:05 ` Sudeep Holla
  2023-11-27 15:33   ` Ulf Hansson
  0 siblings, 1 reply; 3+ messages in thread
From: Sudeep Holla @ 2023-11-27 15:05 UTC (permalink / raw)
  To: Ulf Hansson
  Cc: Cristian Marussi, Nikunj Kela, Prasad Sodagudi, Alexandre Torgue,
	linux-pm, linux-arm-kernel, linux-kernel

On Mon, Nov 27, 2023 at 02:50:33PM +0100, Ulf Hansson wrote:
> It was a mistake to prefer polling based mode when setting a performance
> level for a domain. Let's instead rely on the protocol to decide what is
> best and thus avoid polling when possible.
>
> Reported-by: Nikunj Kela <nkela@quicinc.com>
> Fixes: 2af23ceb8624 ("pmdomain: arm: Add the SCMI performance domain")

Ah, I hadn't even noticed before  :). Anyways,

Reviewed-by: Sudeep Holla <sudeep.holla@arm.com>

--
Regards,
Sudeep

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] pmdomain: arm: Avoid polling for scmi_perf_domain
  2023-11-27 15:05 ` Sudeep Holla
@ 2023-11-27 15:33   ` Ulf Hansson
  0 siblings, 0 replies; 3+ messages in thread
From: Ulf Hansson @ 2023-11-27 15:33 UTC (permalink / raw)
  To: Sudeep Holla
  Cc: Cristian Marussi, Nikunj Kela, Prasad Sodagudi, Alexandre Torgue,
	linux-pm, linux-arm-kernel, linux-kernel

On Mon, 27 Nov 2023 at 16:05, Sudeep Holla <sudeep.holla@arm.com> wrote:
>
> On Mon, Nov 27, 2023 at 02:50:33PM +0100, Ulf Hansson wrote:
> > It was a mistake to prefer polling based mode when setting a performance
> > level for a domain. Let's instead rely on the protocol to decide what is
> > best and thus avoid polling when possible.
> >
> > Reported-by: Nikunj Kela <nkela@quicinc.com>
> > Fixes: 2af23ceb8624 ("pmdomain: arm: Add the SCMI performance domain")
>
> Ah, I hadn't even noticed before  :). Anyways,
>
> Reviewed-by: Sudeep Holla <sudeep.holla@arm.com>

Thanks, applied for fixes!

Kind regards
Uffe

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-11-27 15:34 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-11-27 13:50 [PATCH] pmdomain: arm: Avoid polling for scmi_perf_domain Ulf Hansson
2023-11-27 15:05 ` Sudeep Holla
2023-11-27 15:33   ` Ulf Hansson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).