diff --git a/README.md b/README.md index b18e1374..ea4066fe 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,7 @@ A few tests are executed by running the SBSA ACS Linux application which in turn The tests can also be executed in a Bare-metal environment. The initialization of the Bare-metal environment is specific to the environment and is out of scope of this document. ## Release details - - Code Quality: REL v7.1.2 + - Code Quality: REL v7.1.3 - The tests are written for version 7.1 of the SBSA specification. - For complete coverage of the SBSA rules, availability of an Exerciser is required for Exerciser tests to be run during verficiation at Pre-Silicon level. - For complete coverage, both SBSA and BSA ACS should be run. @@ -28,7 +28,7 @@ The tests can also be executed in a Bare-metal environment. The initialization o - The tests can be run at both the Pre-Silicon and Silicon level. - The compliance suite is not a substitute for design verification. - To review the SBSA ACS logs, Arm licensees can contact Arm directly through their partner managers. - - To know about the SBSA rules not implemented in this release, see [Test Scenario Document](docs/Arm_SBSA_Architecture_Compliance_Test_Scenario.pdf). + - To know about the SBSA rules not implemented in this release, see [Test Scenario Document](docs/arm_sbsa_architecture_compliance_test_scenario.pdf). ## GitHub branch @@ -36,12 +36,12 @@ The tests can also be executed in a Bare-metal environment. The initialization o - To get the latest version of the code with bug fixes and new features, use the master branch. ## Additional reading - - For information about the implementable SBSA rules test algorithm and for unimplemented SBSA rules, see the [Test Scenario Document](docs/Arm_SBSA_Architecture_Compliance_Test_Scenario.pdf). - - For information on test category(UEFI, Linux, Bare-metal) and applicable systems(SR,Pre-Silicon), see [Test Checklist](docs/Arm_SBSA_testcase-checklist.rst) - - For details on the design of the SBSA ACS, see the [Arm SBSA Validation Methodology Document](docs/Arm_SBSA_Architecture_Compliance_Validation_Methodology.pdf). - - For details on the SBSA ACS UEFI Shell Application, Linux Application and PMU Linux Application see the [Arm SBSA ACS User Guide](docs/Arm_SBSA_Architecture_Compliance_User_Guide.pdf). + - For information about the implementable SBSA rules test algorithm and for unimplemented SBSA rules, see the [arm SBSA Test Scenario Document](docs/arm_sbsa_architecture_compliance_test_scenario.pdf). + - For information on test category(UEFI, Linux, Bare-metal) and applicable systems(SR,Pre-Silicon), see [arm SBSA Test Checklist Document](docs/arm_sbsa_testcase_checklist.rst) + - For details on the design of the SBSA ACS, see the [arm SBSA Validation Methodology Document](docs/arm_sbsa_architecture_compliance_validation_methodology.pdf). + - For details on the SBSA ACS UEFI Shell Application, Linux Application and PMU Linux Application see the [arm SBSA User Guide Document](docs/arm_sbsa_architecture_compliance_user_guide.pdf). - For details on the SBSA ACS Bare-metal support, see the - - [Arm SBSA ACS Bare-metal User Guide](docs/Arm_SBSA_ACS_Bare-metal_User_Guide.pdf). + - [arm SBSA Bare-metal User Guide Document](docs/arm_sbsa_architecture_compliance_bare-metal_user_guide.pdf). - [Bare-metal Code](platform/pal_baremetal/).
Note: The Bare-metal PCIe enumeration code provided as part of the SBSA ACS should be used and should not be replaced. This code is vital in analyzing of the test result. @@ -52,28 +52,34 @@ Exerciser is a client device wrapped up by PCIe Endpoint. This device is created Note: To run the exerciser tests on a UEFI Based platform with Exerciser, the Exerciser PAL API's need to be implemented. For details on the reference Exerciser implementation and support, see the [Exerciser.md](docs/PCIe_Exerciser/Exerciser.md) and [Exerciser_API_porting_guide.md](docs/PCIe_Exerciser/Exerciser_API_porting_guide.md) ## SBSA ACS Linux kernel module -To enable the export of a few kernel APIs that are necessary for PCIe and IOMMU tests, Linux kernel module and a kernel patch file are required. These files are available at [linux-acs](https://gitlab.arm.com/linux-arm/linux-acs). +To enable the export of a few kernel APIs that are necessary for PCIe and SMMU tests, Linux kernel module and a kernel patch file are required. These files are available at [linux-acs](https://gitlab.arm.com/linux-arm/linux-acs). ## Target platforms Any AARCH64 Enterprise Platform that boots UEFI and Linux OS. + ## ACS build steps - UEFI Shell application +This section details the steps to build standalone SBSA UEFI application and also to build full SBSA image, which includes UEFI, Linux and PMU tests. + ### Prebuilt images -Prebuilt images for v23.07_REL7.1.2 release is available in the prebuilt_images folder of the master branch. The prebuilt images of previous release are present in [release branch](https://github.com/ARM-software/sbsa-acs/tree/release/prebuilt_images). You can choose to use this images or build your own image by following the steps below. If you choose to use the prebuilt image, jump to the test suite execution section below for details on how to run the application. +For each release prebuilt images are available in the prebuilt_images folder of the master branch. +You can choose to use these images or build your own image by following the steps below. +If you choose to use the prebuilt image, jump to the test suite execution section below for details on how to run the application. + ### Prerequisites Before starting the build, ensure that the following requirements are met. - Any mainstream Linux based OS distribution running on a x86 or AArch64 machine. -- Install GCC-ARM 10.3 or later toolchain for Linux from [here](https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-a/downloads). +- Install GCC-ARM 10.3 [toolchain](https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-a/downloads). - Install the build prerequisite packages to build EDK2. Note: The details of the packages are beyond the scope of this document. ### 1. Build Steps -1. git clone the edk2-stable202208 tag of EDK2 tree -> git clone --recursive --branch edk2-stable202208 https://github.com/tianocore/edk2 +1. git clone the edk2-stable202302 tag of EDK2 tree +> git clone --recursive --branch edk2-stable202302 https://github.com/tianocore/edk2 2. git clone the EDK2 port of libc > git clone https://github.com/tianocore/edk2-libc edk2/edk2-libc 3. git clone sbsa-acs @@ -127,13 +133,13 @@ These steps assume that the test suite is invoked through the ACS UEFI shell app ### 3.1 On Silicon On a system where a USB port is available and functional, perform the following steps: -1. Copy 'Sbsa.efi' to a USB Flash drive. +1. Copy 'Sbsa.efi' to a USB Flash drive. Path for 'Sbsa.efi' is present in step 2. 2. Plug in the USB Flash drive to one of the functional USB ports on the system. 3. Boot the system to UEFI shell. 4. To determine the file system number of the plugged in USB drive, execute 'map -r' command. 5. Type 'fsx' where 'x' is replaced by the number determined in step 4. 6. To start the compliance tests, run the executable Sbsa.efi with the appropriate parameters. - For details on the parameters, refer to [SBSA ACS User Guide](docs/Arm_SBSA_Architecture_Compliance_User_Guide.pdf) + For details on the parameters, refer to [arm SBSA User Guide Document](docs/arm_sbsa_architecture_compliance_user_guide.pdf) > shell> Sbsa.efi 7. Copy the UART console output to a log file for analysis and certification. @@ -154,7 +160,7 @@ On an emulation environment with secondary storage, perform the following steps: 4. To determine the file system number of the secondary storage, execute 'map -r' command. 5. Type 'fsx' where 'x' is replaced by the number determined in step 4. 6. To start the compliance tests, run the executable Sbsa.efi with the appropriate parameters. - For details on the parameters, see the [SBSA ACS User Guide](docs/Arm_SBSA_Architecture_Compliance_User_Guide.pdf) + For details on the parameters, see the [arm SBSA User Guide Document](docs/arm_sbsa_architecture_compliance_user_guide.pdf) > shell> Sbsa.efi 7. Copy the UART console output to a log file for analysis and certification. @@ -166,14 +172,14 @@ On an emulation platform where secondary storage is not available, perform the f 2. Build UEFI image including the UEFI Shell. 3. Boot the system to UEFI shell. 4. Run the executable 'Sbsa.efi' to start the compliance tests. - For details about the parameters, see the [SBSA ACS User Guide](docs/Arm_SBSA_Architecture_Compliance_User_Guide.pdf). + For details about the parameters, see the [arm SBSA User Guide Document](docs/arm_sbsa_architecture_compliance_user_guide.pdf). > shell> Sbsa.efi 5. Copy the UART console output to a log file for analysis and certification. ## ACS build steps - Linux application -Certain Peripheral, PCIe and Memory map tests require Linux operating system.This chapter provides information on building and executing these tests from the Linux application. +Certain PCIe and SMMU tests require Linux operating system.This chapter provides information on building and executing these tests from the Linux application. ### 1. Build steps and environment setup This section lists the porting and build steps for the kernel module. @@ -181,22 +187,22 @@ The patch for the kernel tree and the Linux PAL are hosted separately on [linux- ### 1.1 Building the kernel module #### Prerequisites -- Linux kernel source version 5.11, 5.13, 5.15, 6.0. -- Linaro GCC tool chain 10.3 or above. +- Linux kernel source version 5.11, 5.13, 5.15, 6.0, 6.4 +- Install GCC-ARM 10.3 [toolchain](https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-a/downloads). - Build environment for AArch64 Linux kernel.
NOTE:
-- Linux version 6.0 is recommened version. -- GCC 10.3 is recommended toolchain. +- Linux version 6.4 is recommened version. +- GCC 10.3 is recommended toolchain #### Porting steps for Linux kernel 1. git clone https://gitlab.arm.com/linux-arm/linux-acs sbsa-acs-drv 2. git clone https://github.com/ARM-software/sbsa-acs.git sbsa-acs -3. git clone https://github.com/torvalds/linux.git -b v6.0 +3. git clone https://github.com/torvalds/linux.git -b v6.4 4. export CROSS_COMPILE= pointing to /bin/aarch64-linux-gnu- -5. git apply /sbsa-acs-drv/kernel/src/0001-BSA-ACS-Linux-6.0.patch to your kernel source tree. +5. git apply /sbsa-acs-drv/kernel/src/0001-BSA-ACS-Linux-6.4.patch to your kernel source tree. 6. make ARCH=arm64 defconfig && make -j $(nproc) ARCH=arm64 -NOTE: The steps mentions Linux version 6.0, as it is latest version which is verified at ACS end. +NOTE: The steps mentions Linux version 6.4, as it is latest version which is verified at ACS end. #### 1.2 Build steps for SBSA kernel module 1. cd /sbsa-acs-drv/files @@ -224,7 +230,7 @@ shell> insmod sbsa_acs.ko ```sh shell> ./sbsa ``` - - For information on the SBSA Linux application parameters, see the [SBSA ACS User Guide](docs/Arm_SBSA_Architecture_Compliance_User_Guide.pdf). + - For information on the SBSA Linux application parameters, see the [User Guide](docs/arm_sbsa_architecture_compliance_user_guide.pdf). ## ACS build steps - Bare-metal abstraction @@ -235,30 +241,31 @@ To execute the Bare-metal code from UEFI Shell, checkout to [bare-metal](https:/ For details on generating the binaries to run on Bare-metal environment, refer [README.md](platform/pal_baremetal/README.md) ## Security implication -Arm Enterprise ACS test suite may run at higher privilege level. An attacker may utilize these tests as a means to elevate privilege which can potentially reveal the platform security assets. To prevent the leakage of secure information, it is strongly recommended that the ACS test suite is run only on development platforms. If it is run on production systems, the system should be scrubbed after running the test suite. +SBSA ACS test suite may run at higher privilege level. An attacker may utilize these tests as a means to elevate privilege which can potentially reveal the platform security assets. To prevent the leakage of secure information, it is strongly recommended that the ACS test suite is run only on development platforms. If it is run on production systems, the system should be scrubbed after running the test suite. ## Limitations Validating the compliance of certain PCIe rules defined in the SBSA specification requires the PCIe end-point to generate specific stimulus during the runtime of the test. Examples of such stimulus are P2P, PASID, ATC, etc. The tests that requires these stimuli are grouped together in the exerciser module. The exerciser layer is an abstraction layer that enables the integration of hardware capable of generating such stimuli to the test framework. The details of the hardware or Verification IP which enable these exerciser tests are platform specific and are beyond the scope of this document. -### SBSA Level 7 tests dependencies - - MPAM test will require EL3 firmware to enable access to MPAM registers from lower EL's. - If arm trusted firmware is used as EL3 fimrware, enable ENABLE_MPAM_FOR_LOWER_ELS=1 in tf build +### SBSA Tests dependencies + - MPAM tests will require EL3 firmware to enable access to MPAM registers from lower EL's. + If arm trusted firmware is used as EL3 fimrware, enable ENABLE_MPAM_FOR_LOWER_ELS=1 during arm TF build. + If the above flags are not enabled, MPAM tests can lead to exception at EL3. - RAS test will require EL3 firmware to enable access to RAS registers from lower EL's and forward RAS related exceptions to lower EL's. - If arm trusted firmware is used as EL3 fimrware, enable EL3_EXCEPTION_HANDLING=1 RAS_EXTENSION=1 HANDLE_EA_EL3_FIRST=1 RAS_TRAP_LOWER_EL_ERR_ACCESS=0 in tf build - - If the above flags are not enabled, MPAM and RAS test can lead to exception at EL3. - - MPAM test will require system to implement MPAM, SRAT, HMAT, PPTT tables. - - RAS test will require system to implement AEST, RAS2, SRAT, HMAT, PPTT tables. - - PMU test will require system to implement APMT table. - - Entrophy rule will require ACS to build with STS package + If arm trusted firmware is used as EL3 fimrware, enable EL3_EXCEPTION_HANDLING=1 RAS_EXTENSION=1 HANDLE_EA_EL3_FIRST=1 RAS_TRAP_LOWER_EL_ERR_ACCESS=0 during arm TF build + If the above flags are not enabled, RAS tests can lead to exception at EL3. + - MPAM test have dependency on MPAM, SRAT, HMAT, PPTT tables. + - RAS test have dependency on AEST, RAS2, SRAT, HMAT, PPTT tables. + - PMU test have dependency on APMT table. + - Entrophy rule will require ACS to build with NIST-STS package -**Note:** To build the ACS with NIST Statistical Test Suite, see the [SBSA_NIST_User_Guide](docs/Arm_SBSA_NIST_User_Guide.md) +**Note:** To build the ACS with NIST Statistical Test Suite, see the [arm SBSA_NIST_User_Guide Document](docs/arm_sbsa_nist_user_guide.md) |APIs |Description |Affected tests | |-----------------------------|------------------------------------------------------------------------------|------------------------| -|pal_pcie_p2p_support |Return 0 if the test system PCIe supports peer to peer transaction, else 1 |853, 854, 856, 911 | +|pal_pcie_dev_p2p_support |Return 0 if the test system PCIe supports peer to peer transaction, else 1 |856, 857 | |pal_pcie_is_cache_present |Return 1 if the test system supports PCIe address translation cache, else 0 |852 | -|pal_pcie_get_legacy_irq_map |Return 0 if system legacy irq map is filled, else 1 |812, 850 | +|pal_pcie_get_legacy_irq_map |Return 0 if system legacy irq map is filled, else 1 |850 | Below exerciser capabilities are required by exerciser test. - MSI-X interrupt generation. @@ -272,6 +279,7 @@ The details of the hardware or Verification IP which enable these exerciser test --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | SBSA Spec Version | ACS Coverage Mapping | SBSA ACS Version | SBSA Tag ID | BSA ACS Version | BSA Tag ID | Pre-Si Support | |-----------------------|:------------------------:|:--------------------:|:--------------------------:|:-------------------:|:-------------------:|:--------------------:| +| SBSA v7.1 | BSA ACS + SBSA ACS | v7.1.3 | v23.09_REL7.1.3 | v1.0.6 | v23.09_REL1.0.6 | Yes | | SBSA v7.1 | BSA ACS + SBSA ACS | v7.1.2 | v23.07_REL7.1.2 | v1.0.5 | v23.07_REL1.0.5 | Yes | | SBSA v7.1 | BSA ACS + SBSA ACS | v7.1.1 BETA-1 | v23.03_REL7.1.1_BETA-1 | v1.0.4 | v23.03_REL1.0.4 | Yes | | SBSA v7.1 | BSA ACS + SBSA ACS | v7.1.0 BETA-0 | v23.01_REL7.1.0_BETA-0 | v1.0.3 | v23.01_REL1.0.3 | Yes | diff --git a/baremetal_app/SbsaAvs.h b/baremetal_app/SbsaAvs.h index 3bf9440b..974fd2d4 100644 --- a/baremetal_app/SbsaAvs.h +++ b/baremetal_app/SbsaAvs.h @@ -22,7 +22,7 @@ #define SBSA_ACS_MAJOR_VER 7 #define SBSA_ACS_MINOR_VER 1 - #define SBSA_ACS_SUBMINOR_VER 2 + #define SBSA_ACS_SUBMINOR_VER 3 #define SBSA_MIN_LEVEL_SUPPORTED 3 #define SBSA_MAX_LEVEL_SUPPORTED 7 diff --git a/docs/Arm_SBSA_ACS_Bare-metal_User_Guide.pdf b/docs/Arm_SBSA_ACS_Bare-metal_User_Guide.pdf deleted file mode 100644 index c91555d6..00000000 Binary files a/docs/Arm_SBSA_ACS_Bare-metal_User_Guide.pdf and /dev/null differ diff --git a/docs/Arm_SBSA_Architecture_Compliance_User_Guide.pdf b/docs/Arm_SBSA_Architecture_Compliance_User_Guide.pdf deleted file mode 100644 index 208e893e..00000000 Binary files a/docs/Arm_SBSA_Architecture_Compliance_User_Guide.pdf and /dev/null differ diff --git a/docs/arm_sbsa_architecture_compliance_bare-metal_user_guide.pdf b/docs/arm_sbsa_architecture_compliance_bare-metal_user_guide.pdf new file mode 100644 index 00000000..116c87d2 Binary files /dev/null and b/docs/arm_sbsa_architecture_compliance_bare-metal_user_guide.pdf differ diff --git a/docs/Arm_SBSA_Architecture_Compliance_Test_Scenario.pdf b/docs/arm_sbsa_architecture_compliance_test_scenario.pdf similarity index 89% rename from docs/Arm_SBSA_Architecture_Compliance_Test_Scenario.pdf rename to docs/arm_sbsa_architecture_compliance_test_scenario.pdf index 37c4e276..d14845da 100644 Binary files a/docs/Arm_SBSA_Architecture_Compliance_Test_Scenario.pdf and b/docs/arm_sbsa_architecture_compliance_test_scenario.pdf differ diff --git a/docs/arm_sbsa_architecture_compliance_user_guide.pdf b/docs/arm_sbsa_architecture_compliance_user_guide.pdf new file mode 100644 index 00000000..c07665da Binary files /dev/null and b/docs/arm_sbsa_architecture_compliance_user_guide.pdf differ diff --git a/docs/Arm_SBSA_Architecture_Compliance_Validation_Methodology.pdf b/docs/arm_sbsa_architecture_compliance_validation_methodology.pdf similarity index 58% rename from docs/Arm_SBSA_Architecture_Compliance_Validation_Methodology.pdf rename to docs/arm_sbsa_architecture_compliance_validation_methodology.pdf index 09ac4036..bed8c756 100644 Binary files a/docs/Arm_SBSA_Architecture_Compliance_Validation_Methodology.pdf and b/docs/arm_sbsa_architecture_compliance_validation_methodology.pdf differ diff --git a/docs/Arm_SBSA_NIST_User_Guide.md b/docs/arm_sbsa_nist_user_guide.md similarity index 100% rename from docs/Arm_SBSA_NIST_User_Guide.md rename to docs/arm_sbsa_nist_user_guide.md diff --git a/docs/Arm_SBSA_testcase-checklist.rst b/docs/arm_sbsa_testcase_checklist.rst similarity index 99% rename from docs/Arm_SBSA_testcase-checklist.rst rename to docs/arm_sbsa_testcase_checklist.rst index a724a68b..f65c6a0f 100644 --- a/docs/Arm_SBSA_testcase-checklist.rst +++ b/docs/arm_sbsa_testcase_checklist.rst @@ -310,6 +310,6 @@ The below table provides the following details |PMU app|Latency events |L7 |PMU_EV_10 |Yes |No |No |Yes |No | +-------+--------------------------------------------+-----+----------------------------------------------------+----------------+----+----------+-----+-------------------+ -*For running tests on a bare-metal environment, integration of ACS with platform boot code is required. See `Bare-metal User Guide `_ +*For running tests on a bare-metal environment, integration of ACS with platform boot code is required. See `arm SBSA Bare-metal User Guide `_ diff --git a/linux_app/sbsa-acs-app/include/sbsa_app.h b/linux_app/sbsa-acs-app/include/sbsa_app.h index e0caf249..3b980d28 100644 --- a/linux_app/sbsa-acs-app/include/sbsa_app.h +++ b/linux_app/sbsa-acs-app/include/sbsa_app.h @@ -22,7 +22,7 @@ #define SBSA_APP_VERSION_MAJOR 7 #define SBSA_APP_VERSION_MINOR 1 -#define SBSA_APP_VERSION_SUBMINOR 2 +#define SBSA_APP_VERSION_SUBMINOR 3 #include "sbsa_drv_intf.h" diff --git a/platform/pal_baremetal/README.md b/platform/pal_baremetal/README.md index 1d7ab89b..38f20a76 100644 --- a/platform/pal_baremetal/README.md +++ b/platform/pal_baremetal/README.md @@ -23,7 +23,7 @@ The output library files will be generated at /build/lib/ Note: Any platform specific changes can be done by using TARGET_EMULATION macro defintion. The pal_baremetal reference code is located in [pal_baremetal](.). To customize the bare-metal code for different platforms, create a directory in [pal_baremetal](.) folder and copy the reference code from [source](src) folder and [RDN2](FVP/RDN2) folder to . -For more details on how to port the reference code to a specific platform and for further customisation please refer to the [User Guide](../../docs/Arm_SBSA_ACS_Bare-metal_User_Guide.pdf) +For more details on how to port the reference code to a specific platform and for further customisation please refer to the [User Guide](../../docs/arm_sbsa_architecture_compliance_bare-metal_user_guide.pdf) ----------------- diff --git a/uefi_app/SbsaAvs.h b/uefi_app/SbsaAvs.h index a9505b4f..d8f7592c 100644 --- a/uefi_app/SbsaAvs.h +++ b/uefi_app/SbsaAvs.h @@ -22,7 +22,7 @@ #define SBSA_ACS_MAJOR_VER 7 #define SBSA_ACS_MINOR_VER 1 - #define SBSA_ACS_SUBMINOR_VER 2 + #define SBSA_ACS_SUBMINOR_VER 3 #define G_SBSA_LEVEL 4 #define SBSA_MIN_LEVEL_SUPPORTED 3