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: <6e1831dc-9d7c-151c-ca83-594d249d6442@amd.com>
Date:   Thu, 4 Nov 2021 10:10:59 -0500
From:   Nathan Fontenot <nafonten@....com>
To:     Huang Rui <ray.huang@....com>,
        "Fontenot, Nathan" <Nathan.Fontenot@....com>
Cc:     "Rafael J . Wysocki" <rafael.j.wysocki@...el.com>,
        Viresh Kumar <viresh.kumar@...aro.org>,
        Shuah Khan <skhan@...uxfoundation.org>,
        Borislav Petkov <bp@...e.de>,
        Peter Zijlstra <peterz@...radead.org>,
        Ingo Molnar <mingo@...nel.org>,
        Giovanni Gherdovich <ggherdovich@...e.cz>,
        "linux-pm@...r.kernel.org" <linux-pm@...r.kernel.org>,
        "Sharma, Deepak" <Deepak.Sharma@....com>,
        "Deucher, Alexander" <Alexander.Deucher@....com>,
        "Limonciello, Mario" <Mario.Limonciello@....com>,
        Steven Noonan <steven@...vesoftware.com>,
        "Su, Jinzhou (Joe)" <Jinzhou.Su@....com>,
        "Du, Xiaojian" <Xiaojian.Du@....com>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "x86@...nel.org" <x86@...nel.org>
Subject: Re: [PATCH v3 06/21] cpufreq: amd: introduce a new amd pstate driver
 to support future processors

On 11/3/21 2:01 AM, Huang Rui wrote:

>>> diff --git a/drivers/cpufreq/amd-pstate.c b/drivers/cpufreq/amd-pstate.c
>>> new file mode 100644
>>> index 000000000000..a400861c7fdc
>>> --- /dev/null
>>> +++ b/drivers/cpufreq/amd-pstate.c
>>> @@ -0,0 +1,413 @@
>>> +/*
>>> + * amd-pstate.c - AMD Processor P-state Frequency Driver
>>> + *
>>> + * Copyright (C) 2021 Advanced Micro Devices, Inc. All Rights Reserved.
>>> + *
>>> + * This program is free software; you can redistribute it and/or
>>> + * modify it under the terms of the GNU General Public License
>>> + * as published by the Free Software Foundation; either version 2
>>> + * of the License, or (at your option) any later version.
>>> + *
>>> + * This program is distributed in the hope that it will be useful,
>>> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
>>> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
>>> + * GNU General Public License for more details.
>>> + *
>>> + * You should have received a copy of the GNU General Public License along with
>>> + * this program; if not, write to the Free Software
>>> + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
>>
>> You should use a SPDX license identifier instead of copying the GPL text
>> in the file. See Documentation/process/license-rules.rst
> 
> The SPDX license identifier is an alternative way to instead of the common
> way to express the license at the top comment of the file. Acutally it's
> not mandatory, right?
> 

It's not mandatory but I believe using SPDX identifiers is the preferred method.

...

>>> +static int __init amd_pstate_init(void)
>>> +{
>>> +	int ret;
>>> +
>>> +	if (boot_cpu_data.x86_vendor != X86_VENDOR_AMD)
>>> +		return -ENODEV;
>>> +
>>> +	if (!acpi_cpc_valid()) {
>>> +		pr_debug("%s, the _CPC object is not present in SBIOS\n",
>>> +			 __func__);
>>
>> Do we need to print the function name here (and below)?
> 
> It's a soft reminder to tell the user where the message comes from.
>

True, but you do define pr_fmt at the top of the file so users will know
this is coming from the amd_pstate driver.

-Nathan

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ