chore(auth)!: remove CryptoCell-712/713 support

CryptoCell-712 and CryptoCell-713 drivers have been deprecated since
TF-A v2.9 and their removal was announced for TF-A v2.10 release.
See [1].

As the release is approaching, this patch deletes these drivers' code as
well as all references to them in the documentation and Arm platforms
code (Nuvoton platform is taken care in a subsequent patch). Associated
build options (ARM_CRYPTOCELL_INTEG and PLAT_CRYPTOCELL_BASE) have also
been removed and thus will have no effect if defined.

This is a breaking change for downstream platforms which use these
drivers.

[1] https://trustedfirmware-a.readthedocs.io/en/v2.9/about/release-information.html#removal-of-deprecated-drivers
    Note that TF-A v3.0 release later got renumbered into v2.10.

Signed-off-by: Sandrine Bailleux <sandrine.bailleux@arm.com>
Change-Id: Idabbc9115f6732ac1a0e52b273d3380677a39813
diff --git a/plat/arm/common/aarch64/arm_helpers.S b/plat/arm/common/aarch64/arm_helpers.S
index ed85ea1..3e56691 100644
--- a/plat/arm/common/aarch64/arm_helpers.S
+++ b/plat/arm/common/aarch64/arm_helpers.S
@@ -86,51 +86,3 @@
 func platform_mem_init
 	ret
 endfunc platform_mem_init
-
-/*
- * Need to use coherent stack when ARM Cryptocell is used to autheticate images
- * since Cryptocell uses DMA to transfer data and it is not coherent with the
- * AP CPU.
- */
-#if ARM_CRYPTOCELL_INTEG
-#if defined(IMAGE_BL1) || defined(IMAGE_BL2)
-	.globl	plat_get_my_stack
-	.globl	plat_set_my_stack
-	.local	platform_coherent_stacks
-
-	/* -------------------------------------------------------
-	 * uintptr_t plat_get_my_stack ()
-	 *
-	 * For cold-boot BL images, only the primary CPU needs a
-	 * stack. This function returns the stack pointer for a
-	 * stack allocated in coherent memory.
-	 * -------------------------------------------------------
-	 */
-func plat_get_my_stack
-	get_up_stack platform_coherent_stacks, PLATFORM_STACK_SIZE
-	ret
-endfunc plat_get_my_stack
-
-	/* -------------------------------------------------------
-	 * void plat_set_my_stack ()
-	 *
-	 * For cold-boot BL images, only the primary CPU needs a
-	 * stack. This function sets the stack pointer to a stack
-	 * allocated in coherent memory.
-	 * -------------------------------------------------------
-	 */
-func plat_set_my_stack
-	get_up_stack platform_coherent_stacks, PLATFORM_STACK_SIZE
-	mov sp, x0
-	ret
-endfunc plat_set_my_stack
-
-	/* ----------------------------------------------------
-	 * Single cpu stack in coherent memory.
-	 * ----------------------------------------------------
-	 */
-declare_stack platform_coherent_stacks, .tzfw_coherent_mem, \
-		PLATFORM_STACK_SIZE, 1, CACHE_WRITEBACK_GRANULE
-
-#endif	/* defined(IMAGE_BL1) || defined(IMAGE_BL2) */
-#endif	/* ARM_CRYPTOCELL_INTEG */
diff --git a/plat/arm/common/arm_bl1_setup.c b/plat/arm/common/arm_bl1_setup.c
index 7000236..feff691 100644
--- a/plat/arm/common/arm_bl1_setup.c
+++ b/plat/arm/common/arm_bl1_setup.c
@@ -108,11 +108,8 @@
  *****************************************************************************/
 void arm_bl1_plat_arch_setup(void)
 {
-#if USE_COHERENT_MEM && !ARM_CRYPTOCELL_INTEG
-	/*
-	 * Ensure ARM platforms don't use coherent memory in BL1 unless
-	 * cryptocell integration is enabled.
-	 */
+#if USE_COHERENT_MEM
+	/* Ensure ARM platforms don't use coherent memory in BL1. */
 	assert((BL_COHERENT_RAM_END - BL_COHERENT_RAM_BASE) == 0U);
 #endif
 
@@ -123,9 +120,6 @@
 		ARM_MAP_ROMLIB_CODE,
 		ARM_MAP_ROMLIB_DATA,
 #endif
-#if ARM_CRYPTOCELL_INTEG
-		ARM_MAP_BL_COHERENT_RAM,
-#endif
 		{0}
 	};
 
diff --git a/plat/arm/common/arm_bl2_setup.c b/plat/arm/common/arm_bl2_setup.c
index e15bf0f..3e8109e 100644
--- a/plat/arm/common/arm_bl2_setup.c
+++ b/plat/arm/common/arm_bl2_setup.c
@@ -184,11 +184,8 @@
  ******************************************************************************/
 void arm_bl2_plat_arch_setup(void)
 {
-#if USE_COHERENT_MEM && !ARM_CRYPTOCELL_INTEG
-	/*
-	 * Ensure ARM platforms don't use coherent memory in BL2 unless
-	 * cryptocell integration is enabled.
-	 */
+#if USE_COHERENT_MEM
+	/* Ensure ARM platforms don't use coherent memory in BL2. */
 	assert((BL_COHERENT_RAM_END - BL_COHERENT_RAM_BASE) == 0U);
 #endif
 
@@ -199,9 +196,6 @@
 		ARM_MAP_ROMLIB_CODE,
 		ARM_MAP_ROMLIB_DATA,
 #endif
-#if ARM_CRYPTOCELL_INTEG
-		ARM_MAP_BL_COHERENT_RAM,
-#endif
 		ARM_MAP_BL_CONFIG_REGION,
 #if ENABLE_RME
 		ARM_MAP_L0_GPT_REGION,
diff --git a/plat/arm/common/arm_common.mk b/plat/arm/common/arm_common.mk
index bbb39d5..ae0d85d 100644
--- a/plat/arm/common/arm_common.mk
+++ b/plat/arm/common/arm_common.mk
@@ -164,24 +164,11 @@
     endif
 endif
 
-# Disable ARM Cryptocell by default
-ARM_CRYPTOCELL_INTEG		:=	0
-$(eval $(call assert_boolean,ARM_CRYPTOCELL_INTEG))
-$(eval $(call add_define,ARM_CRYPTOCELL_INTEG))
-
 # Enable PIE support for RESET_TO_BL31/RESET_TO_SP_MIN case
 ifneq ($(filter 1,${RESET_TO_BL31} ${RESET_TO_SP_MIN}),)
 	ENABLE_PIE			:=	1
 endif
 
-# CryptoCell integration relies on coherent buffers for passing data from
-# the AP CPU to the CryptoCell
-ifeq (${ARM_CRYPTOCELL_INTEG},1)
-    ifeq (${USE_COHERENT_MEM},0)
-        $(error "ARM_CRYPTOCELL_INTEG needs USE_COHERENT_MEM to be set.")
-    endif
-endif
-
 # Disable GPT parser support, use FIP image by default
 ARM_GPT_SUPPORT			:=	0
 $(eval $(call assert_boolean,ARM_GPT_SUPPORT))
@@ -447,11 +434,7 @@
     BL31_SOURCES	+=	drivers/auth/crypto_mod.c
 
     # We expect to locate the *.mk files under the directories specified below
-    ifeq (${ARM_CRYPTOCELL_INTEG},0)
-        CRYPTO_LIB_MK := drivers/auth/mbedtls/mbedtls_crypto.mk
-    else
-        CRYPTO_LIB_MK := drivers/auth/cryptocell/cryptocell_crypto.mk
-    endif
+    CRYPTO_LIB_MK := drivers/auth/mbedtls/mbedtls_crypto.mk
 
     $(info Including ${CRYPTO_LIB_MK})
     include ${CRYPTO_LIB_MK}