diff options
author | Jarkko Sakkinen <jarkko@kernel.org> | 2021-06-10 11:30:18 +0300 |
---|---|---|
committer | Shuah Khan <skhan@linuxfoundation.org> | 2021-06-16 01:23:09 +0300 |
commit | 235d1c9c63088c33d746a1e7e92e15153b8d1192 (patch) | |
tree | b77ee5282fcb8a91a3b915ecb4b01cf42b5a029d /tools/testing/selftests/sgx/load.c | |
parent | 6a7171b8a0f8e961744d0c46fb7547662a3fca36 (diff) | |
download | linux-235d1c9c63088c33d746a1e7e92e15153b8d1192.tar.xz |
selftests/sgx: Migrate to kselftest harness
Migrate to kselftest harness. Use a fixture test with enclave initialized
and de-initialized for each of the existing three tests, in other words:
1. One FIXTURE() for managing the enclave life-cycle.
2. Three TEST_F()'s, one for each test case.
Dump lines of /proc/self/maps matching "sgx" in FIXTURE_SETUP() as this
can be very useful debugging information later on.
Amended commit log:
This migration changes the output of this test. Instead of skipping
the tests if open /dev/sgx_enclave fails, it will run all the tests
and report failures on all of them.
Shuah Khan <skhan@linuxfoundation.org>
Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Diffstat (limited to 'tools/testing/selftests/sgx/load.c')
-rw-r--r-- | tools/testing/selftests/sgx/load.c | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/tools/testing/selftests/sgx/load.c b/tools/testing/selftests/sgx/load.c index f441ac34b4d4..00928be57fc4 100644 --- a/tools/testing/selftests/sgx/load.c +++ b/tools/testing/selftests/sgx/load.c @@ -239,9 +239,6 @@ bool encl_load(const char *path, struct encl *encl) seg->offset = (phdr->p_offset & PAGE_MASK) - src_offset; seg->size = (phdr->p_filesz + PAGE_SIZE - 1) & PAGE_MASK; - printf("0x%016lx 0x%016lx 0x%02x\n", seg->offset, seg->size, - seg->prot); - j++; } |