diff options
author | Pali Rohár <pali@kernel.org> | 2021-06-28 15:27:25 +0200 |
---|---|---|
committer | Pali Rohár <pali@kernel.org> | 2021-07-10 18:24:43 +0200 |
commit | 528dafc367c4f49d4904c4335422502dacf469bf (patch) | |
tree | edf8b02fe49cf91ee21f081a0df6159969f94938 | |
parent | 41e893fff445c0c272303961a38f14cb54f2e8ab (diff) | |
download | arm-trusted-firmware-528dafc367c4f49d4904c4335422502dacf469bf.tar.gz |
fix(plat/marvell/a8k): Require that MV_DDR_PATH is correctly set
Target mrvl_flash depends on external mv_ddr source code which is not
part of TF-A project. Do not expect that it is pre-downloaded at some
specific location and require user to specify correct path to mv_ddr
source code via MV_DDR_PATH build option.
TF-A code for Armada 37x0 platform also depends on mv_ddr source code
and already requires passing correct MV_DDR_PATH build option.
So for A8K implement same checks for validity of MV_DDR_PATH option as
are already used by TF-A code for Armada 37x0 platform.
Signed-off-by: Pali Rohár <pali@kernel.org>
Change-Id: I792f2bfeab0cec89b1b64e88d7b2c456e22de43a
-rw-r--r-- | docs/plat/marvell/armada/build.rst | 6 | ||||
-rw-r--r-- | plat/marvell/armada/a8k/common/ble/ble.mk | 5 |
2 files changed, 5 insertions, 6 deletions
diff --git a/docs/plat/marvell/armada/build.rst b/docs/plat/marvell/armada/build.rst index c9f5e8224..fcc74a51e 100644 --- a/docs/plat/marvell/armada/build.rst +++ b/docs/plat/marvell/armada/build.rst @@ -129,15 +129,13 @@ There are several build options: - MV_DDR_PATH + This parameter is required for ``mrvl_flash`` and ``mrvl_uart`` targets. + For A7K/8K/CN913x, use this parameter to point to mv_ddr driver sources to allow BLE build. For A37x0, it is used for ddr_tool build. Usage example: MV_DDR_PATH=path/to/mv_ddr - The parameter is optional for A7K/8K/CN913x, when this parameter is not set, the mv_ddr - sources are expected to be located at: drivers/marvell/mv_ddr. However, the parameter - is necessary for A37x0. - For the mv_ddr source location, check the section "Tools and external components installation" If MV_DDR_PATH source code is a git snapshot then provide path to the full git diff --git a/plat/marvell/armada/a8k/common/ble/ble.mk b/plat/marvell/armada/a8k/common/ble/ble.mk index d6d72c15d..6ca18fdb8 100644 --- a/plat/marvell/armada/a8k/common/ble/ble.mk +++ b/plat/marvell/armada/a8k/common/ble/ble.mk @@ -3,8 +3,6 @@ # SPDX-License-Identifier: BSD-3-Clause # https://spdx.org/licenses -MV_DDR_PATH ?= drivers/marvell/mv_ddr - MV_DDR_LIB = $(BUILD_PLAT)/ble/mv_ddr_lib.a LIBC_LIB = $(BUILD_PLAT)/lib/libc.a BLE_LIBS = $(MV_DDR_LIB) $(LIBC_LIB) @@ -28,4 +26,7 @@ PLAT_INCLUDES += -I$(MV_DDR_PATH) \ BLE_LINKERFILE := $(BLE_PATH)/ble.ld.S $(MV_DDR_LIB): FORCE + $(if $(value MV_DDR_PATH),,$(error "Platform '$(PLAT)' for BLE requires MV_DDR_PATH. Please set MV_DDR_PATH to point to the right directory")) + $(if $(wildcard $(value MV_DDR_PATH)/*),,$(error "'MV_DDR_PATH=$(value MV_DDR_PATH)' was specified, but '$(value MV_DDR_PATH)' directory does not exist")) + $(if $(shell git -C $(value MV_DDR_PATH) rev-parse --show-cdup 2>&1),$(error "'MV_DDR_PATH=$(value MV_DDR_PATH)' was specified, but '$(value MV_DDR_PATH)' does not contain valid mv-ddr-marvell git repository")) @+make -C $(MV_DDR_PATH) --no-print-directory PLAT_INCLUDES="$(PLAT_INCLUDES)" PLATFORM=$(PLAT) ARCH=AARCH64 OBJ_DIR=$(BUILD_PLAT)/ble |