meta-quanta: gbs: add GBS system initial script
system initial script:
1. get MB/HSBP/Fan boards REV/SKU ID
2. read FRUs on PE slots
3. reset PHY
4. SATA power enable
5. check HSBP/Fan board cables present
5. verfiy BIOS image
6. Host power on
7. gpio persistence
Signed-off-by: George Hung <george.hung@quantatw.com>
Change-Id: Ia28cbf93b04d09f519a0fa5fe8f8bda0b2eed347
diff --git a/meta-gbs/recipes-gbs/gbs-sysinit/gbs-sysinit.bb b/meta-gbs/recipes-gbs/gbs-sysinit/gbs-sysinit.bb
new file mode 100644
index 0000000..68a9cf1
--- /dev/null
+++ b/meta-gbs/recipes-gbs/gbs-sysinit/gbs-sysinit.bb
@@ -0,0 +1,31 @@
+SUMMARY = "Phosphor OpenBMC Quanta GBS System Initialization Service"
+DESCRIPTION = "Phosphor OpenBMC Quanta GBS System Init"
+PR = "r1"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10"
+
+inherit systemd
+
+DEPENDS += "systemd"
+RDEPENDS_${PN} += "bash"
+RDEPENDS_${PN} += "libsystemd"
+RDEPENDS_${PN} += "jq"
+
+SRC_URI = "file://gbs-sysinit.sh \
+ file://gbs-gpio-common.sh \
+ file://gbs-sysinit.service \
+ "
+
+do_install () {
+ install -d ${D}${bindir}
+ install -m 0755 ${WORKDIR}/gbs-sysinit.sh ${D}${bindir}/
+
+ install -d ${D}${libexecdir}
+ install -m 0755 ${WORKDIR}/gbs-gpio-common.sh ${D}${libexecdir}/
+
+ install -d ${D}${systemd_system_unitdir}
+ install -m 0644 ${WORKDIR}/gbs-sysinit.service ${D}${systemd_system_unitdir}
+}
+
+SYSTEMD_PACKAGES = "${PN}"
+SYSTEMD_SERVICE_${PN} = "gbs-sysinit.service"