diff options
Diffstat (limited to 'meta-fii/meta-kudo/recipes-kudo')
5 files changed, 89 insertions, 0 deletions
diff --git a/meta-fii/meta-kudo/recipes-kudo/hotswap-power-cycle/files/hotswap-power-cycle.service b/meta-fii/meta-kudo/recipes-kudo/hotswap-power-cycle/files/hotswap-power-cycle.service new file mode 100644 index 000000000..f9f03e7c3 --- /dev/null +++ b/meta-fii/meta-kudo/recipes-kudo/hotswap-power-cycle/files/hotswap-power-cycle.service @@ -0,0 +1,15 @@ +[Unit] +Description=Power Cycle by Hotswap Controller + +[Service] +Environment= PSU_HARDRESET_DELAY=1 +EnvironmentFile=-/run/psu_timedelay +ExecStartPre=sleep $PSU_HARDRESET_DELAY +ExecStart=gpioset 2 30=1 +Restart=no +Type=oneshot +RemainAfterExit=true +StandardOutput=syslog + +[Install] +WantedBy=gbmc-psu-hardreset.target diff --git a/meta-fii/meta-kudo/recipes-kudo/hotswap-power-cycle/hotswap-power-cycle.bb b/meta-fii/meta-kudo/recipes-kudo/hotswap-power-cycle/hotswap-power-cycle.bb new file mode 100644 index 000000000..d01b898a9 --- /dev/null +++ b/meta-fii/meta-kudo/recipes-kudo/hotswap-power-cycle/hotswap-power-cycle.bb @@ -0,0 +1,21 @@ +SUMMARY = "Power Cycle by Hotswap Controller" +DESCRIPTION = "Power Cycle by Hotswap Controller Daemon" +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" + +FILESEXTRAPATHS_prepend := "${THISDIR}/files:" +SRC_URI_append_kudo = " file://hotswap-power-cycle.service" + +do_install() { + install -d ${D}${systemd_unitdir}/system/ + install -m 0644 ${WORKDIR}/hotswap-power-cycle.service ${D}${systemd_unitdir}/system/hotswap-power-cycle.service +} + +SYSTEMD_PACKAGES = "${PN}" +SYSTEMD_SERVICE_${PN} = " hotswap-power-cycle.service" diff --git a/meta-fii/meta-kudo/recipes-kudo/kudo-system/kudo-entity-association-map.bb b/meta-fii/meta-kudo/recipes-kudo/kudo-system/kudo-entity-association-map.bb new file mode 100644 index 000000000..85006dadc --- /dev/null +++ b/meta-fii/meta-kudo/recipes-kudo/kudo-system/kudo-entity-association-map.bb @@ -0,0 +1,16 @@ +UMMARY = "Kudo IPMI Entity association mapping." +PR = "r1" +LICENSE = "Apache-2.0" +LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10" + +SRC_URI += "file://kudo_entity_association_map.json" + +FILES_${PN} = " \ + ${datadir}/ipmi-entity-association/entity_association_map.json \ + " + +do_install() { + install -d ${D}${datadir}/ipmi-entity-association + install -m 0644 -D ${WORKDIR}/kudo_entity_association_map.json \ + ${D}${datadir}/ipmi-entity-association/entity_association_map.json +} diff --git a/meta-fii/meta-kudo/recipes-kudo/kudo-system/kudo-entity-association-map/kudo_entity_association_map.json b/meta-fii/meta-kudo/recipes-kudo/kudo-system/kudo-entity-association-map/kudo_entity_association_map.json new file mode 100644 index 000000000..2530684c0 --- /dev/null +++ b/meta-fii/meta-kudo/recipes-kudo/kudo-system/kudo-entity-association-map/kudo_entity_association_map.json @@ -0,0 +1,35 @@ +{ + "system_board": [ + {"instance": 1, "name": "/"} + ], + "system_internal_expansion_board": [ + {"instance": 1, "name": "/"} + ], + "power_system_board": [ + {"instance": 1, "name": "/"} + ], + "add_in_card": [ + {"instance": 0, "name": "/PE0"}, + {"instance": 1, "name": "/PE1"}, + {"instance": 2, "name": "/PE2"}, + {"instance": 3, "name": "/PE3"}, + {"instance": 4, "name": "/PE4"}, + {"instance": 5, "name": "/PE5"}, + {"instance": 6, "name": "/PE6"}, + {"instance": 7, "name": "/PE7"} + ], + "fan": [ + {"instance": 0, "name": "/fan0"}, + {"instance": 1, "name": "/fan1"}, + {"instance": 2, "name": "/fan2"}, + {"instance": 3, "name": "/fan3"}, + {"instance": 4, "name": "/fan4"}, + {"instance": 5, "name": "/fan5"} + ], + "cooling_unit": [ + {"instance": 0, "name": "/ZONE0"}, + {"instance": 1, "name": "/ZONE1"}, + {"instance": 2, "name": "/ZONE2"}, + {"instance": 3, "name": "/ZONE3"} + ] +} 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 f64373e89..af6d08085 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 @@ -20,6 +20,8 @@ RDEPENDS_${PN}-kudo-system = " \ ethtool \ memtester \ loadsvf \ + kudo-entity-association-map \ + hotswap-power-cycle \ obmc-console \ usb-network \ ncsid \ |