lkml.org 
[lkml]   [2020]   [Jan]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] x86/cpu: clear X86_BUG_SPECTRE_V2 on Zhaoxin family 7 CPUs
From
Date
On 16/01/2020 06:19, Thomas Gleixner wrote:
> Tony W Wang-oc <TonyWWang-oc@zhaoxin.com> writes:
>
>> These CPUs are not affected by spectre_v2, so clear spectre_v2 bug flag
>> in their specific initialization code.
>>
>> if (cpu_has(c, X86_FEATURE_VMX))
>> centaur_detect_vmx_virtcap(c);
>> +
>> + if (c->x86 == 7) {
>> + setup_clear_cpu_cap(X86_BUG_SPECTRE_V2);
>> + clear_bit(X86_BUG_SPECTRE_V2, (unsigned long *)cpu_caps_set);
>
> No. Please use cpu_vuln_whitelist. It exists for exactly this
> purpose. You just need to extend it with a NO_SPECTRE_V2 bit.

Got, done.

Sincerely
TonyWWang-oc

\
 
 \ /
  Last update: 2020-01-16 04:52    [W:0.042 / U:0.248 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site