Thread (20 messages) 20 messages, 4 authors, 2024-03-28

Re: [RESEND][PATCH v2 4/4] soc: samsung: exynos-asv: Update Energy Model after adjusting voltage

From: Lukasz Luba <lukasz.luba@arm.com>
Date: 2024-03-26 20:13:04
Also in: linux-pm, linux-samsung-soc, lkml

Hi Dietmar,

On 3/26/24 11:20, Dietmar Eggemann wrote:
On 22/03/2024 12:08, Lukasz Luba wrote:

[...]
quoted
@@ -97,9 +98,17 @@ static int exynos_asv_update_opps(struct exynos_asv *asv)
  			last_opp_table = opp_table;
  
  			ret = exynos_asv_update_cpu_opps(asv, cpu);
-			if (ret < 0)
+			if (!ret) {
+				/*
+				 * When the voltage for OPPs successfully
+				 * changed, update the EM power values to
+				 * reflect the reality and not use stale data
At this point, can we really say that the voltage has changed?

   exynos_asv_update_cpu_opps()

     ...
     ret = dev_pm_opp_adjust_voltage()
     if (!ret)
       em_dev_update_chip_binning()
     ...

dev_pm_opp_adjust_voltage() also returns 0 when the voltage value stays
the same?

[...]
The comment for the dev_pm_opp_adjust_voltage() says that it
returns 0 if no modification was done or modification was
successful. So I cannot distinguish in that driver code, but
also there is no additional need to do it IMO (even framework
doesn't do this).

Regards,
Lukasz

[1] 
https://elixir.bootlin.com/linux/v6.9-rc1/source/drivers/opp/core.c#L2950

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help