On Tue, Sep 15, 2020 at 02:05:19PM +0300, Jarkko Sakkinen wrote: > +struct sgx_enclave_run { > + __u64 tcs; > + __u32 flags; > + __u32 exit_reason; > + > + union { > + sgx_enclave_exit_handler_t user_handler; > + __u64 __user_handler; > + }; I will replace this with just: __u64 user_handler; > + __u64 user_data; > + > + union { > + struct sgx_enclave_exception exception; > + > + /* Pad the entire struct to 256 bytes. */ > + __u8 pad[256 - 32]; > + }; > +}; Resulting: struct sgx_enclave_run { __u64 tcs; __u32 flags; __u32 exit_reason; __u64 user_handler; __u64 user_data; union { struct sgx_enclave_exception exception; /* Pad the entire struct to 256 bytes. */ __u8 pad[256 - 32]; }; }; BTW, why there is that padding? /Jarkko