From: Dave Hansen Subject: Re: [PATCH v4 07/17] x86/split_lock: Enumerate #AC for split lock by MSR IA32_CORE_CAPABILITY Date: Mon, 4 Mar 2019 11:19:31 -0800 Message-ID: References: <1551494711-213533-1-git-send-email-fenghua.yu@intel.com> <1551494711-213533-8-git-send-email-fenghua.yu@intel.com> <8b810f50-e4ed-7020-c0df-203cf98c3ce8@intel.com> <20190304185922.GA231946@romley-ivt3.sc.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Cc: Thomas Gleixner , Ingo Molnar , Borislav Petkov , H Peter Anvin , Paolo Bonzini , Ashok Raj , Peter Zijlstra , Ravi V Shankar , Xiaoyao Li , linux-kernel , x86 , kvm@vger.kernel.org To: Fenghua Yu Return-path: In-Reply-To: <20190304185922.GA231946@romley-ivt3.sc.intel.com> Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org On 3/4/19 10:59 AM, Fenghua Yu wrote: >> But, it goes unmentioned why you do the boot-cpu-only restriction here. >> It doesn't match the behavior of the two functions called before >> init_core_capability(): >> >> init_scattered_cpuid_features(c); >> init_speculation_control(c); >> >> So why is this new function special? > The function sets the split_lock_detect feature which needs to be > applied before BSP calls apply_enforced_caps() in get_cpu_cap(). Why does it need to be applied that way? > And I want to enable split lock detection in earlier phase to detect > split lock earlier. Why do you want to do this? Why is this *required* as part of this implementation? ... and how is this different than the other features that are processed for cpus other than the boot CPU?