mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-19 21:58:04 +00:00
c552bbe00d
02e23db fix compilation errors popped up by GCC-10 7c35173 Merge pull request #29 from pali/sync-a38x-uboot bb734f5 mv_ddr: a38x: Use SOC_REGS_PHY_BASE for INTER_REGS_BASE ee1ea84 mv_ddr: a38x: Fix ddr3 compilation 70f3e2e mv_ddr: Fix comment typo dd960b4 mv_ddr: ddr3: Allow boards to specify CK_DELAY parameter a87f4f7 mv_ddr: ddr3: only use active chip-selects when tuning ODT 3defcec mv_ddr: a38x: Add support for setting timing in hws_topology_map Signed-off-by: Andre Heider <a.heider@gmail.com>
187 lines
5.1 KiB
Makefile
187 lines
5.1 KiB
Makefile
#
|
|
# Copyright (C) 2019 Sartura Ltd.
|
|
#
|
|
# This is free software, licensed under the GNU General Public License v2.
|
|
# See /LICENSE for more information.
|
|
#
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
PKG_VERSION:=2.5
|
|
PKG_RELEASE:=$(AUTORELEASE)
|
|
PKG_HASH:=ad8a2ffcbcd12d919723da07630fc0840c3c2fba7656d1462e45488e42995d7c
|
|
|
|
PKG_MAINTAINER:=Vladimir Vid <vladimir.vid@sartura.hr>
|
|
|
|
include $(INCLUDE_DIR)/trusted-firmware-a.mk
|
|
include $(INCLUDE_DIR)/package.mk
|
|
|
|
define Trusted-Firmware-A/Default
|
|
BUILD_TARGET:=mvebu
|
|
BUILD_SUBTARGET:=cortexa53
|
|
TFA_IMAGE:=flash-image.bin uart-images.tgz.bin
|
|
UBOOT:=
|
|
DDR_TOPOLOGY:=
|
|
CLOCKSPRESET:=
|
|
endef
|
|
|
|
|
|
define Trusted-Firmware-A/espressobin-512mb
|
|
NAME:=Marvell ESPRESSObin (512MB)
|
|
DEPENDS:=+u-boot-espressobin
|
|
BUILD_DEVICES:=globalscale_espressobin
|
|
UBOOT:=espressobin
|
|
DDR_TOPOLOGY:=0
|
|
CLOCKSPRESET:=CPU_1000_DDR_800
|
|
PLAT:=a3700
|
|
endef
|
|
|
|
define Trusted-Firmware-A/espressobin-v3-v5-1gb-1cs
|
|
NAME:=Marvell ESPRESSObin V3-V5 (1GB 1CS)
|
|
DEPENDS:=+u-boot-espressobin
|
|
BUILD_DEVICES:=globalscale_espressobin
|
|
UBOOT:=espressobin
|
|
DDR_TOPOLOGY:=4
|
|
CLOCKSPRESET:=CPU_1000_DDR_800
|
|
PLAT:=a3700
|
|
endef
|
|
|
|
define Trusted-Firmware-A/espressobin-v3-v5-1gb-2cs
|
|
NAME:=Marvell ESPRESSObin V3-V5 (1GB, 2CS)
|
|
DEPENDS:=+u-boot-espressobin
|
|
BUILD_DEVICES:=globalscale_espressobin
|
|
UBOOT:=espressobin
|
|
DDR_TOPOLOGY:=2
|
|
CLOCKSPRESET:=CPU_1000_DDR_800
|
|
PLAT:=a3700
|
|
endef
|
|
|
|
define Trusted-Firmware-A/espressobin-v3-v5-2gb
|
|
NAME:=Marvell ESPRESSObin V3-V5 (2GB)
|
|
DEPENDS:=+u-boot-espressobin
|
|
BUILD_DEVICES:=globalscale_espressobin
|
|
UBOOT:=espressobin
|
|
DDR_TOPOLOGY:=7
|
|
CLOCKSPRESET:=CPU_1000_DDR_800
|
|
PLAT:=a3700
|
|
endef
|
|
|
|
define Trusted-Firmware-A/espressobin-v7-1gb
|
|
NAME:=Marvell ESPRESSObin V7 (1GB)
|
|
DEPENDS:=+u-boot-espressobin
|
|
BUILD_DEVICES:=globalscale_espressobin-v7
|
|
UBOOT:=espressobin
|
|
DDR_TOPOLOGY:=5
|
|
CLOCKSPRESET:=CPU_1000_DDR_800
|
|
PLAT:=a3700
|
|
endef
|
|
|
|
define Trusted-Firmware-A/espressobin-v7-2gb
|
|
NAME:=Marvell ESPRESSObin V7 (2GB)
|
|
DEPENDS:=+u-boot-espressobin
|
|
BUILD_DEVICES:=globalscale_espressobin-v7
|
|
UBOOT:=espressobin
|
|
DDR_TOPOLOGY:=6
|
|
CLOCKSPRESET:=CPU_1000_DDR_800
|
|
PLAT:=a3700
|
|
endef
|
|
|
|
define Trusted-Firmware-A/udpu
|
|
NAME:=Methode uDPU
|
|
DEPENDS:=+u-boot-uDPU
|
|
BUILD_DEVICES:=methode_udpu
|
|
UBOOT:=uDPU
|
|
DDR_TOPOLOGY:=0
|
|
CLOCKSPRESET:=CPU_1000_DDR_800
|
|
PLAT:=a3700
|
|
endef
|
|
|
|
|
|
TFA_TARGETS:= \
|
|
espressobin-512mb \
|
|
espressobin-v3-v5-1gb-1cs \
|
|
espressobin-v3-v5-1gb-2cs \
|
|
espressobin-v3-v5-2gb \
|
|
espressobin-v7-1gb \
|
|
espressobin-v7-2gb \
|
|
udpu
|
|
|
|
TFA_MAKE_FLAGS += \
|
|
CROSS_CM3=$(STAGING_DIR_IMAGE)/$(LINARO_NAME)-$(LINARO_RELEASE).$(LINARO_VERSION)/bin/arm-linux-gnueabi- \
|
|
BL33=$(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot.bin \
|
|
MV_DDR_PATH=$(STAGING_DIR_IMAGE)/$(MV_DDR_NAME) \
|
|
WTP=$(STAGING_DIR_IMAGE)/$(A3700_UTILS_NAME) \
|
|
USE_COHERENT_MEM=0 \
|
|
FIP_ALIGN=0x100 \
|
|
DDR_TOPOLOGY=$(DDR_TOPOLOGY) \
|
|
CLOCKSPRESET=$(CLOCKSPRESET) \
|
|
A3700_UTILS_COMMIT_ID=$(A3700_UTILS_RELEASE) \
|
|
MV_DDR_COMMIT_ID=$(MV_DDR_RELEASE) \
|
|
all \
|
|
mrvl_flash \
|
|
mrvl_uart
|
|
|
|
A3700_UTILS_NAME:=a3700-utils
|
|
A3700_UTILS_RELEASE:=2efdb10f
|
|
A3700_UTILS_SOURCE=$(A3700_UTILS_NAME)-$(A3700_UTILS_RELEASE).tar.bz2
|
|
|
|
define Download/a3700-utils
|
|
FILE:=$(A3700_UTILS_SOURCE)
|
|
PROTO:=git
|
|
URL:=https://github.com/MarvellEmbeddedProcessors/A3700-utils-marvell.git
|
|
VERSION:=2efdb10f3524c534d276002adf81fec06e0f1cf2
|
|
MIRROR_HASH:=4476e1bacfa7abb4a1303c6cf3aa7d067038b24090dfd5da13ca2a72a0d5c7a4
|
|
SUBDIR:=$(A3700_UTILS_NAME)
|
|
endef
|
|
|
|
MV_DDR_NAME:=mv-ddr-marvell
|
|
MV_DDR_RELEASE:=02e23dbc
|
|
MV_DDR_SOURCE:=$(MV_DDR_NAME)-$(MV_DDR_RELEASE).tar.bz2
|
|
|
|
define Download/mv-ddr-marvell
|
|
FILE:=$(MV_DDR_SOURCE)
|
|
PROTO:=git
|
|
URL:=https://github.com/MarvellEmbeddedProcessors/mv-ddr-marvell.git
|
|
VERSION:=02e23dbcf8dd22e038986052d99319a0eba8f25f
|
|
MIRROR_HASH:=d87dcc288b3895d1a1a78908fc607976d500b317ef81edfe667035579df0b440
|
|
SUBDIR:=$(MV_DDR_NAME)
|
|
endef
|
|
|
|
LINARO_NAME:=gcc-linaro
|
|
LINARO_RELEASE:=6
|
|
LINARO_VERSION:=5.0-2018.12-$(HOST_ARCH)_arm-linux-gnueabi
|
|
LINARO_SOURCE=$(LINARO_NAME)-$(LINARO_RELEASE).$(LINARO_VERSION).tar.xz
|
|
|
|
define Download/gcc-linaro
|
|
FILE:=$(LINARO_SOURCE)
|
|
URL:=https://releases.linaro.org/components/toolchain/binaries/latest-$(LINARO_RELEASE)/arm-linux-gnueabi/
|
|
HASH:=2d4a92d6c8b384ae404b2e02c1c412e3ec18f9b714135acf046b2b1b510e9ace
|
|
endef
|
|
|
|
define Build/Clean
|
|
rm -rf \
|
|
$(STAGING_DIR_IMAGE)/$(A3700_UTILS_NAME) \
|
|
$(STAGING_DIR_IMAGE)/$(MV_DDR_NAME) \
|
|
$(STAGING_DIR_IMAGE)/$(LINARO_NAME)-$(LINARO_RELEASE).$(LINARO_VERSION)
|
|
endef
|
|
|
|
define Build/Prepare
|
|
# Download sources
|
|
$(eval $(call Download,a3700-utils))
|
|
$(eval $(call Download,mv-ddr-marvell))
|
|
$(eval $(call Download,gcc-linaro))
|
|
|
|
$(call Build/Prepare/Default,)
|
|
|
|
mkdir -p $(STAGING_DIR_IMAGE)
|
|
$(TAR) -C $(STAGING_DIR_IMAGE) -xf $(DL_DIR)/$(A3700_UTILS_SOURCE)
|
|
echo "master" > $(STAGING_DIR_IMAGE)/$(A3700_UTILS_NAME)/branch.txt
|
|
$(call PatchDir/Default,$(STAGING_DIR_IMAGE)/$(A3700_UTILS_NAME),./patches-a3700-utils)
|
|
$(TAR) -C $(STAGING_DIR_IMAGE) -xf $(DL_DIR)/$(MV_DDR_SOURCE)
|
|
echo "master" > $(STAGING_DIR_IMAGE)/$(MV_DDR_NAME)/branch.txt
|
|
$(call PatchDir/Default,$(STAGING_DIR_IMAGE)/$(MV_DDR_NAME),./patches-mv-ddr-marvell)
|
|
$(TAR) -C $(STAGING_DIR_IMAGE) -xf $(DL_DIR)/$(LINARO_SOURCE)
|
|
endef
|
|
|
|
$(eval $(call BuildPackage/Trusted-Firmware-A))
|