> > On Tue, Feb 16, 2021 at 10:30:03AM +0000, Huang, Kai wrote: > > Because those contents are *architectural*. They are defined in SDM. > > > > And patch 13 (x86/sgx: Add helpers to expose ECREATE and EINIT to KVM) > > will introduce arch/x86/include/asm/sgx.h, where non-architectural > > functions will be declared. > > Who cares about the SDM? Sorry I am not sure I understand your question. Could you elaborate? IMHO it's better to put architectural staff (such as data structures defined in SDM and used by hardware) into one header, and other non-architectural staff into another header, so that the user can include the one that is actually required, but doesn't have to include one big header which includes all SGX related data structures and functions.