Add support for IMA-CATALOG package
diff --git a/openpower/configs/barreleye_defconfig b/openpower/configs/barreleye_defconfig
index 93a36c8..3d8e8e6 100644
--- a/openpower/configs/barreleye_defconfig
+++ b/openpower/configs/barreleye_defconfig
@@ -53,7 +53,7 @@
BR2_HOSTBOOT_BINARY_SBEC_FILENAME="centaur_sbec_pad.img.ecc"
BR2_HOSTBOOT_BINARY_WINK_FILENAME="p8.ref_image.hdr.bin.ecc"
BR2_IMA_CATALOG_FILENAME="ima_catalog.bin"
-BR2_IMA_CATALOG_ECC_FILENAME="ima_catalog.bin.ecc"
+BR2_IMA_CATALOG_DTS="POWER8"
BR2_OPENPOWER_TARGETING_BIN_FILENAME="BARRELEYE_HB.targeting.bin"
BR2_OPENPOWER_TARGETING_ECC_FILENAME="BARRELEYE_HB.targeting.bin.ecc"
BR2_PACKAGE_PETITBOOT=y
diff --git a/openpower/configs/firenze_defconfig b/openpower/configs/firenze_defconfig
index e372c5f..c9ba087 100644
--- a/openpower/configs/firenze_defconfig
+++ b/openpower/configs/firenze_defconfig
@@ -48,5 +48,6 @@
BR2_PACKAGE_PETITBOOT_MTD=y
# BR2_PACKAGE_HOST_P8_PORE_BINUTILS is not set
# BR2_PACKAGE_OCC is not set
+# BR2_PACKAGE_IMA_CATALOG is not set
# BR2_PACKAGE_CAPP_UCODE is not set
BR2_PACKAGE_LOADKEYS=y
diff --git a/openpower/configs/firestone_defconfig b/openpower/configs/firestone_defconfig
index fdfc0db..e744171 100644
--- a/openpower/configs/firestone_defconfig
+++ b/openpower/configs/firestone_defconfig
@@ -53,7 +53,7 @@
BR2_HOSTBOOT_BINARY_SBEC_FILENAME="centaur_sbec_pad.img.ecc"
BR2_HOSTBOOT_BINARY_WINK_FILENAME="p8.ref_image.hdr.bin.ecc"
BR2_IMA_CATALOG_FILENAME="ima_catalog.bin"
-BR2_IMA_CATALOG_ECC_FILENAME="ima_catalog.bin.ecc"
+BR2_IMA_CATALOG_DTS="POWER8"
BR2_OPENPOWER_TARGETING_BIN_FILENAME="FIRESTONE_HB.targeting.bin"
BR2_OPENPOWER_TARGETING_ECC_FILENAME="FIRESTONE_HB.targeting.bin.ecc"
BR2_PACKAGE_PETITBOOT=y
diff --git a/openpower/configs/garrison_defconfig b/openpower/configs/garrison_defconfig
index 758b1fd..71b93c3 100644
--- a/openpower/configs/garrison_defconfig
+++ b/openpower/configs/garrison_defconfig
@@ -53,7 +53,7 @@
BR2_HOSTBOOT_BINARY_SBEC_FILENAME="centaur_sbec_pad.img.ecc"
BR2_HOSTBOOT_BINARY_WINK_FILENAME="n1.ref_image.hdr.bin.ecc"
BR2_IMA_CATALOG_FILENAME="ima_catalog.bin"
-BR2_IMA_CATALOG_ECC_FILENAME="ima_catalog.bin.ecc"
+BR2_IMA_CATALOG_DTS="POWER8"
BR2_OPENPOWER_TARGETING_BIN_FILENAME="GARRISON_HB.targeting.bin"
BR2_OPENPOWER_TARGETING_ECC_FILENAME="GARRISON_HB.targeting.bin.ecc"
BR2_PACKAGE_PETITBOOT=y
diff --git a/openpower/configs/habanero_defconfig b/openpower/configs/habanero_defconfig
index 66d3adb..646936c 100644
--- a/openpower/configs/habanero_defconfig
+++ b/openpower/configs/habanero_defconfig
@@ -53,7 +53,7 @@
BR2_HOSTBOOT_BINARY_SBEC_FILENAME="centaur_sbec_pad.img.ecc"
BR2_HOSTBOOT_BINARY_WINK_FILENAME="p8.ref_image.hdr.bin.ecc"
BR2_IMA_CATALOG_FILENAME="ima_catalog.bin"
-BR2_IMA_CATALOG_ECC_FILENAME="ima_catalog.bin.ecc"
+BR2_IMA_CATALOG_DTS="POWER8"
BR2_OPENPOWER_TARGETING_BIN_FILENAME="HABANERO_HB.targeting.bin"
BR2_OPENPOWER_TARGETING_ECC_FILENAME="HABANERO_HB.targeting.bin.ecc"
BR2_PACKAGE_PETITBOOT=y
diff --git a/openpower/configs/openpower_mambo_defconfig b/openpower/configs/openpower_mambo_defconfig
index c2dd7e2..ad70d69 100644
--- a/openpower/configs/openpower_mambo_defconfig
+++ b/openpower/configs/openpower_mambo_defconfig
@@ -44,3 +44,4 @@
BR2_OPENPOWER_CONFIG_NAME="openpower-mambo"
BR2_PACKAGE_PETITBOOT=y
# BR2_PACKAGE_OCC is not set
+# BR2_PACKAGE_IMA_CATALOG is not set
diff --git a/openpower/configs/openpower_p9_mambo_defconfig b/openpower/configs/openpower_p9_mambo_defconfig
index a9d89b9..17c7788 100644
--- a/openpower/configs/openpower_p9_mambo_defconfig
+++ b/openpower/configs/openpower_p9_mambo_defconfig
@@ -43,3 +43,4 @@
BR2_OPENPOWER_CONFIG_NAME="openpower-mambo-p9"
BR2_PACKAGE_PETITBOOT=y
# BR2_PACKAGE_OCC is not set
+# BR2_PACKAGE_IMA_CATALOG is not set
diff --git a/openpower/configs/palmetto_defconfig b/openpower/configs/palmetto_defconfig
index 812f962..6f4b37c 100644
--- a/openpower/configs/palmetto_defconfig
+++ b/openpower/configs/palmetto_defconfig
@@ -51,7 +51,7 @@
BR2_HOSTBOOT_BINARY_SBEC_FILENAME="centaur_sbec_pad.img.ecc"
BR2_HOSTBOOT_BINARY_WINK_FILENAME="p8.ref_image.hdr.bin.ecc"
BR2_IMA_CATALOG_FILENAME="ima_catalog.bin"
-BR2_IMA_CATALOG_ECC_FILENAME="ima_catalog.bin.ecc"
+BR2_IMA_CATALOG_DTS="POWER8"
BR2_OPENPOWER_TARGETING_BIN_FILENAME="PALMETTO_HB.targeting.bin"
BR2_OPENPOWER_TARGETING_ECC_FILENAME="PALMETTO_HB.targeting.bin.ecc"
BR2_PACKAGE_PETITBOOT=y
diff --git a/openpower/configs/witherspoon_defconfig b/openpower/configs/witherspoon_defconfig
index c8f248c..c464684 100644
--- a/openpower/configs/witherspoon_defconfig
+++ b/openpower/configs/witherspoon_defconfig
@@ -50,7 +50,7 @@
BR2_HOSTBOOT_BINARY_SBEC_FILENAME="centaur_sbec_pad.img.ecc"
BR2_HOSTBOOT_BINARY_WINK_FILENAME="p9n.ref_image.hdr.bin.ecc"
BR2_IMA_CATALOG_FILENAME="ima_catalog.bin"
-BR2_IMA_CATALOG_ECC_FILENAME="ima_catalog.bin.ecc"
+BR2_IMA_CATALOG_DTS="POWER9"
BR2_OPENPOWER_TARGETING_BIN_FILENAME="WITHERSPOON_HB.targeting.bin"
BR2_OPENPOWER_TARGETING_ECC_FILENAME="WITHERSPOON_HB.targeting.bin.ecc"
BR2_PACKAGE_PETITBOOT=y
diff --git a/openpower/configs/zaius_defconfig b/openpower/configs/zaius_defconfig
index 56df695..945bec7 100644
--- a/openpower/configs/zaius_defconfig
+++ b/openpower/configs/zaius_defconfig
@@ -49,7 +49,7 @@
BR2_HOSTBOOT_BINARY_SBEC_FILENAME="centaur_sbec_pad.img.ecc"
BR2_HOSTBOOT_BINARY_WINK_FILENAME="p9n.ref_image.hdr.bin.ecc"
BR2_IMA_CATALOG_FILENAME="ima_catalog.bin"
-BR2_IMA_CATALOG_ECC_FILENAME="ima_catalog.bin.ecc"
+BR2_IMA_CATALOG_DTS="POWER9"
BR2_OPENPOWER_TARGETING_BIN_FILENAME="ZAIUS_HB.targeting.bin"
BR2_OPENPOWER_TARGETING_ECC_FILENAME="ZAIUS_HB.targeting.bin.ecc"
BR2_PACKAGE_PETITBOOT=y
diff --git a/openpower/package/Config.in b/openpower/package/Config.in
index db58166..dc12184 100755
--- a/openpower/package/Config.in
+++ b/openpower/package/Config.in
@@ -20,3 +20,4 @@
source "$BR2_EXTERNAL_OP_BUILD_PATH/package/ppe42-binutils/Config.in"
source "$BR2_EXTERNAL_OP_BUILD_PATH/package/ppe42-gcc/Config.in"
source "$BR2_EXTERNAL_OP_BUILD_PATH/package/zaius-xml/Config.in"
+source "$BR2_EXTERNAL_OP_BUILD_PATH/package/ima-catalog/Config.in"
diff --git a/openpower/package/hostboot-binaries/hostboot_binaries.mk b/openpower/package/hostboot-binaries/hostboot_binaries.mk
index ca9062e..f031832 100644
--- a/openpower/package/hostboot-binaries/hostboot_binaries.mk
+++ b/openpower/package/hostboot-binaries/hostboot_binaries.mk
@@ -17,7 +17,6 @@
$(INSTALL) -D $(@D)/$(BR2_HOSTBOOT_BINARY_WINK_FILENAME) $(STAGING_DIR)/hostboot_binaries/
$(INSTALL) -D $(@D)/$(BR2_HOSTBOOT_BINARY_SBEC_FILENAME) $(STAGING_DIR)/hostboot_binaries/
$(INSTALL) -D $(@D)/$(BR2_HOSTBOOT_BINARY_SBE_FILENAME) $(STAGING_DIR)/hostboot_binaries/
- $(INSTALL) -D $(@D)/$(BR2_IMA_CATALOG_FILENAME) $(STAGING_DIR)/hostboot_binaries/
endef
$(eval $(generic-package))
diff --git a/openpower/package/ima-catalog/Config.in b/openpower/package/ima-catalog/Config.in
new file mode 100644
index 0000000..98d02c5
--- /dev/null
+++ b/openpower/package/ima-catalog/Config.in
@@ -0,0 +1,15 @@
+config BR2_PACKAGE_IMA_CATALOG
+ bool "ima_catalog"
+ default y if (BR2_OPENPOWER_PLATFORM)
+ help
+ Event Catalog for In Memory Accumulation(IMA) hardware
+
+config BR2_IMA_CATALOG_DTS
+ string "Catalog DTS file to select"
+ help
+ String used to define the CATALOG dts file to select
+
+config BR2_IMA_CATALOG_FILENAME
+ string "Name of Catalog Binary file"
+ help
+ String used to define name of the CATALOG binary image file
diff --git a/openpower/package/ima-catalog/ima-catalog.mk b/openpower/package/ima-catalog/ima-catalog.mk
new file mode 100644
index 0000000..05707fc
--- /dev/null
+++ b/openpower/package/ima-catalog/ima-catalog.mk
@@ -0,0 +1,22 @@
+################################################################################
+#
+# ima-catalog.mk
+#
+################################################################################
+IMA_CATALOG_VERSION ?= a85e932d8aa769818f00a2185c306ec55251e70b
+IMA_CATALOG_SITE ?= $(call github,open-power,ima-catalog,$(IMA_CATALOG_VERSION))
+IMA_CATALOG_LICENSE = Apache-2.0
+IMA_CATALOG_DEPENDENCIES = host-dtc host-xz
+
+IMA_CATALOG_INSTALL_IMAGES = YES
+IMA_CATALOG_INSTALL_TARGET = NO
+
+define IMA_CATALOG_BUILD_CMDS
+ cd $(@D) && ./build.sh $(HOST_DIR)/usr/bin/ $(BR2_IMA_CATALOG_DTS)
+endef
+
+define IMA_CATALOG_INSTALL_IMAGES_CMDS
+ $(INSTALL) $(@D)/$(BR2_IMA_CATALOG_FILENAME) $(BINARIES_DIR)
+endef
+
+$(eval $(generic-package))
diff --git a/openpower/package/openpower-pnor/Config.in b/openpower/package/openpower-pnor/Config.in
index 3750609..38e425a 100644
--- a/openpower/package/openpower-pnor/Config.in
+++ b/openpower/package/openpower-pnor/Config.in
@@ -7,6 +7,7 @@
select BR2_PACKAGE_OPENPOWER_FFS
select BR2_PACKAGE_OCC
select BR2_PACKAGE_CAPP_UCODE
+ select BRZ_PACKAGE_IMA_CATALOG
select BR2_PACKAGE_ZAIUS_XML if (BR2_OPENPOWER_XML_PACKAGE = "zaius-xml")
select BR2_PACKAGE_WITHERSPOON_XML if (BR2_OPENPOWER_XML_PACKAGE = "witherspoon-xml")
select BR2_PACKAGE_BARRELEYE_XML if (BR2_OPENPOWER_XML_PACKAGE = "barreleye-xml")
diff --git a/openpower/package/openpower-pnor/openpower-pnor.mk b/openpower/package/openpower-pnor/openpower-pnor.mk
index 70e96a9..be5e4dd 100644
--- a/openpower/package/openpower-pnor/openpower-pnor.mk
+++ b/openpower/package/openpower-pnor/openpower-pnor.mk
@@ -8,7 +8,7 @@
# make doesn't care for quotes in the dependencies.
XML_PACKAGE=$(subst $\",,$(BR2_OPENPOWER_XML_PACKAGE))
-OPENPOWER_PNOR_VERSION ?= bf4b7288c38e772f5d71207dc2ed44edd2900571
+OPENPOWER_PNOR_VERSION ?= 36eb2ad2b83a1b959527777cda334de879ba5478
OPENPOWER_PNOR_SITE ?= $(call github,open-power,pnor,$(OPENPOWER_PNOR_VERSION))
OPENPOWER_PNOR_LICENSE = Apache-2.0
@@ -64,7 +64,7 @@
-wink_binary_filename $(BR2_HOSTBOOT_BINARY_WINK_FILENAME) \
-occ_binary_filename $(OCC_STAGING_DIR)/$(BR2_OCC_BIN_FILENAME) \
-capp_binary_filename $(BINARIES_DIR)/$(BR2_CAPP_UCODE_BIN_FILENAME) \
- -ima_catalog_filename $(BR2_IMA_CATALOG_FILENAME) \
+ -ima_catalog_binary_filename $(BINARIES_DIR)/$(BR2_IMA_CATALOG_FILENAME) \
-openpower_version_filename $(OPENPOWER_PNOR_VERSION_FILE) \
-payload $(BINARIES_DIR)/$(BR2_SKIBOOT_LID_NAME) \
$(if ($(BR2_OPENPOWER_PNOR_XZ_ENABLED),y),-xz_compression)
@@ -83,7 +83,6 @@
-sbec_binary_filename $(BR2_HOSTBOOT_BINARY_SBEC_FILENAME) \
-wink_binary_filename $(BR2_HOSTBOOT_BINARY_WINK_FILENAME) \
-occ_binary_filename $(OCC_STAGING_DIR)/$(BR2_OCC_BIN_FILENAME) \
- -ima_catalog_filename $(BR2_IMA_CATALOG_ECC_FILENAME) \
-targeting_binary_filename $(BR2_OPENPOWER_TARGETING_ECC_FILENAME) \
-openpower_version_filename $(OPENPOWER_PNOR_VERSION_FILE)