Skip to content

Commit e79eec6

Browse files
pksublimerafaeljw
authored andcommitted
Documentation: Fix typos in energy model documentation
Fix typos in documentation related to energy model management. Signed-off-by: Patrick Little <plittle@gmail.com> Acked-by: Randy Dunlap <rdunlap@infradead.org> [ rjw: Subject and changelog edits ] Link: https://patch.msgid.link/20260128-documentation-fix-grammar-v1-1-39238dc471f9@gmail.com Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
1 parent 63804fe commit e79eec6

2 files changed

Lines changed: 11 additions & 11 deletions

File tree

Documentation/power/energy-model.rst

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ subsystems willing to use that information to make energy-aware decisions.
1414
The source of the information about the power consumed by devices can vary greatly
1515
from one platform to another. These power costs can be estimated using
1616
devicetree data in some cases. In others, the firmware will know better.
17-
Alternatively, userspace might be best positioned. And so on. In order to avoid
18-
each and every client subsystem to re-implement support for each and every
17+
Alternatively, userspace might be best positioned. In order to avoid
18+
having each and every client subsystem re-implement support for each and every
1919
possible source of information on its own, the EM framework intervenes as an
2020
abstraction layer which standardizes the format of power cost tables in the
2121
kernel, hence enabling to avoid redundant work.
@@ -32,7 +32,7 @@ be found in the Intelligent Power Allocation in
3232
Documentation/driver-api/thermal/power_allocator.rst.
3333
Kernel subsystems might implement automatic detection to check whether EM
3434
registered devices have inconsistent scale (based on EM internal flag).
35-
Important thing to keep in mind is that when the power values are expressed in
35+
An important thing to keep in mind is that when the power values are expressed in
3636
an 'abstract scale' deriving real energy in micro-Joules would not be possible.
3737

3838
The figure below depicts an example of drivers (Arm-specific here, but the
@@ -82,7 +82,7 @@ using kref mechanism. The device driver which provided the new EM at runtime,
8282
should call EM API to free it safely when it's no longer needed. The EM
8383
framework will handle the clean-up when it's possible.
8484

85-
The kernel code which want to modify the EM values is protected from concurrent
85+
The kernel code which wants to modify the EM values is protected from concurrent
8686
access using a mutex. Therefore, the device driver code must run in sleeping
8787
context when it tries to modify the EM.
8888

@@ -113,7 +113,7 @@ Registration of 'advanced' EM
113113
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
114114

115115
The 'advanced' EM gets its name due to the fact that the driver is allowed
116-
to provide more precised power model. It's not limited to some implemented math
116+
to provide a more precise power model. It's not limited to some implemented math
117117
formula in the framework (like it is in 'simple' EM case). It can better reflect
118118
the real power measurements performed for each performance state. Thus, this
119119
registration method should be preferred in case considering EM static power
@@ -172,7 +172,7 @@ Registration of 'simple' EM
172172
~~~~~~~~~~~~~~~~~~~~~~~~~~~
173173

174174
The 'simple' EM is registered using the framework helper function
175-
cpufreq_register_em_with_opp(). It implements a power model which is tight to
175+
cpufreq_register_em_with_opp(). It implements a power model which is tied to a
176176
math formula::
177177

178178
Power = C * V^2 * f
@@ -251,7 +251,7 @@ It returns the 'struct em_perf_state' pointer which is an array of performance
251251
states in ascending order.
252252
This function must be called in the RCU read lock section (after the
253253
rcu_read_lock()). When the EM table is not needed anymore there is a need to
254-
call rcu_real_unlock(). In this way the EM safely uses the RCU read section
254+
call rcu_read_unlock(). In this way the EM safely uses the RCU read section
255255
and protects the users. It also allows the EM framework to manage the memory
256256
and free it. More details how to use it can be found in Section 3.2 in the
257257
example driver.

Documentation/scheduler/sched-energy.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -244,15 +244,15 @@ Example 2.
244244

245245

246246
From these calculations, the Case 1 has the lowest total energy. So CPU 1
247-
is be the best candidate from an energy-efficiency standpoint.
247+
is the best candidate from an energy-efficiency standpoint.
248248

249249
Big CPUs are generally more power hungry than the little ones and are thus used
250250
mainly when a task doesn't fit the littles. However, little CPUs aren't always
251251
necessarily more energy-efficient than big CPUs. For some systems, the high OPPs
252252
of the little CPUs can be less energy-efficient than the lowest OPPs of the
253253
bigs, for example. So, if the little CPUs happen to have enough utilization at
254254
a specific point in time, a small task waking up at that moment could be better
255-
of executing on the big side in order to save energy, even though it would fit
255+
off executing on the big side in order to save energy, even though it would fit
256256
on the little side.
257257

258258
And even in the case where all OPPs of the big CPUs are less energy-efficient
@@ -285,7 +285,7 @@ much that can be done by the scheduler to save energy without severely harming
285285
throughput. In order to avoid hurting performance with EAS, CPUs are flagged as
286286
'over-utilized' as soon as they are used at more than 80% of their compute
287287
capacity. As long as no CPUs are over-utilized in a root domain, load balancing
288-
is disabled and EAS overridess the wake-up balancing code. EAS is likely to load
288+
is disabled and EAS overrides the wake-up balancing code. EAS is likely to load
289289
the most energy efficient CPUs of the system more than the others if that can be
290290
done without harming throughput. So, the load-balancer is disabled to prevent
291291
it from breaking the energy-efficient task placement found by EAS. It is safe to
@@ -385,7 +385,7 @@ Using EAS with any other governor than schedutil is not supported.
385385
6.5 Scale-invariant utilization signals
386386
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
387387

388-
In order to make accurate prediction across CPUs and for all performance
388+
In order to make accurate predictions across CPUs and for all performance
389389
states, EAS needs frequency-invariant and CPU-invariant PELT signals. These can
390390
be obtained using the architecture-defined arch_scale{cpu,freq}_capacity()
391391
callbacks.

0 commit comments

Comments
 (0)