From e873af7b508f167c4d8e5e37f3cefb119ef15b8e Mon Sep 17 00:00:00 2001 From: Gowtham Suresh Kumar Date: Thu, 1 Jun 2023 16:34:15 +0100 Subject: [PATCH 1/2] [cassini-bsp, cassini-tests] Fix parsec RSA key generation failure The RSA key generation operation is very slow and this causes the parsec-tool to timeout when the cli tests are executed. The parsec cli test script can use a preset PARSEC_TOOL variable so this patch sets this variable with sufficient timeout to complete the tests. Signed-off-by: Gowtham Suresh Kumar --- .../0001-cassini-bsp-Enable-parse-service-to-use-TS.patch | 3 ++- .../parsec-simple-e2e-tests/parsec-simple-e2e-tests.bats | 4 +++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/meta-cassini-bsp/meta-security/meta-parsec/recipes-parsec/parsec-service/files/0001-cassini-bsp-Enable-parse-service-to-use-TS.patch b/meta-cassini-bsp/meta-security/meta-parsec/recipes-parsec/parsec-service/files/0001-cassini-bsp-Enable-parse-service-to-use-TS.patch index ca12801..7fd3bc1 100644 --- a/meta-cassini-bsp/meta-security/meta-parsec/recipes-parsec/parsec-service/files/0001-cassini-bsp-Enable-parse-service-to-use-TS.patch +++ b/meta-cassini-bsp/meta-security/meta-parsec/recipes-parsec/parsec-service/files/0001-cassini-bsp-Enable-parse-service-to-use-TS.patch @@ -7,6 +7,7 @@ Update the default `config.toml` to use trusted service provider for parsec-service. Signed-off-by: Vikas Katariya +Signed-off-by: Gowtham Suresh Kumar --- config.toml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) @@ -38,7 +39,7 @@ index 9532f32..d65bdbe 100644 # (Required) Timeout of the read and write operations on the IPC channel. After the # timeout expires, the connection is dropped. -timeout = 200 # in milliseconds -+timeout = 600 # in milliseconds ++timeout = 3600000 # in milliseconds # Specify the Unix Domain Socket path. The path is fixed and should always be the default one for # clients to connect. However, it is useful to change it for tests. diff --git a/meta-cassini-tests/recipes-tests/runtime-integration-tests/parsec-simple-e2e-tests/parsec-simple-e2e-tests.bats b/meta-cassini-tests/recipes-tests/runtime-integration-tests/parsec-simple-e2e-tests/parsec-simple-e2e-tests.bats index b4cb1c9..d82ce15 100644 --- a/meta-cassini-tests/recipes-tests/runtime-integration-tests/parsec-simple-e2e-tests/parsec-simple-e2e-tests.bats +++ b/meta-cassini-tests/recipes-tests/runtime-integration-tests/parsec-simple-e2e-tests/parsec-simple-e2e-tests.bats @@ -18,6 +18,7 @@ fi export TEST_LOG_FILE="${TEST_LOG_DIR}/parsec-simple-e2e-tests.log" export TEST_STDERR_FILE="${TEST_LOG_DIR}/ps-stderr.log" export TEST_RUN_FILE="${TEST_RUNTIME_DIR}/parsec-simple-e2e-tests.pgid" +export PARSEC_TOOL="/usr/bin/parsec-tool -t 3600" export TEST_CLEAN_ENV="${PS_TEST_CLEAN_ENV:=1}" @@ -74,7 +75,8 @@ clean_test_environment() { } @test 'simple end to end tests for PARSEC service' { - + + # PARSEC_TOOL is used by parsec-cli-tests.sh internally _run /usr/bin/parsec-cli-tests.sh if [ "${status}" -ne 0 ]; then log "FAIL" -- GitLab From 2b5e169abf6ed3ac09885a935f105e91696c464e Mon Sep 17 00:00:00 2001 From: Gowtham Suresh Kumar Date: Wed, 7 Jun 2023 10:17:12 +0100 Subject: [PATCH 2/2] ci: Increase timeouts for parsec cli tests The parsec cli tests include RSA key generation which is very slow. The test action and job timeouts are increased to accommodate this. Signed-off-by: Gowtham Suresh Kumar --- .gitlab/lava/corstone1000-mps3/ptest.yml.j2 | 6 +++--- .gitlab/lava/n1sdp/ptest.yml.j2 | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.gitlab/lava/corstone1000-mps3/ptest.yml.j2 b/.gitlab/lava/corstone1000-mps3/ptest.yml.j2 index 0799ca4..fcf2400 100644 --- a/.gitlab/lava/corstone1000-mps3/ptest.yml.j2 +++ b/.gitlab/lava/corstone1000-mps3/ptest.yml.j2 @@ -11,7 +11,7 @@ job_name: {{ CI_JOB_NAME }} timeouts: job: {% if should_run %} - minutes: 600 + minutes: 700 {% else %} minutes: 270 {% endif %} @@ -158,7 +158,7 @@ actions: namespace: secondary_media timeout: {% if should_run %} - minutes: 360 + minutes: 460 {% else %} minutes: 15 {% endif %} @@ -180,7 +180,7 @@ actions: {% if should_run %} - lava-test-case cassini-integration-tests --shell "sudo -HEnu test ptest-runner -t 3600 psa-arch-tests" - lava-test-case cassini-integration-tests --shell "sudo -HEnu test ptest-runner -t 10800 optee-xtests" - - lava-test-case cassini-integration-tests --shell "sudo -HEnu test ptest-runner -t 1800 parsec-simple-e2e-tests" + - lava-test-case cassini-integration-tests --shell "sudo -HEnu test ptest-runner -t 5400 parsec-simple-e2e-tests" {% endif %} - jfrog-cli config add artifactory-aws --interactive=false --artifactory-url={{ ARTIFACTORY_AWS_URL }} --user={{ ARTIFACTORY_USER }} --password={{ ARTIFACTORY_PASS }}; - | diff --git a/.gitlab/lava/n1sdp/ptest.yml.j2 b/.gitlab/lava/n1sdp/ptest.yml.j2 index f5c016d..2e9ae9b 100644 --- a/.gitlab/lava/n1sdp/ptest.yml.j2 +++ b/.gitlab/lava/n1sdp/ptest.yml.j2 @@ -11,7 +11,7 @@ job_name: {{ CI_JOB_NAME }} timeouts: job: {% if should_run %} - minutes: 450 + minutes: 550 {% else %} minutes: 80 {% endif %} @@ -193,7 +193,7 @@ actions: namespace: secondary_media timeout: {% if should_run %} - minutes: 360 + minutes: 460 {% else %} minutes: 15 {% endif %} @@ -215,7 +215,7 @@ actions: {% if should_run %} - lava-test-case cassini-integration-tests --shell "sudo -HEnu test ptest-runner -t 3600 psa-arch-tests" - lava-test-case cassini-integration-tests --shell "sudo -HEnu test ptest-runner -t 10800 optee-xtests" - - lava-test-case cassini-integration-tests --shell "sudo -HEnu test ptest-runner -t 1800 parsec-simple-e2e-tests" + - lava-test-case cassini-integration-tests --shell "sudo -HEnu test ptest-runner -t 5400 parsec-simple-e2e-tests" {% endif %} - jfrog-cli config add artifactory-aws --interactive=false --artifactory-url={{ ARTIFACTORY_AWS_URL }} --user={{ ARTIFACTORY_USER }} --password={{ ARTIFACTORY_PASS }}; - | -- GitLab