diff options
3 files changed, 39 insertions, 1 deletions
diff --git a/meta-ibm/recipes-phosphor/packagegroups/packagegroup-obmc-apps.bbappend b/meta-ibm/recipes-phosphor/packagegroups/packagegroup-obmc-apps.bbappend index 75d10e7f70..ccb014d173 100644 --- a/meta-ibm/recipes-phosphor/packagegroups/packagegroup-obmc-apps.bbappend +++ b/meta-ibm/recipes-phosphor/packagegroups/packagegroup-obmc-apps.bbappend @@ -13,6 +13,7 @@ POWER_SERVICE_PACKAGES_P10 = " \ phosphor-power-utils \ phosphor-power \ phosphor-power-regulators \ + phosphor-power-systemd-links-regulators \ phosphor-power-psu-monitor \ " diff --git a/meta-phosphor/recipes-phosphor/power/phosphor-power-systemd-links-regulators.bb b/meta-phosphor/recipes-phosphor/power/phosphor-power-systemd-links-regulators.bb new file mode 100644 index 0000000000..6240fda48a --- /dev/null +++ b/meta-phosphor/recipes-phosphor/power/phosphor-power-systemd-links-regulators.bb @@ -0,0 +1,37 @@ +SUMMARY = "Phosphor Power Regulator services installation" +LICENSE = "Apache-2.0" +LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10" +PR = "r1" + +inherit allarch + +RDEPENDS:${PN} += "phosphor-power-regulators" + +pkg_prerm:${PN}() { + LINK="$D$systemd_system_unitdir/obmc-chassis-poweron@${i}.target.requires/phosphor-regulators-config.service" + rm $LINK + + LINK="$D$systemd_system_unitdir/obmc-chassis-poweron@${i}.target.wants/phosphor-regulators-monitor-enable.service" + rm $LINK + + LINK="$D$systemd_system_unitdir/obmc-chassis-poweroff@${i}.target.wants/phosphor-regulators-monitor-disable.service" + rm $LINK +} +pkg_postinst:${PN}() { + mkdir -p $D$systemd_system_unitdir/obmc-chassis-poweron@0.target.requires + LINK="$D$systemd_system_unitdir/obmc-chassis-poweron@0.target.requires/phosphor-regulators-config.service" + TARGET="../phosphor-regulators-config.service" + ln -s $TARGET $LINK + + mkdir -p $D$systemd_system_unitdir/obmc-chassis-poweron@0.target.wants + LINK="$D$systemd_system_unitdir/obmc-chassis-poweron@0.target.wants/phosphor-regulators-monitor-enable.service" + TARGET="../phosphor-regulators-monitor-enable.service" + ln -s $TARGET $LINK + + mkdir -p $D$systemd_system_unitdir/obmc-chassis-poweroff@0.target.wants + LINK="$D$systemd_system_unitdir/obmc-chassis-poweroff@0.target.wants/phosphor-regulators-monitor-disable.service" + TARGET="../phosphor-regulators-monitor-disable.service" + ln -s $TARGET $LINK +} + +ALLOW_EMPTY:${PN} = "1" diff --git a/meta-phosphor/recipes-phosphor/power/phosphor-power.inc b/meta-phosphor/recipes-phosphor/power/phosphor-power.inc index d60607754d..18287214b5 100644 --- a/meta-phosphor/recipes-phosphor/power/phosphor-power.inc +++ b/meta-phosphor/recipes-phosphor/power/phosphor-power.inc @@ -2,4 +2,4 @@ HOMEPAGE = "https://github.com/openbmc/phosphor-power" LICENSE = "Apache-2.0" LIC_FILES_CHKSUM = "file://${S}/LICENSE;md5=e3fc50a88d0a364313df4b21ef20c29e" SRC_URI += "git://github.com/openbmc/phosphor-power;branch=master;protocol=https" -SRCREV = "aded7a0d4401ebd9f2d7d0fd089961aa33818224" +SRCREV = "8c90f319d579357e671c7ebbf8b845f680bb1aa2" |