sgx: merge what we know from v3.13.x/5.01.01.01

Signed-off-by: Robert Nelson <robertcnelson@gmail.com>