1# 2# Copyright (c) 2021, Arm Limited. All rights reserved. 3# 4# SPDX-License-Identifier: BSD-3-Clause 5# 6 7include lib/fconf/fconf.mk 8 9AMU_SOURCES := lib/extensions/amu/${ARCH}/amu.c \ 10 lib/extensions/amu/${ARCH}/amu_helpers.S 11 12ifneq (${ENABLE_AMU_AUXILIARY_COUNTERS},0) 13 ifeq (${ENABLE_FEAT_AMU},0) 14 $(error AMU auxiliary counter support (`ENABLE_AMU_AUXILIARY_COUNTERS`) requires AMU support (`ENABLE_FEAT_AMU`)) 15 endif 16endif 17 18ifneq (${ENABLE_AMU_FCONF},0) 19 ifeq (${ENABLE_AMU_AUXILIARY_COUNTERS},0) 20 $(error AMU FCONF support (`ENABLE_AMU_FCONF`) is not necessary when auxiliary counter support (`ENABLE_AMU_AUXILIARY_COUNTERS`) is disabled) 21 endif 22 23 AMU_SOURCES += ${FCONF_AMU_SOURCES} 24endif 25