<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/thermal/gov_power_allocator.c, branch linux-5.19.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-5.19.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-5.19.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2021-04-22T21:51:32Z</updated>
<entry>
<title>thermal/core/power allocator: Use the lockless __thermal_cdev_update() function</title>
<updated>2021-04-22T21:51:32Z</updated>
<author>
<name>Lukasz Luba</name>
</author>
<published>2021-04-22T15:36:24Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=ab39c8853737158604e154ad3b03639e74082bd6'/>
<id>urn:sha1:ab39c8853737158604e154ad3b03639e74082bd6</id>
<content type='text'>
Use the new helper function and avoid unnecessery second lock/unlock,
which was present in old approach with thermal_cdev_update().

Signed-off-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Link: https://lore.kernel.org/r/20210422153624.6074-4-lukasz.luba@arm.com
</content>
</entry>
<entry>
<title>thermal/core/power_allocator: Update once cooling devices when temp is low</title>
<updated>2021-04-22T21:51:14Z</updated>
<author>
<name>Lukasz Luba</name>
</author>
<published>2021-04-22T11:43:08Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=0952177f2a1f63ba87a1940fac21768f402c0b94'/>
<id>urn:sha1:0952177f2a1f63ba87a1940fac21768f402c0b94</id>
<content type='text'>
The cooling device state change generates an event, also when there is no
need, because temperature is low and device is not throttled. Avoid to
unnecessary update the cooling device which means also not sending event.
The cooling device state has not changed because the temperature is still
below the first activation trip point value, so we can do this.
Add a tracking mechanism to make sure it updates cooling devices only
once - when the temperature dropps below first trip point.

Reported-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Signed-off-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Link: https://lore.kernel.org/r/20210422114308.29684-4-lukasz.luba@arm.com
</content>
</entry>
<entry>
<title>thermal/core/power_allocator: Maintain the device statistics from going stale</title>
<updated>2021-04-22T21:50:49Z</updated>
<author>
<name>Lukasz Luba</name>
</author>
<published>2021-04-22T11:43:07Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d3b60ed9b135e2c652115db691a87dc28b324bea'/>
<id>urn:sha1:d3b60ed9b135e2c652115db691a87dc28b324bea</id>
<content type='text'>
When the temperature is below the first activation trip point the cooling
devices are not checked, so they cannot maintain fresh statistics. It
leads into the situation, when temperature crosses first trip point, the
statistics are stale and show state for very long period. This has impact
on IPA algorithm calculation and wrong decisions. Thus, check the cooling
devices even when the temperature is low, to refresh these statistics.

Signed-off-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Link: https://lore.kernel.org/r/20210422114308.29684-3-lukasz.luba@arm.com
</content>
</entry>
<entry>
<title>thermal/core/power_allocator: Using round the division when re-divvying up power</title>
<updated>2021-03-16T11:44:20Z</updated>
<author>
<name>jeson.gao</name>
</author>
<published>2021-03-15T08:25:37Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=6e3e14c9385c3cfb35f9da4f495acdd21f9bc25b'/>
<id>urn:sha1:6e3e14c9385c3cfb35f9da4f495acdd21f9bc25b</id>
<content type='text'>
The division is used directly in re-divvying up power, the decimal part will
be discarded, devices will get less than the extra_actor_power - 1.
if using round the division to make the calculation more accurate.

For example:
actor0 received more than its max_power, it has the extra_power 759
actor1 received less than its max_power, it require extra_actor_power 395
actor2 received less than its max_power, it require extra_actor_power 365
actor1 and actor2 require the total capped_extra_power 760

using division in re-divvying up power
actor1 would actually get the extra_actor_power 394
actor2 would actually get the extra_actor_power 364

if using round the division in re-divvying up power
actor1 would actually get the extra_actor_power 394
actor2 would actually get the extra_actor_power 365

Signed-off-by: Jeson Gao &lt;jeson.gao@unisoc.com&gt;
Reviewed-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Link: https://lore.kernel.org/r/1615796737-4688-1-git-send-email-gao.yunxiao6@gmail.com
</content>
</entry>
<entry>
<title>thermal: power allocator: fail binding for non-power actor devices</title>
<updated>2021-01-19T21:31:10Z</updated>
<author>
<name>Lukasz Luba</name>
</author>
<published>2021-01-19T11:41:26Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=7a583405f24bffdd9f696a8e1b2f02c297245f4d'/>
<id>urn:sha1:7a583405f24bffdd9f696a8e1b2f02c297245f4d</id>
<content type='text'>
The thermal zone can have cooling devices which are missing power actor
API. This could be due to missing Energy Model for devfreq or cpufreq
cooling device. In this case it is safe to fail the binding rather than
trying to workaround and control the temperature in such thermal zone.

Signed-off-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Link: https://lore.kernel.org/r/20210119114126.19480-1-lukasz.luba@arm.com
</content>
</entry>
<entry>
<title>thermal/core: Remove ms based delay fields</title>
<updated>2021-01-19T21:23:49Z</updated>
<author>
<name>Daniel Lezcano</name>
</author>
<published>2020-12-16T22:03:37Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b39d2dd5b5ed08d15711aefd5afd72bd87387c64'/>
<id>urn:sha1:b39d2dd5b5ed08d15711aefd5afd72bd87387c64</id>
<content type='text'>
The code does no longer use the ms unit based fields to set the
delays as they are replaced by the jiffies.

Remove them and replace their user to use the jiffies version instead.

Cc: Thara Gopinath &lt;thara.gopinath@linaro.org&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Reviewed-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Reviewed-by: Peter Kästle &lt;peter@piie.net&gt;
Acked-by: Hans de Goede &lt;hdegoede@redhat.com&gt;
Link: https://lore.kernel.org/r/20201216220337.839878-3-daniel.lezcano@linaro.org
</content>
</entry>
<entry>
<title>thermal: power allocator: change the 'k_*' always in estimate_pid_constants()</title>
<updated>2020-11-26T16:11:59Z</updated>
<author>
<name>Lukasz Luba</name>
</author>
<published>2020-11-24T16:10:25Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=90a996544946d1d4834ec2ec8add586edd905779'/>
<id>urn:sha1:90a996544946d1d4834ec2ec8add586edd905779</id>
<content type='text'>
The PID coefficients should be estimated again when there was a change to
sustainable power value made by user. This change removes unused argument
'force' and makes the function ready for such updates.

Signed-off-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Reviewed-by: Ionela Voinescu &lt;ionela.voinescu@arm.com&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Link: https://lore.kernel.org/r/20201124161025.27694-4-lukasz.luba@arm.com
</content>
</entry>
<entry>
<title>thermal: power allocator: refactor sustainable power estimation</title>
<updated>2020-11-26T16:11:59Z</updated>
<author>
<name>Lukasz Luba</name>
</author>
<published>2020-11-24T16:10:24Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=eda1ecfa772f11b68b0ddb8d1c3948451fcff5d6'/>
<id>urn:sha1:eda1ecfa772f11b68b0ddb8d1c3948451fcff5d6</id>
<content type='text'>
The sustainable power value might come from the Device Tree or can be
estimated in run time. The sustainable power might be updated by the user
via sysfs interface, which should trigger new estimation of PID
coefficients. There is no need to estimate it every time when the
governor is called and temperature is high. Instead, store the estimated
value and make it available via standard sysfs interface, so it can be
checked from the user-space.

Signed-off-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Reviewed-by: Ionela Voinescu &lt;ionela.voinescu@arm.com&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Link: https://lore.kernel.org/r/20201124161025.27694-3-lukasz.luba@arm.com
</content>
</entry>
<entry>
<title>thermal: power allocator: change the 'k_i' coefficient estimation</title>
<updated>2020-11-26T16:11:59Z</updated>
<author>
<name>Lukasz Luba</name>
</author>
<published>2020-11-24T16:10:23Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e34a7233896928e4e39d3cdb201ce605d5b258c2'/>
<id>urn:sha1:e34a7233896928e4e39d3cdb201ce605d5b258c2</id>
<content type='text'>
Intelligent Power Allocation (IPA) is built around the PID controller
concept. The initialization code tries to setup the environment based on
the information available in DT or estimate the value based on minimum
power reported by each of the cooling device. The estimation will have an
impact on the PID controller behaviour via the related 'k_po', 'k_pu',
'k_i' coefficients and also on the power budget calculation.

This change prevents the situation when 'k_i' is relatively big compared
to 'k_po' and 'k_pu' values. This might happen when the estimation for
'sustainable_power' returned small value, thus 'k_po' and 'k_pu' are
small.

Signed-off-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Reviewed-by: Ionela Voinescu &lt;ionela.voinescu@arm.com&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Link: https://lore.kernel.org/r/20201124161025.27694-2-lukasz.luba@arm.com
</content>
</entry>
<entry>
<title>thermal: core: Move power_actor_set_power into IPA</title>
<updated>2020-10-27T08:44:32Z</updated>
<author>
<name>Lukasz Luba</name>
</author>
<published>2020-10-15T11:24:41Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=345a8af7ea63ac75a9000159d6298769d3d50f91'/>
<id>urn:sha1:345a8af7ea63ac75a9000159d6298769d3d50f91</id>
<content type='text'>
Since the power actor section has one function power_actor_set_power()
move it into Intelligent Power Allocation (IPA). There is no other user
of that helper function. It would also allow to remove the check of
cdev_is_power_actor() because the code which calls it in IPA already does
the needed check. Make the function static since only IPA use it.

Signed-off-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Link: https://lore.kernel.org/r/20201015112441.4056-5-lukasz.luba@arm.com
</content>
</entry>
</feed>
