Skip to content

Commit

Permalink
ARMv7 may not support Generic Timer Extension
Browse files Browse the repository at this point in the history
If ARMv7 based platform does not set ARM_CORTEX_Ax=yes, platform
shall define ARMV7_SUPPORTS_GENERIC_TIMER to enable generic timer
support.

Signed-off-by: Etienne Carriere <[email protected]>
  • Loading branch information
etienne-lms committed Nov 8, 2017
1 parent 64cc6e9 commit 86e2683
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/psci/psci_setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -266,8 +266,10 @@ int psci_setup(const psci_lib_args_t *lib_args)
******************************************************************************/
void psci_arch_setup(void)
{
#if ARM_ARCH_MAJOR > 7 || defined(ARMV7_SUPPORTS_GENERIC_TIMER)
/* Program the counter frequency */
write_cntfrq_el0(plat_get_syscnt_freq2());
#endif

/* Initialize the cpu_ops pointer. */
init_cpu_ops();
Expand Down
4 changes: 4 additions & 0 deletions make_helpers/armv7-a-cpus.mk
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,12 @@ endif
#
# ARMV7_SUPPORTS_VIRTUALIZATION
# Defined if ARMv7 core supports the Virtualization extension.
#
# ARMV7_SUPPORTS_GENERIC_TIMER
# Defined if ARMv7 core supports the Generic Timer extension.

ifeq ($(filter yes,$(ARM_CORTEX_A7) $(ARM_CORTEX_A12) $(ARM_CORTEX_A15) $(ARM_CORTEX_A17)),yes)
$(eval $(call add_define,ARMV7_SUPPORTS_LARGE_PAGE_ADDRESSING))
$(eval $(call add_define,ARMV7_SUPPORTS_VIRTUALIZATION))
$(eval $(call add_define,ARMV7_SUPPORTS_GENERIC_TIMER))
endif

0 comments on commit 86e2683

Please sign in to comment.