Chris Kay | 1000ea8 | 2021-05-19 19:24:37 +0100 | [diff] [blame] | 1 | # |
| 2 | # Copyright (c) 2021, Arm Limited. All rights reserved. |
| 3 | # |
| 4 | # SPDX-License-Identifier: BSD-3-Clause |
| 5 | # |
| 6 | |
Chris Kay | f11909f | 2021-08-19 11:21:52 +0100 | [diff] [blame] | 7 | include lib/fconf/fconf.mk |
| 8 | |
Chris Kay | 1000ea8 | 2021-05-19 19:24:37 +0100 | [diff] [blame] | 9 | AMU_SOURCES := lib/extensions/amu/${ARCH}/amu.c \ |
| 10 | lib/extensions/amu/${ARCH}/amu_helpers.S |
Chris Kay | f11909f | 2021-08-19 11:21:52 +0100 | [diff] [blame] | 11 | |
| 12 | ifneq (${ENABLE_AMU_AUXILIARY_COUNTERS},0) |
| 13 | ifeq (${ENABLE_AMU},0) |
| 14 | $(error AMU auxiliary counter support (`ENABLE_AMU_AUXILIARY_COUNTERS`) requires AMU support (`ENABLE_AMU`)) |
| 15 | endif |
| 16 | endif |
| 17 | |
| 18 | ifneq (${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} |
| 24 | endif |