Balint Dobszay | 1bf41f5 | 2022-05-30 12:56:38 +0200 | [diff] [blame] | 1 | FVP_USE_BASE_PLAT ?= y |
| 2 | FVP_VIRTFS_ENABLE ?= y |
| 3 | FVP_VIRTFS_AUTOMOUNT ?= y |
| 4 | MEASURED_BOOT ?= y |
| 5 | MEASURED_BOOT_FTPM ?= n |
| 6 | TS_SMM_GATEWAY ?= y |
Imre Kis | cef118b | 2023-01-11 18:01:46 +0100 | [diff] [blame] | 7 | TS_UEFI_TESTS ?= n |
Balint Dobszay | a59865b | 2022-09-13 16:47:27 +0200 | [diff] [blame] | 8 | # Supported values: embedded, fip |
| 9 | SP_PACKAGING_METHOD ?= embedded |
Imre Kis | cef118b | 2023-01-11 18:01:46 +0100 | [diff] [blame] | 10 | SPMC_TESTS ?= n |
Balint Dobszay | 1bf41f5 | 2022-05-30 12:56:38 +0200 | [diff] [blame] | 11 | |
Balint Dobszay | 6c7dfb2 | 2023-03-16 14:48:33 +0100 | [diff] [blame] | 12 | # Enable the "HArdware Volatile Entropy Gathering and Expansion" daemon to |
| 13 | # overcome low-entropy conditions in the FVP |
| 14 | BR2_PACKAGE_HAVEGED ?= y |
Imre Kis | d545be1 | 2023-04-05 13:43:53 +0200 | [diff] [blame] | 15 | TS_RPC_UUID ?= n |
Balint Dobszay | 6c7dfb2 | 2023-03-16 14:48:33 +0100 | [diff] [blame] | 16 | |
Imre Kis | 874a2dd | 2023-01-09 17:01:22 +0100 | [diff] [blame] | 17 | # TS SP configurations |
| 18 | DEFAULT_SP_CONFIG ?= default-opteesp |
| 19 | SP_BLOCK_STORAGE_CONFIG ?= $(DEFAULT_SP_CONFIG) |
| 20 | SP_PSA_ITS_CONFIG ?= $(DEFAULT_SP_CONFIG) |
| 21 | SP_PSA_PS_CONFIG ?= $(DEFAULT_SP_CONFIG) |
| 22 | SP_PSA_CRYPTO_CONFIG ?= $(DEFAULT_SP_CONFIG) |
| 23 | SP_PSA_ATTESTATION_CONFIG ?= $(DEFAULT_SP_CONFIG) |
| 24 | SP_SMM_GATEWAY_CONFIG ?= $(DEFAULT_SP_CONFIG) |
| 25 | |
Balint Dobszay | 1bf41f5 | 2022-05-30 12:56:38 +0200 | [diff] [blame] | 26 | TF_A_FLAGS ?= \ |
| 27 | BL32=$(OPTEE_OS_PAGER_V2_BIN) \ |
| 28 | BL33=$(EDK2_BIN) \ |
| 29 | PLAT=fvp \ |
| 30 | SPD=spmd \ |
| 31 | SPMD_SPM_AT_SEL2=0 \ |
Balint Dobszay | db9b8f0 | 2022-09-01 11:20:23 +0200 | [diff] [blame] | 32 | ARM_SPMC_MANIFEST_DTS=$(ROOT)/build/fvp/spmc_manifest.dts \ |
| 33 | $(TF_A_FIP_SP_FLAGS) |
Balint Dobszay | 1bf41f5 | 2022-05-30 12:56:38 +0200 | [diff] [blame] | 34 | |
Balint Dobszay | 3730e01 | 2023-06-02 11:40:41 +0200 | [diff] [blame^] | 35 | LINUX_DEFCONFIG_COMMON_FILES ?= $(CURDIR)/kconfigs/fvp_trusted-services.conf |
| 36 | |
Balint Dobszay | 1bf41f5 | 2022-05-30 12:56:38 +0200 | [diff] [blame] | 37 | include fvp.mk |
| 38 | include trusted-services.mk |
| 39 | |
Imre Kis | efd2ece | 2023-04-05 13:35:28 +0200 | [diff] [blame] | 40 | # The macros used in bl2_sp_list.dts and spmc_manifest.dts has to be passed to |
| 41 | # TF-A because it handles the preprocessing of these files. |
| 42 | define add-dtc-define |
| 43 | DTC_CPPFLAGS+=-D$1=$(subst y,1,$(subst n,0,$($1))) |
| 44 | endef |
| 45 | |
| 46 | ifeq ($(SP_PACKAGING_METHOD),fip) |
| 47 | $(eval $(call add-dtc-define,SPMC_TESTS)) |
| 48 | $(eval $(call add-dtc-define,TS_SMM_GATEWAY)) |
Imre Kis | d545be1 | 2023-04-05 13:43:53 +0200 | [diff] [blame] | 49 | $(eval $(call add-dtc-define,TS_RPC_UUID)) |
Imre Kis | efd2ece | 2023-04-05 13:35:28 +0200 | [diff] [blame] | 50 | |
| 51 | TF_A_EXPORTS += DTC_CPPFLAGS="$(DTC_CPPFLAGS)" |
| 52 | endif |
| 53 | |
Balint Dobszay | 1bf41f5 | 2022-05-30 12:56:38 +0200 | [diff] [blame] | 54 | OPTEE_OS_COMMON_EXTRA_FLAGS += \ |
| 55 | CFG_SECURE_PARTITION=y \ |
| 56 | CFG_CORE_SEL1_SPMC=y \ |
| 57 | CFG_CORE_HEAP_SIZE=131072 \ |
| 58 | CFG_DT=y \ |
| 59 | CFG_MAP_EXT_DT_SECURE=y |
| 60 | |
Jelle Sels | 3a937c5 | 2023-02-01 09:25:52 +0100 | [diff] [blame] | 61 | |
| 62 | ifeq ($(TS_RPC_UUID),y) |
| 63 | TS_RPC_UUID="bdcd76d7-825e-4751-963b-86d4f84943ac" |
| 64 | SP_BLOCK_STORAGE_EXTRA_FLAGS +=-DTS_RPC_UUID=$(TS_RPC_UUID) |
| 65 | SP_PSA_ITS_EXTRA_FLAGS +=-DTS_RPC_UUID=$(TS_RPC_UUID) |
| 66 | SP_PSA_PS_EXTRA_FLAGS +=-DTS_RPC_UUID=$(TS_RPC_UUID) |
| 67 | SP_PSA_CRYPTO_EXTRA_FLAGS +=-DTS_RPC_UUID=$(TS_RPC_UUID) |
| 68 | SP_PSA_ATTESTATION_EXTRA_FLAGS +=-DTS_RPC_UUID=$(TS_RPC_UUID) |
| 69 | SP_SMM_GATEWAY_EXTRA_FLAGS +=-DTS_RPC_UUID=$(TS_RPC_UUID) |
| 70 | endif |
| 71 | |
Balint Dobszay | 1bf41f5 | 2022-05-30 12:56:38 +0200 | [diff] [blame] | 72 | # The boot order of the SPs is determined by the order of calls here. This is |
| 73 | # due to the SPMC not (yet) supporting the boot order field of the SP manifest. |
Imre Kis | 0dbd3df | 2023-04-05 13:31:22 +0200 | [diff] [blame] | 74 | ifeq ($(SPMC_TESTS),n) |
| 75 | # PSA SPs |
Imre Kis | 874a2dd | 2023-01-09 17:01:22 +0100 | [diff] [blame] | 76 | $(eval $(call build-sp,block-storage,config/$(SP_BLOCK_STORAGE_CONFIG),63646e80-eb52-462f-ac4f-8cdf3987519c,$(SP_BLOCK_STORAGE_EXTRA_FLAGS))) |
| 77 | $(eval $(call build-sp,internal-trusted-storage,config/$(SP_PSA_ITS_CONFIG),dc1eef48-b17a-4ccf-ac8b-dfcff7711b14,$(SP_PSA_ITS_EXTRA_FLAGS))) |
| 78 | $(eval $(call build-sp,protected-storage,config/$(SP_PSA_PS_CONFIG),751bf801-3dde-4768-a514-0f10aeed1790,$(SP_PSA_PS_EXTRA_FLAGS))) |
| 79 | $(eval $(call build-sp,crypto,config/$(SP_PSA_CRYPTO_CONFIG),d9df52d5-16a2-4bb2-9aa4-d26d3b84e8c0,$(SP_PSA_CRYPTO_EXTRA_FLAGS))) |
Balint Dobszay | 1bf41f5 | 2022-05-30 12:56:38 +0200 | [diff] [blame] | 80 | ifeq ($(MEASURED_BOOT),y) |
Imre Kis | 874a2dd | 2023-01-09 17:01:22 +0100 | [diff] [blame] | 81 | $(eval $(call build-sp,attestation,config/$(SP_PSA_ATTESTATION_CONFIG),a1baf155-8876-4695-8f7c-54955e8db974,$(SP_PSA_ATTESTATION_EXTRA_FLAGS))) |
Balint Dobszay | 1bf41f5 | 2022-05-30 12:56:38 +0200 | [diff] [blame] | 82 | endif |
| 83 | ifeq ($(TS_SMM_GATEWAY),y) |
Imre Kis | 874a2dd | 2023-01-09 17:01:22 +0100 | [diff] [blame] | 84 | $(eval $(call build-sp,smm-gateway,config/$(SP_SMM_GATEWAY_CONFIG),ed32d533-99e6-4209-9cc0-2d72cdd998a7,$(SP_SMM_GATEWAY_EXTRA_FLAGS))) |
Balint Dobszay | 1bf41f5 | 2022-05-30 12:56:38 +0200 | [diff] [blame] | 85 | endif |
Imre Kis | 0dbd3df | 2023-04-05 13:31:22 +0200 | [diff] [blame] | 86 | else |
| 87 | # SPMC test SPs |
| 88 | OPTEE_OS_COMMON_EXTRA_FLAGS += CFG_SPMC_TESTS=y |
| 89 | $(eval $(call build-sp,spm-test1,opteesp,5c9edbc3-7b3a-4367-9f83-7c191ae86a37,$(SP_SPMC_TEST_EXTRA_FLAGS))) |
| 90 | $(eval $(call build-sp,spm-test2,opteesp,7817164c-c40c-4d1a-867a-9bb2278cf41a,$(SP_SPMC_TEST_EXTRA_FLAGS))) |
| 91 | $(eval $(call build-sp,spm-test3,opteesp,23eb0100-e32a-4497-9052-2f11e584afa6,$(SP_SPMC_TEST_EXTRA_FLAGS))) |
Imre Kis | d545be1 | 2023-04-05 13:43:53 +0200 | [diff] [blame] | 92 | ifeq ($(TS_RPC_UUID),y) |
Imre Kis | 0dbd3df | 2023-04-05 13:31:22 +0200 | [diff] [blame] | 93 | $(eval $(call build-sp,spm-test4,opteesp,423762ed-7772-406f-99d8-0c27da0abbf8,$(SP_SPMC_TEST_EXTRA_FLAGS))) |
| 94 | endif |
Imre Kis | d545be1 | 2023-04-05 13:43:53 +0200 | [diff] [blame] | 95 | endif |
Balint Dobszay | c0b8fdf | 2022-06-02 14:41:54 +0200 | [diff] [blame] | 96 | |
Imre Kis | 0dbd3df | 2023-04-05 13:31:22 +0200 | [diff] [blame] | 97 | # Linux user space applications |
| 98 | ifeq ($(SPMC_TESTS),n) |
Balint Dobszay | c0b8fdf | 2022-06-02 14:41:54 +0200 | [diff] [blame] | 99 | $(eval $(call build-ts-app,libts)) |
| 100 | $(eval $(call build-ts-app,ts-service-test)) |
| 101 | $(eval $(call build-ts-app,psa-api-test/internal_trusted_storage)) |
| 102 | $(eval $(call build-ts-app,psa-api-test/protected_storage)) |
| 103 | $(eval $(call build-ts-app,psa-api-test/crypto)) |
| 104 | ifeq ($(MEASURED_BOOT),y) |
| 105 | $(eval $(call build-ts-app,psa-api-test/initial_attestation)) |
| 106 | endif |
| 107 | ifeq ($(TS_UEFI_TESTS),y) |
| 108 | $(eval $(call build-ts-app,uefi-test)) |
| 109 | endif |
Jelle Sels | bb5a536 | 2022-07-18 17:07:05 +0200 | [diff] [blame] | 110 | endif |