Re: v5.7: new core kernel option missing help text

From: Vincent Guittot
Date: Wed Jun 03 2020 - 16:22:54 EST


On Wed, 3 Jun 2020 at 21:59, Russell King - ARM Linux admin
<linux@xxxxxxxxxxxxxxx> wrote:
>
> On Wed, Jun 03, 2020 at 09:24:56PM +0200, Vincent Guittot wrote:
> > On Wed, 3 Jun 2020 at 20:45, Russell King - ARM Linux admin
> > <linux@xxxxxxxxxxxxxxx> wrote:
> > > It's a start. I'm still wondering whether I should answer yes or no
> > > for the platforms I'm building for.
> > >
> > > So far, all I've found is:
> > >
> > > arch/arm/include/asm/topology.h:#define arch_scale_thermal_pressure topology_get_thermal_pressure
> > >
> > > which really doesn't tell me anything about this. So I'm still in
> > > the dark.
> > >
> > > I guess topology_get_thermal_pressure is provided by something in
> > > drivers/ which will be conditional on some driver or something.
> >
> > You need cpufreq_cooling device to make it useful and only for SMP
> > I don't think that this should not be user configurable because even
> > with the description above, it is not easy to choose.
> > This should be set by the driver that implement the feature which is
> > only cpufreq cooling device for now it
>
> As I have CONFIG_CPU_FREQ_THERMAL=y in my config, I'm guessing (and it's
> only a guess) that I should say y to SCHED_THERMAL_PRESSURE ?

yes, you're right

>
> > > > + help
> > > > + This option allows the scheduler to be aware of CPU thermal throttling
> > > > + (i.e. thermal pressure), providing arch_scale_thermal_pressure() is
> > > > + implemented.
>
> Is this feature documented in terms of what it does? Do I assume that
> as the thermal trip points start tripping, that has an influence on
> the scheduler? Or is it the case that the scheduler is wanting to
> know when the cpu frequency changes?

When the thermal trip points start tripping, we take into account the
decrease of the compute capacity of the CU. This reduced capacity is
used instead of max capacity when we balance the tasks between CPUs.

A similar mechanism is used to account the time "stolen" by IRQ or
RT/DL tasks to CFS tasks

>
> Grepping for "thermal" in Documentation/scheduler brings up nothing.

John Mathew sent a patch to add documentation:
https://lkml.org/lkml/2020/5/14/290

>
> --
> RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
> FTTC for 0.8m (est. 1762m) line in suburbia: sync at 13.1Mbps down 424kbps up