selftests/sgx: Refine the test enclave to have storage
authorJarkko Sakkinen <jarkko@kernel.org>
Thu, 10 Jun 2021 08:30:21 +0000 (11:30 +0300)
committerShuah Khan <skhan@linuxfoundation.org>
Tue, 15 Jun 2021 22:27:23 +0000 (16:27 -0600)
commit22118ce17eb8dcf2a6ba2f6fb250816ddb59685a
tree9500effee23ad00a66540d603195e0afca535080
parentb334fb6fa7f38b4ad188d38307aea45e827b56ce
selftests/sgx: Refine the test enclave to have storage

Extend the enclave to have two operations: ENCL_OP_PUT and ENCL_OP_GET.
ENCL_OP_PUT stores value inside the enclave address space and
ENCL_OP_GET reads it. The internal buffer can be later extended to be
variable size, and allow reclaimer tests.

Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
tools/testing/selftests/sgx/defines.h
tools/testing/selftests/sgx/main.c
tools/testing/selftests/sgx/test_encl.c
tools/testing/selftests/sgx/test_encl.lds