1ifeq ($(CFG_NXP_SE05X),y) 2# Enable the crypto driver 3$(call force,CFG_CRYPTO_DRIVER,y) 4CFG_CRYPTO_DRIVER_DEBUG ?= 0 5 6# SE050 initialization 7# Enables the SCP03 key rotation 8CFG_CORE_SE05X_SCP03_PROVISION ?= n 9# Displays the SE050 device information on the console at boot (i.e. OEFID) 10CFG_CORE_SE05X_DISPLAY_INFO ?= y 11# Enables the SCP03 before the REE: notice that if SCP03_PROVISION is enabled, 12# it will also attempt to rotate the keys 13CFG_CORE_SE05X_SCP03_EARLY ?= y 14# Deletes all persistent storage from the SE050 at boot 15CFG_CORE_SE05X_INIT_NVM ?= n 16# Selects the default SCP03 keys based on the configured OEFID 17CFG_CORE_SE05X_OEFID ?= 0 18 19# I2C bus baudrate (depends on SoC) 20CFG_CORE_SE05X_BAUDRATE ?= 3400000 21# I2C bus [0..2] (depends on board) 22CFG_CORE_SE05X_I2C_BUS ?= 2 23 24# Extra stacks required to support the Plug and Trust external library 25ifeq ($(shell test $(CFG_STACK_THREAD_EXTRA) -lt 8192; echo $$?), 0) 26$(error Error: SE050 requires CFG_STACK_THREAD_EXTRA at least 8192) 27endif 28ifeq ($(shell test $(CFG_STACK_TMP_EXTRA) -lt 8192; echo $$?), 0) 29$(error Error: SE050 requires CFG_STACK_TMP_EXTRA at least 8192) 30endif 31 32# SE05X Unique Key Identifier 33CFG_NXP_SE05X_HUK_DRV ?= y 34 35# Random Number Generator 36CFG_NXP_SE05X_RNG_DRV ?= y 37ifeq ($(CFG_NXP_SE05X_RNG_DRV),y) 38$(call force,CFG_WITH_SOFTWARE_PRNG,n) 39endif 40 41se050-one-enabled = $(call cfg-one-enabled, \ 42 $(foreach v,$(1), CFG_NXP_SE05X_$(v)_DRV)) 43# Asymmetric ciphers 44CFG_NXP_SE05X_RSA_DRV ?= y 45CFG_NXP_SE05X_ECC_DRV ?= y 46$(call force,CFG_NXP_SE05X_ACIPHER_DRV,$(call se050-one-enabled,RSA ECC)) 47 48# Asymmetric driver 49ifeq ($(CFG_NXP_SE05X_ACIPHER_DRV),y) 50$(call force,CFG_CRYPTO_DRV_ACIPHER,y,Mandated by CFG_NXP_SE05X_ACIPHER_DRV) 51endif 52 53# Asymmetric ciphers configuration 54# - RSA 55ifeq ($(CFG_NXP_SE05X_RSA_DRV),y) 56$(call force,CFG_CRYPTO_DRV_RSA,y) 57CFG_CRYPTO_RSASSA_NA1 ?= y 58_CFG_CORE_LTC_RSA = n 59endif 60# - ECC 61ifeq ($(CFG_NXP_SE05X_ECC_DRV),y) 62$(call force,CFG_CRYPTO_DRV_ECC,y) 63endif 64 65# Symmetric ciphers 66CFG_NXP_SE05X_CTR_DRV ?= y 67$(call force,CFG_NXP_SE05X_CIPHER_DRV,$(call se050-one-enabled,CTR)) 68 69# Symmetric driver 70ifeq ($(CFG_NXP_SE05X_CIPHER_DRV),y) 71$(call force,CFG_CRYPTO_DRV_CIPHER,y,Mandated by CFG_NXP_SE05X_CIPHER_DRV) 72endif 73 74# Plug and Trust NXP SE050X OP-TEE enabled static library 75ldflags-external += $(CFG_NXP_SE05X_PLUG_AND_TRUST_LIB) 76endif # CFG_NXP_SE05X 77