ARM platforms: Initialize cntfrq for BL1 Firmware update

Currenly the CNTFRQ register and system timer is initialized in BL31 for
use by the normal world. During firmware update, the NS-BL1 or NS-BL2U
may need to access the system timer. Hence this patch duplicates the
CNTFRQ and system timer initialization in BL1 as well.

Signed-off-by: Soby Mathew <soby.mathew@arm.com>
Change-Id: I1ede78b4ae64080fb418cb93f3e48b26d7b724dc
diff --git a/plat/arm/common/arm_bl1_setup.c b/plat/arm/common/arm_bl1_setup.c
index e5e7304..d141f64 100644
--- a/plat/arm/common/arm_bl1_setup.c
+++ b/plat/arm/common/arm_bl1_setup.c
@@ -118,6 +118,12 @@
 #if LOAD_IMAGE_V2
 	arm_load_tb_fw_config();
 #endif
+	/*
+	 * Allow access to the System counter timer module and program
+	 * counter frequency for non secure images during FWU
+	 */
+	arm_configure_sys_timer();
+	write_cntfrq_el0(plat_get_syscnt_freq2());
 }
 
 void bl1_platform_setup(void)