From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Cooper Subject: Re: [PATCH RFC 27/31] xen/x86: Rework Intel masking/faulting setup Date: Fri, 22 Jan 2016 14:46:20 +0000 Message-ID: <56A240BC.50900@citrix.com> References: <1450301073-28191-1-git-send-email-andrew.cooper3@citrix.com> <1450301073-28191-28-git-send-email-andrew.cooper3@citrix.com> <56A2073B02000078000C9EDB@prv-mh.provo.novell.com> <56A23827.2080208@citrix.com> <56A24AD202000078000CA23B@prv-mh.provo.novell.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <56A24AD202000078000CA23B@prv-mh.provo.novell.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Jan Beulich Cc: Xen-devel List-Id: xen-devel@lists.xenproject.org On 22/01/16 14:29, Jan Beulich wrote: >>>> On 22.01.16 at 15:09, wrote: >> On 22/01/16 09:40, Jan Beulich wrote: >>>>>> On 16.12.15 at 22:24, wrote: >>>> @@ -183,22 +237,13 @@ static void early_init_intel(struct cpuinfo_x86 *c) >>>> (boot_cpu_data.x86_mask == 3 || boot_cpu_data.x86_mask == 4)) >>>> paddr_bits = 36; >>>> >>>> - if (c == &boot_cpu_data && c->x86 == 6) { >>>> - if (probe_intel_cpuid_faulting()) >>>> - __set_bit(X86_FEATURE_CPUID_FAULTING, >>>> - c->x86_capability); >>>> - } else if (boot_cpu_has(X86_FEATURE_CPUID_FAULTING)) { >>>> - BUG_ON(!probe_intel_cpuid_faulting()); >>>> - __set_bit(X86_FEATURE_CPUID_FAULTING, c->x86_capability); >>>> - } >>>> + if (c == &boot_cpu_data) >>>> + intel_init_levelling(); >>>> + >>>> + if (test_bit(X86_FEATURE_CPUID_FAULTING, boot_cpu_data.x86_capability)) >>>> + __set_bit(X86_FEATURE_CPUID_FAULTING, c->x86_capability); >>> So you intentionally delete the validation of CPUID faulting being >>> available on APs? >> Yes. All this does is change where Xen crashes, in the case that AP's >> have different capabilities to the BSP, and allows more startup code to >> move into __init. > So where did that Xen crash point move to (since I didn't spot it)? set_cpuid_faulting() doesn't use safe MSR accesses, so would crash on first use in a mixed setup. I could extend it to ASSERT(cpu_has_cpuid_faulting) if you would prefer. ~Andrew