fix!: introduce access api and VolatileBuf to safely interact with volatile ParamMemref buffers #715
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Licensed to the Apache Software Foundation (ASF) under one | |
| # or more contributor license agreements. See the NOTICE file | |
| # distributed with this work for additional information | |
| # regarding copyright ownership. The ASF licenses this file | |
| # to you under the Apache License, Version 2.0 (the | |
| # "License"); you may not use this file except in compliance | |
| # with the License. You may obtain a copy of the License at | |
| # | |
| # http://www.apache.org/licenses/LICENSE-2.0 | |
| # | |
| # Unless required by applicable law or agreed to in writing, | |
| # software distributed under the License is distributed on an | |
| # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | |
| # KIND, either express or implied. See the License for the | |
| # specific language governing permissions and limitations | |
| # under the License. | |
| name: CI | |
| on: [push, pull_request] | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| defaults: | |
| run: | |
| shell: bash | |
| jobs: | |
| # Run test on AMD64 host | |
| test-on-amd64-host: | |
| uses: ./.github/workflows/reuse_test.yml | |
| with: | |
| runs-on: ubuntu-latest | |
| container: ghcr.io/ivila/teaclave-trustzone-sdk-ci-runner:ubuntu-24.04 | |
| # Run test on ARM64 host | |
| test-on-arm64-host: | |
| uses: ./.github/workflows/reuse_test.yml | |
| with: | |
| runs-on: ubuntu-24.04-arm | |
| container: ghcr.io/ivila/teaclave-trustzone-sdk-ci-runner:ubuntu-24.04 | |
| # Run systest of optee_teec and build systest of optee_utee on ARM64 | |
| systest: | |
| runs-on: ubuntu-24.04-arm | |
| container: ghcr.io/ivila/teaclave-trustzone-sdk-ci-runner:ubuntu-24.04 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Prepare Environment | |
| run: | | |
| # Setup Rust and toolchains | |
| ./setup.sh | |
| source "$HOME/.cargo/env" | |
| # Build optee_os and optee_client for qemu_v8 | |
| ./build_optee_libraries.sh $HOME | |
| # Setup environment | |
| export OPTEE_DIR=$HOME | |
| source environment | |
| # Run systest | |
| export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$OPTEE_DIR/optee_client/export_arm64/usr/lib | |
| (cd optee-teec && cargo run -p systest) | |
| (cd optee-utee && cargo build -p systest) | |
| # Test build no-std examples on dev docker container | |
| test-nostd-build-on-dev-docker: | |
| runs-on: ubuntu-latest | |
| container: | |
| image: teaclave/teaclave-trustzone-emulator-nostd-expand-memory:latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup environment | |
| run: | | |
| # Run entrypoint.sh to set up the bash profile | |
| /entrypoint.sh true | |
| - name: Build no-std and common examples | |
| shell: bash -l {0} # Use login shell to load the profile | |
| run: | | |
| make | |
| # Test build std examples on dev docker container | |
| test-std-build-on-dev-docker: | |
| runs-on: ubuntu-latest | |
| container: | |
| image: teaclave/teaclave-trustzone-emulator-std-expand-memory:latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup environment | |
| run: | | |
| # Run entrypoint.sh to set up the bash profile | |
| /entrypoint.sh true | |
| - name: Build no-std and common examples | |
| shell: bash -l {0} # Use login shell to load the profile | |
| run: | | |
| ln -s $RUST_STD_DIR rust | |
| make std-examples | |
| # Test cargo-optee build no-std examples - aarch64 | |
| test-cargo-optee-nostd-aarch64: | |
| runs-on: ubuntu-latest | |
| container: | |
| image: teaclave/teaclave-trustzone-emulator-nostd-expand-memory:latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup environment | |
| run: | | |
| # Run entrypoint.sh to set up the bash profile | |
| /entrypoint.sh true | |
| # Install jq for JSON parsing | |
| apt-get update && apt-get install -y jq | |
| - name: Test cargo-optee no-std build (aarch64) | |
| shell: bash -l {0} # Use login shell to load the profile | |
| run: | | |
| # Build using cargo-optee tool with default aarch64 settings | |
| ./ci/build.sh | |
| # Test cargo-optee build no-std examples - arm32 | |
| test-cargo-optee-nostd-arm32: | |
| runs-on: ubuntu-latest | |
| container: | |
| image: teaclave/teaclave-trustzone-emulator-nostd-expand-memory:latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup environment | |
| run: | | |
| # Run entrypoint.sh to set up the bash profile | |
| /entrypoint.sh true | |
| # Install jq for JSON parsing | |
| apt-get update && apt-get install -y jq | |
| - name: Test cargo-optee no-std build (arm32) | |
| shell: bash -l {0} # Use login shell to load the profile | |
| run: | | |
| # Switch to ARM32 configuration and build | |
| # Note: Explicit environment reload needed for GitHub Actions | |
| # (wrapper function in .bashrc not working for non-interactive shells: docker exec cmd=[...]) | |
| # We can fix this by updating entrypoint.sh to make ~/.profile source ~/.bashrc | |
| switch_config --ta no-std/arm32 && \ | |
| switch_config --host arm32 && \ | |
| source ${TEACLAVE_TOOLCHAIN_BASE}/environment && \ | |
| ./ci/build.sh --ta arm --host arm | |
| # Test cargo-optee build std examples - aarch64 | |
| test-cargo-optee-std-aarch64: | |
| runs-on: ubuntu-latest | |
| container: | |
| image: teaclave/teaclave-trustzone-emulator-std-expand-memory:latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup environment | |
| run: | | |
| # Run entrypoint.sh to set up the bash profile | |
| /entrypoint.sh true | |
| # Install jq for JSON parsing | |
| apt-get update && apt-get install -y jq | |
| - name: Test cargo-optee std build (aarch64) | |
| shell: bash -l {0} # Use login shell to load the profile | |
| run: | | |
| # Link rust directory for std support | |
| ln -s $RUST_STD_DIR rust | |
| # Build using cargo-optee tool with default aarch64 std settings | |
| ./ci/build.sh --std | |
| # Test cargo-optee build std examples - arm32 | |
| test-cargo-optee-std-arm32: | |
| runs-on: ubuntu-latest | |
| container: | |
| image: teaclave/teaclave-trustzone-emulator-std-expand-memory:latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup environment | |
| run: | | |
| # Run entrypoint.sh to set up the bash profile | |
| /entrypoint.sh true | |
| # Install jq for JSON parsing | |
| apt-get update && apt-get install -y jq | |
| - name: Test cargo-optee std build (arm32) | |
| shell: bash -l {0} # Use login shell to load the profile | |
| run: | | |
| # Link rust directory for std support | |
| ln -s $RUST_STD_DIR rust | |
| # Switch to ARM32 std configuration and build | |
| # Note: Explicit environment reload needed for GitHub Actions | |
| # (wrapper function in .bashrc not working for non-interactive shells: docker exec cmd=[...]) | |
| # We can fix this by updating entrypoint.sh to make ~/.profile source ~/.bashrc | |
| switch_config --ta std/arm32 && \ | |
| switch_config --host arm32 && \ | |
| source ${TEACLAVE_TOOLCHAIN_BASE}/environment && \ | |
| ./ci/build.sh --ta arm --host arm --std | |
| license: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Check License Header | |
| uses: apache/skywalking-eyes/header@v0.7.0 | |
| with: | |
| config: .licenserc.yaml | |
| mode: check | |
| token: "" # don't post PR comments from check step |