lkml.org 
[lkml]   [2019]   [Apr]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] cpufreq/intel_pstate: Do not issue the not supported message on !Intel
Date

> index ea62e3f02d56..19854f01e2fa 100644
> --- a/drivers/cpufreq/intel_pstate.c
> +++ b/drivers/cpufreq/intel_pstate.c
> @@ -2608,7 +2608,9 @@ static int __init intel_pstate_init(void)
> } else {
> id = x86_match_cpu(intel_pstate_cpu_ids);
> if (!id) {
> - pr_info("CPU ID not supported\n");
> + if (boot_cpu_data.x86_vendor == X86_VENDOR_INTEL)
> + pr_info("CPU model not supported\n");
> +
> return -ENODEV;
> }

That's a good catch but I was wondering why not putting this vendor
condition at the initial "if (noload)" statement.

I mean, if we don't run an intel CPU there is no need of making the
x86_match_cpu().

This commit is also killing the case of reporting an unsupported intel
processor.


I'd suggest something like this and keep the 'CPUID not supported' part
untouched.

    if (no_load) || (boot_cpu_data.x86_vendor != X86_VENDOR_INTEL)

        return -ENODEV

\
 
 \ /
  Last update: 2019-04-01 10:12    [W:0.106 / U:10.684 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site