linux-sgx.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH for_v2? v2 00/14] selftests/x86/sgx: Improve tests
@ 2019-10-17  3:03 Sean Christopherson
  2019-10-17  3:03 ` [PATCH for_v2? v2 01/14] selftests/x86/sgx: Fix a benign linker warning Sean Christopherson
                   ` (14 more replies)
  0 siblings, 15 replies; 24+ messages in thread
From: Sean Christopherson @ 2019-10-17  3:03 UTC (permalink / raw)
  To: Jarkko Sakkinen; +Cc: linux-sgx, Cedric Xing, Andy Lutomirski

The bulk of this series is comprised of the selftest portion of the vDSO
cleanup[*].  The big difference from the full vDSO series is to reuse as
much of the existing selftest code as possible.  There is still a bit of
homebrew code in defining the low level assertion macro, but much less so
than in the previous from-scratch version.

Cc'd Andy, who also happens to be a reviewer for the harness code, on the
off chance he has bandwidth to weigh in.

Tagged for_v2? to make it clear that this doesn't need to be rushed into
v23.

Passing case:

  TAP version 13
  1..4
  ok 1 test_sgx_basic: Passed
  ok 2 test_sgx_vdso: Passed
  ok 3 test_sgx_vdso_exit_handler: Passed
  ok 4 test_sgx_vdso_exception_handler: Passed
  # Pass 4 Fail 0 Xfail 0 Xpass 0 Skip 0 Error 0

Failing case:

  TAP version 13
  1..4
  not ok 1 Expected 'result (1234605616436508552) != MAGIC (1234605616436508552)' at main.c:324
  ok 2 test_sgx_vdso: Passed
  ok 3 test_sgx_vdso_exit_handler: Passed
  ok 4 test_sgx_vdso_exception_handler: Passed
  # Pass 3 Fail 1 Xfail 0 Xpass 0 Skip 0 Error 0


[*] https://patchwork.kernel.org/cover/11178771/

Sean Christopherson (14):
  selftests/x86/sgx: Fix a benign linker warning
  selftests/x86/sgx: Use getauxval() to retrieve the vDSO base address
  selftests/x86/sgx: Sanitize the types for sgx_vdso_call()'s input
    params
  selftests/x86/sgx: Mark helper functions as static
  selftests/x86/sgx: Move vDSO setup to a helper function
  selftests/x86/sgx: Move individual tests into helper functions
  selftests/x86/sgx: Use standard helper function to signal pass/fail
  selftests/harness: Move operator macros to their own header file
  selftests/x86/sgx: Use kselftest operators to check test results
  selftests/x86/sgx: Handle setup failures via kselftest assertions
  selftests/x86/sgx: Add a check on the vDSO exception reporting
    mechanism
  selftests/x86/sgx: Add test of vDSO with basic exit handler
  selftests/x86/sgx: Add check to verify exit handler stack alignment
  selftests/x86/sgx: Add test for exception behavior with exit handler

 Documentation/dev-tools/kselftest.rst         |   9 +-
 MAINTAINERS                                   |   1 +
 tools/testing/selftests/kselftest_harness.h   | 246 +---------
 tools/testing/selftests/kselftest_operators.h | 255 +++++++++++
 tools/testing/selftests/x86/sgx/Makefile      |   2 +-
 tools/testing/selftests/x86/sgx/defines.h     |   7 +
 tools/testing/selftests/x86/sgx/main.c        | 426 +++++++++++-------
 tools/testing/selftests/x86/sgx/sgx_call.h    |   3 +-
 8 files changed, 541 insertions(+), 408 deletions(-)
 create mode 100644 tools/testing/selftests/kselftest_operators.h

-- 
2.22.0


^ permalink raw reply	[flat|nested] 24+ messages in thread

end of thread, other threads:[~2019-10-26 14:08 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-17  3:03 [PATCH for_v2? v2 00/14] selftests/x86/sgx: Improve tests Sean Christopherson
2019-10-17  3:03 ` [PATCH for_v2? v2 01/14] selftests/x86/sgx: Fix a benign linker warning Sean Christopherson
2019-10-17  3:03 ` [PATCH for_v2? v2 02/14] selftests/x86/sgx: Use getauxval() to retrieve the vDSO base address Sean Christopherson
2019-10-17  3:03 ` [PATCH for_v2? v2 03/14] selftests/x86/sgx: Sanitize the types for sgx_vdso_call()'s input params Sean Christopherson
2019-10-17  3:03 ` [PATCH for_v2? v2 04/14] selftests/x86/sgx: Mark helper functions as static Sean Christopherson
2019-10-17  3:03 ` [PATCH for_v2? v2 05/14] selftests/x86/sgx: Move vDSO setup to a helper function Sean Christopherson
2019-10-17  3:03 ` [PATCH for_v2? v2 06/14] selftests/x86/sgx: Move individual tests into helper functions Sean Christopherson
2019-10-17  3:03 ` [PATCH for_v2? v2 07/14] selftests/x86/sgx: Use standard helper function to signal pass/fail Sean Christopherson
2019-10-17  3:03 ` [PATCH for_v2? v2 08/14] selftests/harness: Move operator macros to their own header file Sean Christopherson
2019-10-17 16:53   ` Jarkko Sakkinen
2019-10-17 18:13     ` Sean Christopherson
2019-10-21 11:08       ` Jarkko Sakkinen
2019-10-22  3:20         ` Sean Christopherson
2019-10-17  3:03 ` [PATCH for_v2? v2 09/14] selftests/x86/sgx: Use kselftest operators to check test results Sean Christopherson
2019-10-17  3:03 ` [PATCH for_v2? v2 10/14] selftests/x86/sgx: Handle setup failures via kselftest assertions Sean Christopherson
2019-10-17  3:03 ` [PATCH for_v2? v2 11/14] selftests/x86/sgx: Add a check on the vDSO exception reporting mechanism Sean Christopherson
2019-10-17  3:03 ` [PATCH for_v2? v2 12/14] selftests/x86/sgx: Add test of vDSO with basic exit handler Sean Christopherson
2019-10-17  3:03 ` [PATCH for_v2? v2 13/14] selftests/x86/sgx: Add check to verify exit handler stack alignment Sean Christopherson
2019-10-17  3:03 ` [PATCH for_v2? v2 14/14] selftests/x86/sgx: Add test for exception behavior with exit handler Sean Christopherson
2019-10-18 10:12 ` [PATCH for_v2? v2 00/14] selftests/x86/sgx: Improve tests Jarkko Sakkinen
2019-10-18 10:20   ` Jarkko Sakkinen
2019-10-22 22:41     ` Sean Christopherson
2019-10-23 12:39       ` Jarkko Sakkinen
2019-10-26 14:08         ` Andy Lutomirski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).