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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240117220742.GC13777@ranerica-svr.sc.intel.com>
Date: Wed, 17 Jan 2024 14:07:42 -0800
From: Ricardo Neri <ricardo.neri-calderon@...ux.intel.com>
To: Tony W Wang-oc <TonyWWang-oc@...oxin.com>
Cc: rafael@...nel.org, lenb@...nel.org, robert.moore@...el.com,
	linux-acpi@...r.kernel.org, linux-kernel@...r.kernel.org,
	acpica-devel@...ts.linux.dev, tglx@...utronix.de, mingo@...hat.com,
	bp@...en8.de, dave.hansen@...ux.intel.com, x86@...nel.org,
	hpa@...or.com, mcgrof@...nel.org, peterz@...radead.org,
	j.granados@...sung.com, viresh.kumar@...aro.org,
	linux-pm@...r.kernel.org, CobeChen@...oxin.com, TimGuo@...oxin.com,
	LeoLiu-oc@...oxin.com, LindaChai@...oxin.com
Subject: Re: [PATCH 1/3] ACPI: CPPC: Add get the highest perf register value
 support

On Thu, Dec 28, 2023 at 03:57:03PM +0800, Tony W Wang-oc wrote:
> Add function cppc_get_highest_perf in generic CPPC driver to get the
> highest perf register value for specified core.
> 
> Signed-off-by: Tony W Wang-oc <TonyWWang-oc@...oxin.com>
> ---
>  drivers/acpi/cppc_acpi.c | 13 +++++++++++++
>  include/acpi/cppc_acpi.h |  5 +++++
>  2 files changed, 18 insertions(+)
> 
> diff --git a/drivers/acpi/cppc_acpi.c b/drivers/acpi/cppc_acpi.c
> index 7ff269a78c20..1a77c514d007 100644
> --- a/drivers/acpi/cppc_acpi.c
> +++ b/drivers/acpi/cppc_acpi.c
> @@ -1154,6 +1154,19 @@ int cppc_get_nominal_perf(int cpunum, u64 *nominal_perf)
>  	return cppc_get_perf(cpunum, NOMINAL_PERF, nominal_perf);
>  }
>  
> +/**
> + * cppc_get_highest_perf - Get the highest performance register value.
> + * @cpunum: CPU from which to get highest performance.
> + * @highest_perf: Return address.
> + *
> + * Return: 0 for success, -EIO otherwise.
> + */
> +int cppc_get_highest_perf(int cpunum, u64 *highest_perf)
> +{
> +	return cppc_get_perf(cpunum, HIGHEST_PERF, highest_perf);
> +}
> +EXPORT_SYMBOL_GPL(cppc_get_highest_perf);

The Intel P-State driver uses cppc_get_perf_caps(). You would not need to
export this function.

Having said that, the Intel P-State driver could also use this new
function, IMO. AFAICS, it does not *have* to use cppc_get_perf_caps().

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ