Re: [PATCH v17 03/23] x86/cpufeatures: Add SGX sub-features (as Linux-defined bits)

2018-11-18 Thread Jarkko Sakkinen
On Fri, Nov 16, 2018 at 03:31:28PM -0800, Dave Hansen wrote: > On 11/15/18 5:01 PM, Jarkko Sakkinen wrote: > > +#define X86_FEATURE_SGX1 ( 8*32+ 0) /* SGX1 leaf functions */ > > +#define X86_FEATURE_SGX2 ( 8*32+ 1) /* SGX2 leaf functions */ > > Is there a reason these are not (

Re: [PATCH v17 03/23] x86/cpufeatures: Add SGX sub-features (as Linux-defined bits)

2018-11-16 Thread Dave Hansen
On 11/15/18 5:01 PM, Jarkko Sakkinen wrote: > +#define X86_FEATURE_SGX1 ( 8*32+ 0) /* SGX1 leaf functions */ > +#define X86_FEATURE_SGX2 ( 8*32+ 1) /* SGX2 leaf functions */ Is there a reason these are not (all) tied to CONFIG_INTEL_SGX via: arch/x86/include/asm/disabled-f

Re: [PATCH v17 03/23] x86/cpufeatures: Add SGX sub-features (as Linux-defined bits)

2018-11-16 Thread Sean Christopherson
On Fri, Nov 16, 2018 at 03:37:15PM +0100, Borislav Petkov wrote: > On Fri, Nov 16, 2018 at 03:01:10AM +0200, Jarkko Sakkinen wrote: > > From: Sean Christopherson > > > > CPUID_12_EAX is an Intel-defined feature bits leaf dedicated for SGX > > that enumerates the SGX instruction sets that are supp

Re: [PATCH v17 03/23] x86/cpufeatures: Add SGX sub-features (as Linux-defined bits)

2018-11-16 Thread Borislav Petkov
On Fri, Nov 16, 2018 at 03:01:10AM +0200, Jarkko Sakkinen wrote: > From: Sean Christopherson > > CPUID_12_EAX is an Intel-defined feature bits leaf dedicated for SGX > that enumerates the SGX instruction sets that are supported by the > CPU, e.g. SGX1, SGX2, etc... Because Linux currently only c

[PATCH v17 03/23] x86/cpufeatures: Add SGX sub-features (as Linux-defined bits)

2018-11-15 Thread Jarkko Sakkinen
From: Sean Christopherson CPUID_12_EAX is an Intel-defined feature bits leaf dedicated for SGX that enumerates the SGX instruction sets that are supported by the CPU, e.g. SGX1, SGX2, etc... Because Linux currently only cares about two bits (SGX1 and SGX2) and there are currently only four docum