Commit 5773b532 authored by danh-arm's avatar danh-arm
Browse files

Merge pull request #479 from jcastillo-arm/jc/tbbr_fip

Apply TBBR naming convention to the fip_create options
parents d37b2098 8f0617ef
...@@ -457,34 +457,34 @@ $(eval $(call MAKE_BL,1)) ...@@ -457,34 +457,34 @@ $(eval $(call MAKE_BL,1))
endif endif
ifeq (${NEED_BL2},yes) ifeq (${NEED_BL2},yes)
$(if ${BL2}, $(eval $(call MAKE_TOOL_ARGS,2,${BL2},in_fip)),\ $(if ${BL2}, $(eval $(call MAKE_TOOL_ARGS,2,${BL2},tb-fw)),\
$(eval $(call MAKE_BL,2,in_fip))) $(eval $(call MAKE_BL,2,tb-fw)))
endif endif
ifeq (${NEED_BL31},yes) ifeq (${NEED_BL31},yes)
BL31_SOURCES += ${SPD_SOURCES} BL31_SOURCES += ${SPD_SOURCES}
$(if ${BL31}, $(eval $(call MAKE_TOOL_ARGS,31,${BL31},in_fip)),\ $(if ${BL31}, $(eval $(call MAKE_TOOL_ARGS,31,${BL31},soc-fw)),\
$(eval $(call MAKE_BL,31,in_fip))) $(eval $(call MAKE_BL,31,soc-fw)))
endif endif
# If a BL32 image is needed but neither BL32 nor BL32_SOURCES is defined, the # If a BL32 image is needed but neither BL32 nor BL32_SOURCES is defined, the
# build system will call FIP_ADD_IMG to print a warning message and abort the # build system will call FIP_ADD_IMG to print a warning message and abort the
# process. Note that the dependency on BL32 applies to the FIP only. # process. Note that the dependency on BL32 applies to the FIP only.
ifeq (${NEED_BL32},yes) ifeq (${NEED_BL32},yes)
$(if ${BL32}, $(eval $(call MAKE_TOOL_ARGS,32,${BL32},in_fip)),\ $(if ${BL32}, $(eval $(call MAKE_TOOL_ARGS,32,${BL32},tos-fw)),\
$(if ${BL32_SOURCES}, $(eval $(call MAKE_BL,32,in_fip)),\ $(if ${BL32_SOURCES}, $(eval $(call MAKE_BL,32,tos-fw)),\
$(eval $(call FIP_ADD_IMG,BL32,--bl32)))) $(eval $(call FIP_ADD_IMG,BL32,--tos-fw))))
endif endif
# Add the BL33 image if required by the platform # Add the BL33 image if required by the platform
ifeq (${NEED_BL33},yes) ifeq (${NEED_BL33},yes)
$(eval $(call FIP_ADD_IMG,BL33,--bl33)) $(eval $(call FIP_ADD_IMG,BL33,--nt-fw))
endif endif
ifeq (${NEED_BL2U},yes) ifeq (${NEED_BL2U},yes)
BL2U_PATH := $(if ${BL2U},${BL2U},$(call IMG_BIN,2u)) BL2U_PATH := $(if ${BL2U},${BL2U},$(call IMG_BIN,2u))
$(if ${BL2U}, ,$(eval $(call MAKE_BL,2u))) $(if ${BL2U}, ,$(eval $(call MAKE_BL,2u)))
$(eval $(call FWU_FIP_ADD_PAYLOAD,${BL2U_PATH},--bl2u)) $(eval $(call FWU_FIP_ADD_PAYLOAD,${BL2U_PATH},--ap-fwu-cfg))
endif endif
locate-checkpatch: locate-checkpatch:
......
...@@ -495,7 +495,7 @@ Create a Firmware package that contains existing BL2 and BL31 images: ...@@ -495,7 +495,7 @@ Create a Firmware package that contains existing BL2 and BL31 images:
# fip_create --help to print usage information # fip_create --help to print usage information
# fip_create <fip_name> <images to add> [--dump to show result] # fip_create <fip_name> <images to add> [--dump to show result]
./tools/fip_create/fip_create fip.bin --dump \ ./tools/fip_create/fip_create fip.bin --dump \
--bl2 build/<platform>/debug/bl2.bin --bl31 build/<platform>/debug/bl31.bin --tb-fw build/<platform>/debug/bl2.bin --soc-fw build/<platform>/debug/bl31.bin
Firmware Image Package ToC: Firmware Image Package ToC:
--------------------------- ---------------------------
...@@ -520,7 +520,7 @@ Existing package entries can be individually updated: ...@@ -520,7 +520,7 @@ Existing package entries can be individually updated:
# Change the BL2 from Debug to Release version # Change the BL2 from Debug to Release version
./tools/fip_create/fip_create fip.bin --dump \ ./tools/fip_create/fip_create fip.bin --dump \
--bl2 build/<platform>/release/bl2.bin --tb-fw build/<platform>/release/bl2.bin
Firmware Image Package ToC: Firmware Image Package ToC:
--------------------------- ---------------------------
......
...@@ -126,7 +126,7 @@ endef ...@@ -126,7 +126,7 @@ endef
# FWU_FIP_ADD_PAYLOAD appends the command line arguments required by the FIP tool # FWU_FIP_ADD_PAYLOAD appends the command line arguments required by the FIP tool
# to package a new FWU payload. Optionally, it adds the dependency on this payload # to package a new FWU payload. Optionally, it adds the dependency on this payload
# $(1) = payload filename (e.g. ns_bl2u.bin) # $(1) = payload filename (e.g. ns_bl2u.bin)
# $(2) = command line option for the specified payload (e.g. --ns_bl2u) # $(2) = command line option for the specified payload (e.g. --fwu)
# $(3) = fip target dependency (optional) (e.g. ns_bl2u) # $(3) = fip target dependency (optional) (e.g. ns_bl2u)
define FWU_FIP_ADD_PAYLOAD define FWU_FIP_ADD_PAYLOAD
$(eval $(if $(3),FWU_FIP_DEPS += $(3))) $(eval $(if $(3),FWU_FIP_DEPS += $(3)))
...@@ -285,16 +285,16 @@ endef ...@@ -285,16 +285,16 @@ endef
# each BL image. Arguments: # each BL image. Arguments:
# $(1) = BL stage (2, 30, 31, 32, 33) # $(1) = BL stage (2, 30, 31, 32, 33)
# $(2) = Binary file # $(2) = Binary file
# $(3) = In FIP (false if empty) # $(3) = FIP command line option (if empty, image will not be included in the FIP)
define MAKE_TOOL_ARGS define MAKE_TOOL_ARGS
$(if $(3),$(eval $(call FIP_ADD_PAYLOAD,$(2),--bl$(1),bl$(1)))) $(if $(3),$(eval $(call FIP_ADD_PAYLOAD,$(2),--$(3),bl$(1))))
endef endef
# MAKE_BL macro defines the targets and options to build each BL image. # MAKE_BL macro defines the targets and options to build each BL image.
# Arguments: # Arguments:
# $(1) = BL stage (2, 2u, 30, 31, 32, 33) # $(1) = BL stage (2, 2u, 30, 31, 32, 33)
# $(2) = In FIP (false if empty) # $(2) = FIP command line option (if empty, image will not be included in the FIP)
define MAKE_BL define MAKE_BL
$(eval BUILD_DIR := ${BUILD_PLAT}/bl$(1)) $(eval BUILD_DIR := ${BUILD_PLAT}/bl$(1))
$(eval BL_SOURCES := $(BL$(call uppercase,$(1))_SOURCES)) $(eval BL_SOURCES := $(BL$(call uppercase,$(1))_SOURCES))
......
...@@ -140,7 +140,7 @@ ifneq (${TRUSTED_BOARD_BOOT},0) ...@@ -140,7 +140,7 @@ ifneq (${TRUSTED_BOARD_BOOT},0)
BL2_SOURCES += ${AUTH_SOURCES} BL2_SOURCES += ${AUTH_SOURCES}
$(eval $(call FWU_FIP_ADD_IMG,NS_BL2U,--ns_bl2u)) $(eval $(call FWU_FIP_ADD_IMG,NS_BL2U,--fwu))
MBEDTLS_KEY_ALG := ${KEY_ALG} MBEDTLS_KEY_ALG := ${KEY_ALG}
......
...@@ -52,7 +52,7 @@ BL31_SOURCES += plat/arm/css/common/css_mhu.c \ ...@@ -52,7 +52,7 @@ BL31_SOURCES += plat/arm/css/common/css_mhu.c \
plat/arm/css/common/css_topology.c plat/arm/css/common/css_topology.c
ifneq (${TRUSTED_BOARD_BOOT},0) ifneq (${TRUSTED_BOARD_BOOT},0)
$(eval $(call FWU_FIP_ADD_IMG,SCP_BL2U,--scp_bl2u)) $(eval $(call FWU_FIP_ADD_IMG,SCP_BL2U,--scp-fwu-cfg))
endif endif
ifneq (${RESET_TO_BL31},0) ifneq (${RESET_TO_BL31},0)
...@@ -61,7 +61,7 @@ ifneq (${RESET_TO_BL31},0) ...@@ -61,7 +61,7 @@ ifneq (${RESET_TO_BL31},0)
endif endif
# Subsystems require a SCP_BL2 image # Subsystems require a SCP_BL2 image
$(eval $(call FIP_ADD_IMG,SCP_BL2,--scp_bl2)) $(eval $(call FIP_ADD_IMG,SCP_BL2,--scp-fw))
# Enable option to detect whether the SCP ROM firmware in use predates version # Enable option to detect whether the SCP ROM firmware in use predates version
# 1.7.0 and therefore, is incompatible. # 1.7.0 and therefore, is incompatible.
......
...@@ -56,23 +56,23 @@ uuid_t uuid_null = {0}; ...@@ -56,23 +56,23 @@ uuid_t uuid_null = {0};
/* The images used depends on the platform. */ /* The images used depends on the platform. */
static entry_lookup_list_t toc_entry_lookup_list[] = { static entry_lookup_list_t toc_entry_lookup_list[] = {
{ "SCP Firmware Updater Configuration FWU SCP_BL2U", UUID_TRUSTED_UPDATE_FIRMWARE_SCP_BL2U, { "SCP Firmware Updater Configuration FWU SCP_BL2U", UUID_TRUSTED_UPDATE_FIRMWARE_SCP_BL2U,
"scp_bl2u", NULL, FLAG_FILENAME }, "scp-fwu-cfg", NULL, FLAG_FILENAME },
{ "AP Firmware Updater Configuration BL2U", UUID_TRUSTED_UPDATE_FIRMWARE_BL2U, { "AP Firmware Updater Configuration BL2U", UUID_TRUSTED_UPDATE_FIRMWARE_BL2U,
"bl2u", NULL, FLAG_FILENAME }, "ap-fwu-cfg", NULL, FLAG_FILENAME },
{ "Firmware Updater NS_BL2U", UUID_TRUSTED_UPDATE_FIRMWARE_NS_BL2U, { "Firmware Updater NS_BL2U", UUID_TRUSTED_UPDATE_FIRMWARE_NS_BL2U,
"ns_bl2u", NULL, FLAG_FILENAME }, "fwu", NULL, FLAG_FILENAME },
{ "Non-Trusted Firmware Updater certificate", UUID_TRUSTED_FWU_CERT, { "Non-Trusted Firmware Updater certificate", UUID_TRUSTED_FWU_CERT,
"fwu-cert", NULL, FLAG_FILENAME}, "fwu-cert", NULL, FLAG_FILENAME},
{ "Trusted Boot Firmware BL2", UUID_TRUSTED_BOOT_FIRMWARE_BL2, { "Trusted Boot Firmware BL2", UUID_TRUSTED_BOOT_FIRMWARE_BL2,
"bl2", NULL, FLAG_FILENAME }, "tb-fw", NULL, FLAG_FILENAME },
{ "SCP Firmware SCP_BL2", UUID_SCP_FIRMWARE_SCP_BL2, { "SCP Firmware SCP_BL2", UUID_SCP_FIRMWARE_SCP_BL2,
"scp_bl2", NULL, FLAG_FILENAME}, "scp-fw", NULL, FLAG_FILENAME},
{ "EL3 Runtime Firmware BL31", UUID_EL3_RUNTIME_FIRMWARE_BL31, { "EL3 Runtime Firmware BL31", UUID_EL3_RUNTIME_FIRMWARE_BL31,
"bl31", NULL, FLAG_FILENAME}, "soc-fw", NULL, FLAG_FILENAME},
{ "Secure Payload BL32 (Trusted OS)", UUID_SECURE_PAYLOAD_BL32, { "Secure Payload BL32 (Trusted OS)", UUID_SECURE_PAYLOAD_BL32,
"bl32", NULL, FLAG_FILENAME}, "tos-fw", NULL, FLAG_FILENAME},
{ "Non-Trusted Firmware BL33", UUID_NON_TRUSTED_FIRMWARE_BL33, { "Non-Trusted Firmware BL33", UUID_NON_TRUSTED_FIRMWARE_BL33,
"bl33", NULL, FLAG_FILENAME}, "nt-fw", NULL, FLAG_FILENAME},
/* Key Certificates */ /* Key Certificates */
{ "Root Of Trust key certificate", UUID_ROT_KEY_CERT, { "Root Of Trust key certificate", UUID_ROT_KEY_CERT,
"rot-cert", NULL, FLAG_FILENAME }, "rot-cert", NULL, FLAG_FILENAME },
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment