Re: [PATCH 0/2] intel_pstate: fix turbo not being used after a processor is rebooted

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Dec 27, 2022 at 7:49 PM srinivas pandruvada
<srinivas.pandruvada@xxxxxxxxxxxxxxx> wrote:
>
> On Tue, 2022-12-27 at 19:47 +0100, Rafael J. Wysocki wrote:
> > On Tue, Dec 27, 2022 at 7:07 PM srinivas pandruvada
> > <srinivas.pandruvada@xxxxxxxxxxxxxxx> wrote:
> > >
> > > On Tue, 2022-12-27 at 18:02 +0100, Rafael J. Wysocki wrote:
> > > > On Tue, Dec 27, 2022 at 5:40 PM srinivas pandruvada
> > > > <srinivas.pandruvada@xxxxxxxxxxxxxxx> wrote:
> > > > >
> > > > > On Tue, 2022-12-27 at 16:38 +0100, Pratyush Yadav wrote:
> > > > > > Hi Srinivas,
> > > > > >
> > > > > > On Sat, Dec 24 2022, srinivas pandruvada wrote:
> > > > > >
> > > > > > > On Fri, 2022-12-23 at 10:10 -0800, srinivas pandruvada
> > > > > > > wrote:
> > > > > > > > Hi Pratyush,
> > > > > > > >
> > > > > > > > On Thu, 2022-12-22 at 11:39 +0100, Pratyush Yadav wrote:
> > > > > > > > >
> > > > > > > > > Hi Srinivas,
> > > > > > > > >
> > > > > > > > > On Wed, Dec 21 2022, srinivas pandruvada wrote:
> > > > > > > > > > On Wed, 2022-12-21 at 16:52 +0100, Pratyush Yadav
> > > > > > > > > > wrote:
> > > > > > > > > > > When a processor is brought offline and online
> > > > > > > > > > > again,
> > > > > > > > > > > it is
> > > > > > > > > > > unable to
> > > > > > > > > > > use Turbo mode because the _PSS table does not
> > > > > > > > > > > contain
> > > > > > > > > > > the
> > > > > > > > > > > whole
> > > > > > > > > > > turbo
> > > > > > > > > > > frequency range, but only +1 MHz above the max non-
> > > > > > > > > > > turbo
> > > > > > > > > > > frequency.
> > > > > > > > > > > This
> > > > > > > > > > > causes problems when ACPI processor driver tries to
> > > > > > > > > > > set
> > > > > > > > > > > frequency
> > > > > > > > > > > constraints. See patch 2 for more details.
> > > > > > > > > > >
> > > > > > > > I can reproduce on a Broadwell server platform. But not
> > > > > > > > on a
> > > > > > > > client
> > > > > > > > system with acpi_ppc usage.
> > > > > > > >
> > > > > > > > Need to check what change broke this.
> > > > > > >
> > > > > > > When PPC limits enforcement changed to PM QOS, this broke.
> > > > > > > Previously
> > > > > > > acpi_processor_get_platform_limit() was not enforcing any
> > > > > > > limits.
> > > > > > > It
> > > > > > > was just setting variable. So any update done after
> > > > > > > acpi_register_performance_state() call to pr->performance-
> > > > > > > > states[ppc].core_frequency, was effective.
> > > > > > >
> > > > > > > We don't really need to call
> > > > > > >         ret = freq_qos_update_request(&pr->perflib_req,
> > > > > > >                         pr->performance-
> > > > > > > > states[ppc].core_frequency
> > > > > > > *
> > > > > > > 1000);
> > > > > > >
> > > > > > > if the PPC is not changed. When PPC is changed, this gets
> > > > > > > called
> > > > > > > again,
> > > > > > > so then we can call the above function to update cpufreq
> > > > > > > limit.
> > > > > > >
> > > > > > > The below change fixed for me.
> > > > > >
> > > > > > Right.
> > > > > I think, this is the only change you require to fix this. In
> > > > > addition
> > > > > set pr->performance_platform_limit = 0 in
> > > > > acpi_processor_unregister_performance().
> > > >
> > > > Not really, because if the limit is set to a lower frequency and
> > > > then
> > > > reset to _PSS[0], it needs to be set back to "no limit".
> > > >
> > >
> > > If PPC becomes 0 again after ppc > 0 during dynamic PPC change, pr-
> > > > performance_platform_limit will not match current PPC, so will
> > > > set to
> > > PPC 0 performance ( which is already patched by driver after return
> > > from acpi_register_performance_state()).
> >
> > I see.
> >
> > > But fine, you can always set freq qos to FREQ_QOS_MAX_DEFAULT_VALUE
> > > for
> > > PPC 0 as you are doing in your patch.
> >
> > I think that using the "no limit" value to represent the "no limit"
> > condition makes sense.
> Agree.
>
> >
> > Also, I'm wondering if the patching of states[0].core_frequency will
> > still be necessary after this change.
>
> I don't think so. We can remove the patching.

OK, let me cut the patches.



[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]
  Powered by Linux