Pankaj Gupta | 6b36c1b | 2020-12-09 14:02:38 +0530 | [diff] [blame] | 1 | # |
| 2 | # Copyright 2021 NXP |
| 3 | # |
| 4 | # SPDX-License-Identifier: BSD-3-Clause |
| 5 | # |
| 6 | # |
| 7 | #------------------------------------------------------------------------------ |
| 8 | # |
| 9 | # Select the CORE files |
| 10 | # |
| 11 | # ----------------------------------------------------------------------------- |
| 12 | |
| 13 | ifeq (${ADD_CONSOLE},) |
| 14 | |
| 15 | ADD_CONSOLE := 1 |
| 16 | |
| 17 | PLAT_INCLUDES += -I$(PLAT_DRIVERS_PATH)/console |
| 18 | |
| 19 | ifeq ($(CONSOLE), NS16550) |
| 20 | NXP_CONSOLE := NS16550 |
| 21 | |
| 22 | $(eval $(call add_define_val,NXP_CONSOLE,${NXP_CONSOLE})) |
| 23 | |
| 24 | CONSOLE_SOURCES := $(PLAT_DRIVERS_PATH)/console/16550_console.S \ |
| 25 | $(PLAT_DRIVERS_PATH)/console/console_16550.c |
| 26 | else |
| 27 | ifeq ($(CONSOLE), PL011) |
| 28 | CONSOLE_SOURCES := drivers/arm/pl011/aarch64/pl011_console.S \ |
| 29 | ${PLAT_DRIVERS_PATH}/console/console_pl011.c |
| 30 | else |
| 31 | $(error -> CONSOLE not set!) |
| 32 | endif |
| 33 | endif |
| 34 | |
| 35 | ifeq (${BL_COMM_CONSOLE_NEEDED},yes) |
| 36 | BL_COMMON_SOURCES += ${CONSOLE_SOURCES} |
| 37 | else |
| 38 | ifeq (${BL2_CONSOLE_NEEDED},yes) |
| 39 | BL2_SOURCES += ${CONSOLE_SOURCES} |
| 40 | endif |
| 41 | ifeq (${BL31_CONSOLE_NEEDED},yes) |
| 42 | BL31_SOURCES += ${CONSOLE_SOURCES} |
| 43 | endif |
| 44 | endif |
| 45 | endif |
| 46 | # ----------------------------------------------------------------------------- |