lkml.org 
[lkml]   [2020]   [Mar]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH v5 1/9] x86/split_lock: Rework the initialization flow of split lock detection
Date
Xiaoyao Li <xiaoyao.li@intel.com> writes:
> On 3/24/2020 6:29 PM, Thomas Gleixner wrote:
>> - switch (sld_state) {
>> + switch (state) {
>> case sld_off:
>> pr_info("disabled\n");
>> - break;
>> -
>> + return;
> Here, when sld_off, it just returns without
> setup_force_cpu_cap(X86_FEATURE_SPLIT_LOCK_DETECT).
>
> So for APs, it won't clear SLD bit in split_lock_init().

Trivial fix:

static void split_lock_init(void)
{
split_lock_verify_msr(sld_state != sld_off);
}

You just need to remove the __init annotation from split_lock_verify_msr().

Thanks,

tglx

\
 
 \ /
  Last update: 2020-03-25 02:14    [W:0.061 / U:0.384 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site