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: <YwwDzcNMQnMcPOU5@amd.com>
Date:   Mon, 29 Aug 2022 08:09:49 +0800
From:   Huang Rui <ray.huang@....com>
To:     Shuah Khan <skhan@...uxfoundation.org>
Cc:     "Meng, Li (Jassmine)" <Li.Meng@....com>,
        "linux-pm@...r.kernel.org" <linux-pm@...r.kernel.org>,
        "Rafael J . Wysocki" <rafael.j.wysocki@...el.com>,
        "Fontenot, Nathan" <Nathan.Fontenot@....com>,
        "Sharma, Deepak" <Deepak.Sharma@....com>,
        "Deucher, Alexander" <Alexander.Deucher@....com>,
        "Limonciello, Mario" <Mario.Limonciello@....com>,
        "Su, Jinzhou (Joe)" <Jinzhou.Su@....com>,
        "Yuan, Perry" <Perry.Yuan@....com>,
        "Du, Xiaojian" <Xiaojian.Du@....com>,
        Viresh Kumar <viresh.kumar@...aro.org>,
        Borislav Petkov <bp@...en8.de>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [RESEND PATCH 2/4] cpufreq: amd-pstate: Add test module for
 amd-pstate driver

On Sat, Aug 27, 2022 at 06:36:30AM +0800, Shuah Khan wrote:
> On 8/26/22 3:47 PM, Shuah Khan wrote:
> > On 8/16/22 9:46 PM, Meng Li wrote:
> >> Add amd-pstate-ut test module, this module is used by kselftest
> >> to unit test amd-pstate functionality. This module will be
> >> expected by some of selftests to be present and loaded.
> >>
> >> Signed-off-by: Meng Li <li.meng@....com>
> >> Acked-by: Huang Rui <ray.huang@....com>
> >> Reviewed-by: Shuah Khan <skhan@...uxfoundation.org>
> >> ---
> >>   drivers/cpufreq/Kconfig.x86     |   7 +
> >>   drivers/cpufreq/Makefile        |   1 +
> >>   drivers/cpufreq/amd-pstate-ut.c | 293 ++++++++++++++++++++++++++++++++
> >>   3 files changed, 301 insertions(+)
> >>   create mode 100644 drivers/cpufreq/amd-pstate-ut.c
> >>
> >> diff --git a/drivers/cpufreq/Kconfig.x86 b/drivers/cpufreq/Kconfig.x86
> >> index 55516043b656..fdd819069d72 100644
> >> --- a/drivers/cpufreq/Kconfig.x86
> >> +++ b/drivers/cpufreq/Kconfig.x86
> >> @@ -51,6 +51,13 @@ config X86_AMD_PSTATE
> >>         If in doubt, say N.
> >> +config X86_AMD_PSTATE_UT
> >> +    tristate "selftest for AMD Processor P-State driver"
> >> +    depends on X86 && ACPI_PROCESSOR
> 
> This has to specify dependency on X86_AMD_PSTATE
> 
> >> +    default n
> >> +    help
> >> +      This kernel module is used for testing. It's safe to say M here.
> >> +
> > 
> > Shouldn't this X86_AMD_PSTATE_UT depend on X86_AMD_PSTATE?
> > I am running a few tests and when I have X86_AMD_PSTATE_UT
> > enabled as built-in and X86_AMD_PSTATE is disabled, test
> > fails saying incorrect cpufreq driver?
> > 
> > Skipped: Test can only run on amd-pstate driver.
> > 
> > So it sounds like X86_AMD_PSTATE_UT depends on X86_AMD_PSTATE.
> > 
> 
> Once I enabled X86_AMD_PSTATE and X86_AMD_PSTATE_UT=m, the test
> ran correctly.
> 
> Please fix the dependencies and send me a new version. Send all
> the patches so it is easier to apply them all at once.
> 

Hi Shuah,

Thanks to accept the patch series. Actually, we want amd-pstate-ut can be
modprobed even without amd-pstate module, because it can tell the users
they loaded a wrong module like "acpi-cpufreq" and needs to replace it with
amd-pstate. :-)

Thanks,
Ray

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ