arm: common: Make timer configuration conditional

Make the timer configuration conditional on the optional interface being
available.

Signed-off-by: Soren Brinkmann <soren.brinkmann@xilinx.com>
This commit is contained in:
Soren Brinkmann 2016-03-06 20:23:39 -08:00
parent b5e6d09294
commit 21aa752dd8
1 changed files with 2 additions and 0 deletions

View File

@ -137,6 +137,7 @@ uint32_t arm_get_spsr_for_bl33_entry(void)
/******************************************************************************* /*******************************************************************************
* Configures access to the system counter timer module. * Configures access to the system counter timer module.
******************************************************************************/ ******************************************************************************/
#ifdef ARM_SYS_TIMCTL_BASE
void arm_configure_sys_timer(void) void arm_configure_sys_timer(void)
{ {
unsigned int reg_val; unsigned int reg_val;
@ -151,6 +152,7 @@ void arm_configure_sys_timer(void)
reg_val = (1 << CNTNSAR_NS_SHIFT(PLAT_ARM_NSTIMER_FRAME_ID)); reg_val = (1 << CNTNSAR_NS_SHIFT(PLAT_ARM_NSTIMER_FRAME_ID));
mmio_write_32(ARM_SYS_TIMCTL_BASE + CNTNSAR, reg_val); mmio_write_32(ARM_SYS_TIMCTL_BASE + CNTNSAR, reg_val);
} }
#endif /* ARM_SYS_TIMCTL_BASE */
/******************************************************************************* /*******************************************************************************
* Returns ARM platform specific memory map regions. * Returns ARM platform specific memory map regions.