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: <fa14666a-269c-249a-f603-b00f6301c1a6@criteo.com>
Date:   Mon, 1 Apr 2019 08:11:51 +0000
From:   Erwan Velu <e.velu@...teo.com>
To:     Borislav Petkov <bp@...en8.de>, LKML <linux-kernel@...r.kernel.org>
CC:     Len Brown <lenb@...nel.org>,
        "linux-pm@...r.kernel.org" <linux-pm@...r.kernel.org>,
        "Rafael J . Wysocki" <rafael.j.wysocki@...el.com>,
        Srinivas Pandruvada <srinivas.pandruvada@...ux.intel.com>,
        Viresh Kumar <viresh.kumar@...aro.org>
Subject: Re: [PATCH] cpufreq/intel_pstate: Do not issue the not supported
 message on !Intel


> 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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ