Thread (69 messages) 69 messages, 5 authors, 2021-03-18

Re: [PATCH v2 07/25] x86/sgx: Initialize virtual EPC driver even when SGX driver is disabled

From: Sean Christopherson <seanjc@google.com>
Date: 2021-03-16 01:14:56
Also in: lkml

On Tue, Mar 16, 2021, Jarkko Sakkinen wrote:
On Tue, Mar 16, 2021 at 01:05:05AM +0200, Jarkko Sakkinen wrote:
quoted
The way I've understood it is that given that KVM can support SGX
without FLC, vEPC should be available even if driver cannot be
enabled.

This is also exactly what the short summary states.

"Initialize virtual EPC driver even when SGX driver is disabled"

It *does not* state:

"Initialize SGX driver even when vEPC driver is disabled"

Also, this is how I interpret the inline comment.

All this considered, the other direction is undocumented functionality.
Also:

1. There is *zero* good practical reasons to support the "2nd direction".
Uh, yes there is.  CONFIG_KVM_INTEL=n and X86_FEATURE_VMX=n, either of which
will cause vEPC initialization to fail.  The former is obvious, the latter is
possible via BIOS configuration.
   For KVM getting init'd with SGX, on the other hand, we have good
   practical reasons.
2. We can get something practically useful with simpler and more verbose
   code, i.e. better logging.

/Jarkko
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help