meta-fii/meta-kudo: support the bmc update feature
1. add kudo-bmc-update package to support bmc update
Signed-off-by: Lancelot Kao <lancelot.kao@fii-usa.com>
Change-Id: I7889d5219fcf376cd5bbcbc92268104745d2c886
Signed-off-by: XP Chen <xiao-peng.chen@fii-na.com>
Signed-off-by: Mohaimen Alsamarai <Mohaimen.alsamarai@fii-na.com>
diff --git a/meta-fii/meta-kudo/recipes-kudo/kudo-fw-utility/kudo-bmc-update.bb b/meta-fii/meta-kudo/recipes-kudo/kudo-fw-utility/kudo-bmc-update.bb
new file mode 100644
index 0000000..184f3ef
--- /dev/null
+++ b/meta-fii/meta-kudo/recipes-kudo/kudo-fw-utility/kudo-bmc-update.bb
@@ -0,0 +1,20 @@
+SUMMARY = "Phosphor OpenBMC Kudo BMC Firmware Upgrade Command"
+DESCRIPTION = "Phosphor OpenBMC Kudo BMC Firmware Upgrade Comman Daemon"
+
+PR = "r1"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10"
+
+DEPENDS += "phosphor-ipmi-flash"
+RDEPENDS_${PN} += "bash"
+
+FILES_${PN} += "${datadir}/phosphor-ipmi-flash/config-bmc.json"
+
+SRC_URI_append_kudo = " \
+ file://config-bmc.json \
+ "
+
+do_install () {
+ install -d ${D}${datadir}/phosphor-ipmi-flash
+ install -m 0644 ${WORKDIR}/config-bmc.json ${D}${datadir}/phosphor-ipmi-flash
+}
diff --git a/meta-fii/meta-kudo/recipes-kudo/kudo-fw-utility/kudo-bmc-update/config-bmc.json b/meta-fii/meta-kudo/recipes-kudo/kudo-fw-utility/kudo-bmc-update/config-bmc.json
new file mode 100644
index 0000000..5aefeb3
--- /dev/null
+++ b/meta-fii/meta-kudo/recipes-kudo/kudo-fw-utility/kudo-bmc-update/config-bmc.json
@@ -0,0 +1,20 @@
+[{
+ "blob": "/flash/image",
+ "handler": {
+ "type": "file",
+ "path": "/run/initramfs/image-bmc"
+ },
+ "actions": {
+ "preparation": {
+ "type": "skip"
+ },
+ "verification": {
+ "type": "skip"
+ },
+ "update": {
+ "type": "systemd",
+ "unit": "reboot.target",
+ "mode": "replace-irreversibly"
+ }
+ }
+}]
diff --git a/meta-fii/meta-kudo/recipes-kudo/packagegroups/packagegroup-kudo-apps.bb b/meta-fii/meta-kudo/recipes-kudo/packagegroups/packagegroup-kudo-apps.bb
index 8601f96..17bde95 100644
--- a/meta-fii/meta-kudo/recipes-kudo/packagegroups/packagegroup-kudo-apps.bb
+++ b/meta-fii/meta-kudo/recipes-kudo/packagegroups/packagegroup-kudo-apps.bb
@@ -28,4 +28,5 @@
RDEPENDS_${PN}-kudo-fw = " \
kudo-fw \
kudo-bios-update \
+ kudo-bmc-update \
"