From: Reinette Chatre <reinette.chatre@intel.com>
To: Jarkko Sakkinen <jarkko@kernel.org>, <linux-sgx@vger.kernel.org>
Cc: Haitao Huang <haitao.huang@linux.intel.com>,
Vijay Dhanraj <vijay.dhanraj@intel.com>,
Dave Hansen <dave.hansen@linux.intel.com>,
"Paul Menzel" <pmenzel@molgen.mpg.de>,
Shuah Khan <shuah@kernel.org>,
"open list:KERNEL SELFTEST FRAMEWORK"
<linux-kselftest@vger.kernel.org>,
open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v2 4/6] selftests/sgx: Add SGX selftest augment_via_eaccept_long
Date: Wed, 31 Aug 2022 13:07:35 -0700 [thread overview]
Message-ID: <d2b76530-82a2-6ac1-32ea-696e653d767d@intel.com> (raw)
In-Reply-To: <20220831173829.126661-5-jarkko@kernel.org>
Hi Jarkko,
On 8/31/2022 10:38 AM, Jarkko Sakkinen wrote:
> From: Vijay Dhanraj <vijay.dhanraj@intel.com>
>
> Add a new test case which is same as augment_via_eaccept but adds a
> larger number of EPC pages to stress test EAUG via EACCEPT.
>
> Signed-off-by: Vijay Dhanraj <vijay.dhanraj@intel.com>
> Co-developed-by: Jarkko Sakkinen <jarkko@kernel.org>
> Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org>
> ---
> v3:
> - Addressed Reinette's feedback:
> https://lore.kernel.org/linux-sgx/bd5285dd-d6dd-8a46-fca9-728db5e2f369@intel.com/
> v2:
> - Addressed Reinette's feedback:
> https://lore.kernel.org/linux-sgx/24bd8e42-ff4e-0090-d9e1-cd81e4807f21@intel.com/
> ---
> tools/testing/selftests/sgx/load.c | 5 +-
> tools/testing/selftests/sgx/main.c | 143 +++++++++++++++++++++++++----
> tools/testing/selftests/sgx/main.h | 3 +-
Is this test passing on your system? This version is missing the change to
mrenclave_ecreate() that causes SGX_IOC_ENCLAVE_INIT to fail when I try it out.
> 3 files changed, 130 insertions(+), 21 deletions(-)
>
> diff --git a/tools/testing/selftests/sgx/load.c b/tools/testing/selftests/sgx/load.c
> index 94bdeac1cf04..47b2786d6a77 100644
> --- a/tools/testing/selftests/sgx/load.c
> +++ b/tools/testing/selftests/sgx/load.c
> @@ -171,7 +171,8 @@ uint64_t encl_get_entry(struct encl *encl, const char *symbol)
> return 0;
> }
>
> -bool encl_load(const char *path, struct encl *encl, unsigned long heap_size)
> +bool encl_load(const char *path, struct encl *encl, unsigned long heap_size,
> + unsigned long edmm_size)
> {
> const char device_path[] = "/dev/sgx_enclave";
> struct encl_segment *seg;
> @@ -300,7 +301,7 @@ bool encl_load(const char *path, struct encl *encl, unsigned long heap_size)
>
> encl->src_size = encl->segment_tbl[j].offset + encl->segment_tbl[j].size;
>
> - for (encl->encl_size = 4096; encl->encl_size < encl->src_size; )
> + for (encl->encl_size = 4096; encl->encl_size < encl->src_size + edmm_size;)
> encl->encl_size <<= 1;
>
> return true;
> diff --git a/tools/testing/selftests/sgx/main.c b/tools/testing/selftests/sgx/main.c
> index 9820b3809c69..c5aa9f323745 100644
> --- a/tools/testing/selftests/sgx/main.c
> +++ b/tools/testing/selftests/sgx/main.c
> @@ -23,6 +23,10 @@
>
> static const uint64_t MAGIC = 0x1122334455667788ULL;
> static const uint64_t MAGIC2 = 0x8877665544332211ULL;
> +/* Message-ID: <DM8PR11MB55912A7F47A84EC9913A6352F6999@DM8PR11MB5591.namprd11.prod.outlook.com> */
> +static const uint64_t EDMM_SIZE_LONG = 8L * 1024L * 1024L * 1024L;
> +static const uint64_t TIMEOUT_LONG = 900; /* seconds */
> +
Apologies if my feedback was vague - I actually think that the comments in V1 added
valuable information, it was just the variation in formatting that was distracting.
Reinette
next prev parent reply other threads:[~2022-08-31 20:07 UTC|newest]
Thread overview: 38+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-31 17:38 [PATCH v2 0/6] x86/sgx: A collection of tests and fixes Jarkko Sakkinen
2022-08-31 17:38 ` [PATCH v2 1/6] selftests/sgx: Ignore OpenSSL 3.0 deprecated functions warning Jarkko Sakkinen
2022-08-31 17:38 ` [PATCH v2 2/6] x86/sgx: Do not consider unsanitized pages an error Jarkko Sakkinen
2022-08-31 20:39 ` Reinette Chatre
2022-09-01 10:50 ` Huang, Kai
2022-09-01 21:47 ` jarkko
2022-09-01 21:53 ` Jarkko Sakkinen
2022-09-01 21:56 ` Jarkko Sakkinen
2022-09-01 22:01 ` Jarkko Sakkinen
2022-09-01 22:34 ` Reinette Chatre
2022-09-01 23:56 ` Jarkko Sakkinen
2022-09-02 13:26 ` Jarkko Sakkinen
2022-09-02 15:53 ` Jarkko Sakkinen
2022-09-02 16:08 ` Reinette Chatre
2022-09-02 16:30 ` Jarkko Sakkinen
2022-09-02 17:38 ` Reinette Chatre
2022-09-02 19:20 ` Jarkko Sakkinen
2022-08-31 17:38 ` [PATCH v2 3/6] x86/sgx: Handle VA page allocation failure for EAUG on PF Jarkko Sakkinen
2022-08-31 18:08 ` Reinette Chatre
2022-08-31 18:21 ` Jarkko Sakkinen
2022-08-31 18:33 ` Reinette Chatre
2022-08-31 18:46 ` Jarkko Sakkinen
2022-08-31 17:38 ` [PATCH v2 4/6] selftests/sgx: Add SGX selftest augment_via_eaccept_long Jarkko Sakkinen
2022-08-31 20:07 ` Reinette Chatre [this message]
2022-09-01 22:22 ` Jarkko Sakkinen
2022-09-01 23:12 ` Reinette Chatre
2022-09-02 0:03 ` Jarkko Sakkinen
2022-09-04 4:02 ` Jarkko Sakkinen
2022-09-04 4:21 ` Jarkko Sakkinen
2022-08-31 17:38 ` [PATCH v2 5/6] selftests/sgx: retry the ioctls returned with EAGAIN Jarkko Sakkinen
2022-08-31 20:08 ` Reinette Chatre
2022-08-31 17:38 ` [PATCH v2 6/6] selftests/sgx: Add a bpftrace script for tracking allocation errors Jarkko Sakkinen
2022-08-31 20:09 ` Reinette Chatre
2022-09-01 22:24 ` Jarkko Sakkinen
2022-08-31 17:43 ` [PATCH v2 0/6] x86/sgx: A collection of tests and fixes Dave Hansen
2022-08-31 18:11 ` Jarkko Sakkinen
2022-08-31 18:24 ` Dave Hansen
2022-08-31 18:47 ` Jarkko Sakkinen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=d2b76530-82a2-6ac1-32ea-696e653d767d@intel.com \
--to=reinette.chatre@intel.com \
--cc=dave.hansen@linux.intel.com \
--cc=haitao.huang@linux.intel.com \
--cc=jarkko@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=linux-sgx@vger.kernel.org \
--cc=pmenzel@molgen.mpg.de \
--cc=shuah@kernel.org \
--cc=vijay.dhanraj@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).