lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ce377dda-e1ce-4553-b9b8-125620b8b2d7@amd.com>
Date:   Wed, 20 Sep 2023 11:56:09 -0500
From:   Mario Limonciello <mario.limonciello@....com>
To:     Oleksandr Natalenko <oleksandr@...alenko.name>,
        Huang Rui <ray.huang@....com>, Meng Li <li.meng@....com>
Cc:     linux-pm@...r.kernel.org, linux-kernel@...r.kernel.org,
        x86@...nel.org, linux-acpi@...r.kernel.org,
        Shuah Khan <skhan@...uxfoundation.org>,
        linux-kselftest@...r.kernel.org,
        Nathan Fontenot <nathan.fontenot@....com>,
        Deepak Sharma <deepak.sharma@....com>,
        Alex Deucher <alexander.deucher@....com>,
        Shimmer Huang <shimmer.huang@....com>,
        Perry Yuan <Perry.Yuan@....com>,
        Xiaojian Du <Xiaojian.Du@....com>,
        Viresh Kumar <viresh.kumar@...aro.org>,
        Borislav Petkov <bp@...en8.de>,
        "Rafael J . Wysocki" <rafael.j.wysocki@...el.com>
Subject: Re: [PATCH V7 0/7] amd-pstate preferred core

On 9/19/2023 14:01, Oleksandr Natalenko wrote:
>> Meng Li (7):
>>    x86: Drop CPU_SUP_INTEL from SCHED_MC_PRIO for the expansion.
>>    acpi: cppc: Add get the highest performance cppc control
>>    cpufreq: amd-pstate: Enable amd-pstate preferred core supporting.
>>    cpufreq: Add a notification message that the highest perf has changed
>>    cpufreq: amd-pstate: Update amd-pstate preferred core ranking
>>      dynamically
>>    Documentation: amd-pstate: introduce amd-pstate preferred core
>>    Documentation: introduce amd-pstate preferrd core mode kernel command
>>      line options
>>
>>   .../admin-guide/kernel-parameters.txt         |   5 +
>>   Documentation/admin-guide/pm/amd-pstate.rst   |  58 +++++-
>>   arch/x86/Kconfig                              |   5 +-
>>   drivers/acpi/cppc_acpi.c                      |  13 ++
>>   drivers/acpi/processor_driver.c               |   6 +
>>   drivers/cpufreq/amd-pstate.c                  | 197 ++++++++++++++++--
>>   drivers/cpufreq/cpufreq.c                     |  13 ++
>>   include/acpi/cppc_acpi.h                      |   5 +
>>   include/linux/amd-pstate.h                    |   6 +
>>   include/linux/cpufreq.h                       |   5 +
>>   10 files changed, 291 insertions(+), 22 deletions(-)
> 
> When applied on top of v6.5.3 this breaks turbo on my 5950X after suspend/resume cycle. Please see the scenario description below.
> 
> If I boot v6.5.3 + this patchset, then `turbostat` reports ~4.9 GHz on core 0 where `taskset -c 0 dd if=/dev/zero of=/dev/null` is being run.
> 
> After I suspend the machine and then resume it, and run `dd` again, `turbostat` reports the core to be capped to a stock frequency of ~3.4 GHz. Rebooting the machine fixes this, and the CPU can boost again.
> 
> If this patchset is reverted, then the CPU can turbo after suspend/resume cycle just fine.
> 
> I'm using `amd_pstate=guided`.
> 
> Is this behaviour expected?

To help confirm where the issue is, can I ask you to do three 
experiments with the patch series applied:

1) 'amd_pstate=active' on your kernel command line.
2) 'amd_pstate=active amd_prefcore=disable' on your kernel command line.
3) 'amd_pstate=guided amd_prefcore=disable' on your kernel command line.

Looking through the code, I anticipate from your report that it 
reproduces on "1" but not "2" and "3".

Meng,

Can you try to repro?

I think that it's probably a call to amd_pstate_init_prefcore() missing
from amd_pstate_cpu_resume() and also amd_pstate_epp_resume().

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ