[SRU][OEM-6.8][Noble][PATCH 0/1] UBUNTU: SAUCE: cpufreq: intel_pstate: Use HWP to initialize ITMT if CPPC is missing

Aaron Rainbolt arainbolt at kfocus.org
Sat Jun 22 01:29:43 UTC 2024


BugLink: https://bugs.launchpad.net/bugs/2069988

SRU Justification:

[Impact]

The new EEVDF scheduler, introduced in Linux 6.6 and present in the Noble
6.8 kernel, requires ITMT in order to determine which cores are P-cores
and which cores are E-cores on hybrid-core Intel-based systems. Currently,
the intel_pstate requires CPPC v2 to be present in order to enable ITMT.
Not all systems that support ITMT also support CPPC v2 however. On such
systems, ITMT will be mistakenly disabled and the scheduler will no longer
be able to schedule intensive single-core workloads on P-cores reliably.
This results in a serious drop in single-core performance (machines
capable of getting Geekbench 5 single-core scores of over 1800 get scores
of less than 1000).

[Fix]

The proposed patch (which I have shamelessly "stolen" from the linux-acpi
mailing list where Rafael J. Wysocki proposed it) fixes this issue by
using information from MSR_HWP_CAPABILITIES to determine whether or not to
enable ITMT, in the event CPPC v2 is not present.

[Test Plan]

Internally, Kubuntu Focus will be using a thorough kernel testing suite on
our hardware to ensure the kernel functions correctly in a wide variety of
different use case scenarios, while also benchmarking the systems to
ensure that single-core Geekbench 5 scores rise to their expected level.
For public testing, it should be noted that this patch will only provide
a performance improvement on hardware without CPPC v2 and with a
hybrid-core Intel processor. If you do not have an affected system, the
patch should provide no change in performance at all. With this in mind,
the following plan should be sufficient to ensure the kernel is functional
and that performance is not negatively impacted:

* Install `7z`.
* Using an older kernel, run `7z b -mmt1` and record the results.
* Repeat the above three times.
* Install the kernel from proposed.
* Again, run `7z b -mmt1` and record the results three times.
* Compare these results and ensure that performance is approximately
  the same both before and after patching.
* Run the system with usual day-to-day workloads for a day or two to
  ensure that it is stable.

[Where problems could occur]

It is theoretically possible that kernel code that deals with ITMT could
behave strangely when ITMT is active without CPPC v2 present. This could
result in kernel instability, or (if the intel_pstate driver itself
misbehaves) performance degredation. The above test plan is intended to
catch either of these issues.



More information about the kernel-team mailing list