summaryrefslogtreecommitdiff
path: root/meta-phosphor
diff options
context:
space:
mode:
authorAndrew Geissler <geissonator@yahoo.com>2020-01-14 23:21:24 +0300
committerBrad Bishop <bradleyb@fuzziesquirrel.com>2020-02-10 22:45:17 +0300
commit024c25d6aa71758f94291cd03ac2fc0c77bd1aff (patch)
tree2797c0b3dcd93a0d45d7568f1b863892b44b0286 /meta-phosphor
parent559224c963de5f66075afa3e76c9e947af904267 (diff)
downloadopenbmc-024c25d6aa71758f94291cd03ac2fc0c77bd1aff.tar.xz
move state systemd files to phosphor-state-manager
The OpenBMC target and service systemd files have been moved to phosphor-state-manager. This commit will move to those changes and delete the files from meta-phosphor. Bump Details: phosphor-state-manager: srcrev bump 4640d48e99..c101157e5b Andrew Geissler (3): move state manager service files into its repo ensure reboot service runs after host stopped move openbmc targets into this repo Tested: - Verified data files and services were all in expected location within witherspoon QEMU run - Verified openbmc systemd target were all in expected location within witherspoon QEMU run - HW CI will verify targets are still working as expected (From meta-phosphor rev: 77cfb0f54a23c3efeba26100110e54055accd16d) Change-Id: If5048f63d07ce45b4bc1f2303d1e87275324a818 Signed-off-by: Andrew Geissler <geissonator@yahoo.com> Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
Diffstat (limited to 'meta-phosphor')
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets.bb85
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-hard-poweroff@.target11
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-powered-off@.target9
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-poweroff@.target9
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-poweron@.target12
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-powerreset@.target7
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fan-control-ready@.target4
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fan-control.target4
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fan-watchdog-takeover.target6
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fans-ready.target4
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-crash@.target4
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-quiesce@.target6
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-reboot@.target8
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-reset-running@.target5
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-reset@.target7
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-shutdown@.target6
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-start-pre@.target7
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-start@.target8
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-started@.target7
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-starting@.target7
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-startmin@.target8
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stop-pre@.target8
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stop@.target9
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stopped@.target9
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stopping@.target10
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-timeout@.target4
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-mapper.target4
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-off@.target7
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-on@.target7
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-reset-on@.target5
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-start-pre@.target7
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-start@.target7
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-stop-pre@.target9
-rw-r--r--meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-stop@.target9
-rw-r--r--meta-phosphor/recipes-core/systemd/systemd_%.bbappend1
-rw-r--r--meta-phosphor/recipes-phosphor/ipmi/phosphor-ipmi-host_git.bb2
-rw-r--r--meta-phosphor/recipes-phosphor/state/files/obmc/phosphor-reboot-host/reboot.conf1
-rw-r--r--meta-phosphor/recipes-phosphor/state/files/phosphor-discover-system-state@.service19
-rw-r--r--meta-phosphor/recipes-phosphor/state/files/phosphor-reboot-host@.service18
-rw-r--r--meta-phosphor/recipes-phosphor/state/files/phosphor-reset-host-check@.service19
-rw-r--r--meta-phosphor/recipes-phosphor/state/files/phosphor-reset-host-reboot-attempts@.service13
-rw-r--r--meta-phosphor/recipes-phosphor/state/files/phosphor-reset-host-running@.service13
-rw-r--r--meta-phosphor/recipes-phosphor/state/files/phosphor-reset-sensor-states@.service15
-rw-r--r--meta-phosphor/recipes-phosphor/state/files/xyz.openbmc_project.State.BMC.service16
-rw-r--r--meta-phosphor/recipes-phosphor/state/files/xyz.openbmc_project.State.Chassis.service16
-rw-r--r--meta-phosphor/recipes-phosphor/state/files/xyz.openbmc_project.State.Host.service18
-rw-r--r--meta-phosphor/recipes-phosphor/state/phosphor-state-manager_git.bb89
47 files changed, 90 insertions, 469 deletions
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets.bb b/meta-phosphor/recipes-core/systemd/obmc-targets.bb
index 4146dba5c..2ab0c22c6 100644
--- a/meta-phosphor/recipes-core/systemd/obmc-targets.bb
+++ b/meta-phosphor/recipes-core/systemd/obmc-targets.bb
@@ -5,86 +5,5 @@ PR = "r1"
LICENSE = "Apache-2.0"
LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10"
-inherit obmc-phosphor-systemd
-inherit allarch
-
-# Chassis power synchronization targets
-# - start-pre: Services to run before we start power on process
-# - start: Services to run to do the chassis power on
-# - on: Services to run once power is on
-# - stop-pre,stop,off: Same as above but applied to powering off
-# - reset-on: Services to check if chassis power is on after bmc reset
-CHASSIS_SYNCH_TARGETS = "start-pre start on stop-pre stop off reset-on"
-
-# Chassis action power targets
-# - on: Services to run to power on the chassis
-# - off: Services to run to power off the chassis
-# - powered-off: Services to run once chassis power is off
-# - reset: Services to check chassis power state and update chassis "on" target
-# - hard-off: Services to force an immediate power off of the chassis
-CHASSIS_ACTION_TARGETS = "poweron poweroff powered-off powerreset hard-poweroff"
-
-# Track all host synchronization point targets
-# - start-pre: Services to run before we start host boot
-# - starting: Services to run to do the host boot
-# - started: Services to run once the host is booted
-# - stop-pre,stopping,stopped: Same as above but applied to shutting down the host
-# - reset-running: Services to check if host is running after bmc reset
-HOST_SYNCH_TARGETS = "start-pre starting started stop-pre stopping stopped reset-running"
-
-# Track all host action targets
-# - start: Will run startmin target, this target used for any additional
-# services that user needs for an initial power on of host.
-# For example, resetting the host reboot count could be put in
-# this target so on any fresh power on, this count is reset.
-# - startmin: Minimum services required to start the host. This target will
-# be called by reboot and start target.
-# - stop: Services to run to shutdown the host
-# - quiesce: Target to enter on host boot failure
-# - shutdown: Tell host to shutdown, then stop system
-# - reset: Services to check if host is running and update host "start" target
-# - crash: Target to run when host crashes. it is very much similar to
-# quiesce target but the only delta is that this target contains
-# multiple services and one of them is the quiesce target.
-# - timeout: Target to run when host watchdog times out
-# - reboot: Reboot the host
-HOST_ACTION_TARGETS = "start startmin stop quiesce reset shutdown crash timeout reboot"
-
-CHASSIS_SYNCH_FMT = "obmc-power-{0}@.target"
-CHASSIS_ACTION_FMT = "obmc-chassis-{0}@.target"
-HOST_SYNCH_FMT = "obmc-host-{0}@.target"
-HOST_ACTION_FMT = "obmc-host-{0}@.target"
-
-CHASSIS_LINK_SYNCH_FMT = "${CHASSIS_SYNCH_FMT}:obmc-power-{0}@{1}.target"
-CHASSIS_LINK_ACTION_FMT = "${CHASSIS_ACTION_FMT}:obmc-chassis-{0}@{1}.target"
-HOST_LINK_SYNCH_FMT = "${HOST_SYNCH_FMT}:obmc-host-{0}@{1}.target"
-HOST_LINK_ACTION_FMT = "${HOST_ACTION_FMT}:obmc-host-{0}@{1}.target"
-FAN_LINK_FMT = "obmc-fan-control-ready@.target:obmc-fan-control-ready@{0}.target"
-
-# Targets to be executed on checkstop and watchdog timeout
-HOST_ERROR_TARGETS = "crash timeout"
-
-QUIESCE_TMPL = "obmc-host-quiesce@.target"
-CRASH_TIMEOUT_TGTFMT = "obmc-host-{0}@{1}.target"
-QUIESCE_INSTFMT = "obmc-host-quiesce@{1}.target"
-QUIESCE_FMT = "../${QUIESCE_TMPL}:${CRASH_TIMEOUT_TGTFMT}.wants/${QUIESCE_INSTFMT}"
-
-SYSTEMD_SERVICE_${PN} += " \
- obmc-mapper.target \
- obmc-fans-ready.target \
- obmc-fan-control.target \
- obmc-fan-control-ready@.target \
- obmc-fan-watchdog-takeover.target \
- "
-
-SYSTEMD_SERVICE_${PN} += "${@compose_list(d, 'CHASSIS_SYNCH_FMT', 'CHASSIS_SYNCH_TARGETS')}"
-SYSTEMD_SERVICE_${PN} += "${@compose_list(d, 'CHASSIS_ACTION_FMT', 'CHASSIS_ACTION_TARGETS')}"
-SYSTEMD_SERVICE_${PN} += "${@compose_list(d, 'HOST_SYNCH_FMT', 'HOST_SYNCH_TARGETS')}"
-SYSTEMD_SERVICE_${PN} += "${@compose_list(d, 'HOST_ACTION_FMT', 'HOST_ACTION_TARGETS')}"
-
-SYSTEMD_LINK_${PN} += "${@compose_list(d, 'CHASSIS_LINK_SYNCH_FMT', 'CHASSIS_SYNCH_TARGETS', 'OBMC_CHASSIS_INSTANCES')}"
-SYSTEMD_LINK_${PN} += "${@compose_list(d, 'CHASSIS_LINK_ACTION_FMT', 'CHASSIS_ACTION_TARGETS', 'OBMC_CHASSIS_INSTANCES')}"
-SYSTEMD_LINK_${PN} += "${@compose_list(d, 'HOST_LINK_SYNCH_FMT', 'HOST_SYNCH_TARGETS', 'OBMC_HOST_INSTANCES')}"
-SYSTEMD_LINK_${PN} += "${@compose_list(d, 'HOST_LINK_ACTION_FMT', 'HOST_ACTION_TARGETS', 'OBMC_HOST_INSTANCES')}"
-SYSTEMD_LINK_${PN} += "${@compose_list(d, 'FAN_LINK_FMT', 'OBMC_CHASSIS_INSTANCES')}"
-SYSTEMD_LINK_${PN} += "${@compose_list(d, 'QUIESCE_FMT', 'HOST_ERROR_TARGETS', 'OBMC_HOST_INSTANCES')}"
+# TODO Will be removed once dependencies in other layers on this recipe are moved
+DEPENDS += "phosphor-state-manager"
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-hard-poweroff@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-hard-poweroff@.target
deleted file mode 100644
index a033f6050..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-hard-poweroff@.target
+++ /dev/null
@@ -1,11 +0,0 @@
-[Unit]
-Description=Chassis%i (Hard Power Off)
-Wants=multi-user.target
-After=multi-user.target
-Wants=mapper-wait@-xyz-openbmc_project-state-chassis%i.service
-After=mapper-wait@-xyz-openbmc_project-state-chassis%i.service
-Conflicts=obmc-chassis-poweron@%i.target
-Conflicts=obmc-chassis-powerreset@%i.target
-Conflicts=obmc-host-shutdown@%i.target
-Conflicts=xyz.openbmc_project.Ipmi.Internal.SoftPowerOff.service
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-powered-off@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-powered-off@.target
deleted file mode 100644
index c043f3744..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-powered-off@.target
+++ /dev/null
@@ -1,9 +0,0 @@
-[Unit]
-Description=Chassis%i (Powered Off)
-Wants=multi-user.target
-After=multi-user.target
-Wants=mapper-wait@-xyz-openbmc_project-state-chassis%i.service
-After=mapper-wait@-xyz-openbmc_project-state-chassis%i.service
-Conflicts=obmc-chassis-poweron@%i.target
-Conflicts=obmc-chassis-powerreset@%i.target
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-poweroff@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-poweroff@.target
deleted file mode 100644
index 69209e64a..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-poweroff@.target
+++ /dev/null
@@ -1,9 +0,0 @@
-[Unit]
-Description=Chassis%i (Power Off)
-Wants=multi-user.target
-After=multi-user.target
-Wants=mapper-wait@-xyz-openbmc_project-state-chassis%i.service
-After=mapper-wait@-xyz-openbmc_project-state-chassis%i.service
-Conflicts=obmc-chassis-poweron@%i.target
-Conflicts=obmc-chassis-powerreset@%i.target
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-poweron@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-poweron@.target
deleted file mode 100644
index cd7c2fc49..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-poweron@.target
+++ /dev/null
@@ -1,12 +0,0 @@
-[Unit]
-Description=Chassis%i (Power On)
-Wants=multi-user.target
-After=multi-user.target
-Wants=mapper-wait@-xyz-openbmc_project-state-chassis%i.service
-After=mapper-wait@-xyz-openbmc_project-state-chassis%i.service
-Wants=mapper-subtree-remove@-xyz-openbmc\x5fproject-software\x3Axyz.openbmc_project.Software.ActivationBlocksTransition.service
-After=mapper-subtree-remove@-xyz-openbmc\x5fproject-software\x3Axyz.openbmc_project.Software.ActivationBlocksTransition.service
-Conflicts=obmc-chassis-poweroff@%i.target
-RefuseManualStop=yes
-OnFailure=obmc-chassis-poweroff@%i.target
-OnFailureJobMode=flush
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-powerreset@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-powerreset@.target
deleted file mode 100644
index 03036f301..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-chassis-powerreset@.target
+++ /dev/null
@@ -1,7 +0,0 @@
-[Unit]
-Description=Chassis%i (Reset Check)
-Conflicts=obmc-chassis-poweroff@%i.target
-RefuseManualStop=yes
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fan-control-ready@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fan-control-ready@.target
deleted file mode 100644
index e041a5508..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fan-control-ready@.target
+++ /dev/null
@@ -1,4 +0,0 @@
-[Unit]
-Description=Fan Control Ready
-RefuseManualStop=yes
-Conflicts=obmc-chassis-powered-off@%i.target
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fan-control.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fan-control.target
deleted file mode 100644
index 50665db4a..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fan-control.target
+++ /dev/null
@@ -1,4 +0,0 @@
-[Unit]
-Description=Fan Control
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fan-watchdog-takeover.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fan-watchdog-takeover.target
deleted file mode 100644
index 803408334..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fan-watchdog-takeover.target
+++ /dev/null
@@ -1,6 +0,0 @@
-#The system implementation should start this target when dynamic fan control
-#is no longer desired or possible. It should also add units to this target
-#that enabled continued operation after dynamic fan control is no longer
-#desired or possible.
-[Unit]
-Description=Fan watchdog takeover target
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fans-ready.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fans-ready.target
deleted file mode 100644
index 59e61c626..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-fans-ready.target
+++ /dev/null
@@ -1,4 +0,0 @@
-[Unit]
-Description=Fans Ready
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-crash@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-crash@.target
deleted file mode 100644
index ea3798b52..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-crash@.target
+++ /dev/null
@@ -1,4 +0,0 @@
-[Unit]
-Description=Host instance %i crashed
-Conflicts=obmc-chassis-poweroff@%i.target
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-quiesce@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-quiesce@.target
deleted file mode 100644
index 900995b9f..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-quiesce@.target
+++ /dev/null
@@ -1,6 +0,0 @@
-[Unit]
-Description=Quiesce Target
-Wants=multi-user.target
-After=multi-user.target
-RefuseManualStop=yes
-Conflicts=obmc-chassis-poweroff@%i.target
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-reboot@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-reboot@.target
deleted file mode 100644
index 8e749e6e1..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-reboot@.target
+++ /dev/null
@@ -1,8 +0,0 @@
-[Unit]
-Description=Reboot Host%i
-Wants=multi-user.target
-After=multi-user.target
-Conflicts=obmc-host-startmin@%i.target
-RefuseManualStop=yes
-OnFailure=obmc-chassis-poweroff@%i.target
-OnFailureJobMode=flush
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-reset-running@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-reset-running@.target
deleted file mode 100644
index 94bb2b130..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-reset-running@.target
+++ /dev/null
@@ -1,5 +0,0 @@
-[Unit]
-Description=Host%i running after reset
-Conflicts=obmc-host-stop@%i.target
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-reset@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-reset@.target
deleted file mode 100644
index 84d870163..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-reset@.target
+++ /dev/null
@@ -1,7 +0,0 @@
-[Unit]
-Description=Host%i (Reset Check)
-Conflicts=obmc-host-stop@%i.target
-RefuseManualStop=yes
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-shutdown@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-shutdown@.target
deleted file mode 100644
index 012d364a1..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-shutdown@.target
+++ /dev/null
@@ -1,6 +0,0 @@
-[Unit]
-Description=Power%i Host Off
-Wants=multi-user.target
-RefuseManualStop=yes
-OnFailure=obmc-chassis-poweroff@%i.target
-OnFailureJobMode=flush
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-start-pre@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-start-pre@.target
deleted file mode 100644
index fe5514618..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-start-pre@.target
+++ /dev/null
@@ -1,7 +0,0 @@
-[Unit]
-Description=Start Host%i (Pre)
-Wants=multi-user.target
-After=multi-user.target
-Conflicts=obmc-host-stop@%i.target
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-start@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-start@.target
deleted file mode 100644
index ff1486b91..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-start@.target
+++ /dev/null
@@ -1,8 +0,0 @@
-[Unit]
-Description=Start Host%i
-Wants=multi-user.target
-After=multi-user.target
-Conflicts=obmc-host-stop@%i.target
-RefuseManualStop=yes
-OnFailure=obmc-host-quiesce@%i.target
-OnFailureJobMode=flush
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-started@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-started@.target
deleted file mode 100644
index fcd51be89..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-started@.target
+++ /dev/null
@@ -1,7 +0,0 @@
-[Unit]
-Description=Host%i (Started)
-Wants=multi-user.target
-After=obmc-host-starting@%i.target
-Conflicts=obmc-host-stop@%i.target
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-starting@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-starting@.target
deleted file mode 100644
index 52e7bea83..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-starting@.target
+++ /dev/null
@@ -1,7 +0,0 @@
-[Unit]
-Description=Host%i (Starting)
-Wants=multi-user.target
-After=obmc-host-start-pre@%i.target
-Conflicts=obmc-host-stop@%i.target
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-startmin@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-startmin@.target
deleted file mode 100644
index 88ccb2595..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-startmin@.target
+++ /dev/null
@@ -1,8 +0,0 @@
-[Unit]
-Description=Start Host%i Minimum
-Wants=multi-user.target
-After=multi-user.target
-Conflicts=obmc-host-stop@%i.target
-RefuseManualStop=yes
-OnFailure=obmc-host-quiesce@%i.target
-OnFailureJobMode=flush
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stop-pre@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stop-pre@.target
deleted file mode 100644
index 9fc3296b1..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stop-pre@.target
+++ /dev/null
@@ -1,8 +0,0 @@
-[Unit]
-Description=Stop Host%i (Pre)
-Wants=multi-user.target
-After=multi-user.target
-Before=obmc-host-stopping@%i.target
-Conflicts=obmc-host-startmin@%i.target
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stop@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stop@.target
deleted file mode 100644
index 496fd5b3f..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stop@.target
+++ /dev/null
@@ -1,9 +0,0 @@
-[Unit]
-Description=Stop Host%i
-Wants=multi-user.target
-After=multi-user.target
-After=obmc-chassis-poweroff@%i.target
-Conflicts=obmc-host-startmin@%i.target
-RefuseManualStop=yes
-OnFailure=obmc-chassis-poweroff@%i.target
-OnFailureJobMode=flush
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stopped@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stopped@.target
deleted file mode 100644
index c9689790b..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stopped@.target
+++ /dev/null
@@ -1,9 +0,0 @@
-[Unit]
-Description=Host%i (Stopped)
-Wants=multi-user.target
-Wants=obmc-host-stopping@%i.target
-After=obmc-host-stopping@%i.target
-Before=obmc-power-stop-pre@%i.target
-Conflicts=obmc-host-startmin@%i.target
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stopping@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stopping@.target
deleted file mode 100644
index 41c4b7f95..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-stopping@.target
+++ /dev/null
@@ -1,10 +0,0 @@
-[Unit]
-Description=Host%i (Stopping)
-Wants=multi-user.target
-Wants=obmc-host-stop-pre@%i.target
-After=obmc-host-stop-pre@%i.target
-Before=obmc-host-stopped@%i.target
-Conflicts=obmc-host-startmin@%i.target
-Conflicts=obmc-host-starting@%i.target
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-timeout@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-timeout@.target
deleted file mode 100644
index b87507bf1..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-host-timeout@.target
+++ /dev/null
@@ -1,4 +0,0 @@
-[Unit]
-Description=Host instance %i timed out refreshing Watchdog
-Conflicts=obmc-chassis-poweroff@%i.target
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-mapper.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-mapper.target
deleted file mode 100644
index 5e52f4cd5..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-mapper.target
+++ /dev/null
@@ -1,4 +0,0 @@
-[Unit]
-Description=Phosphor Object Mapper
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-off@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-off@.target
deleted file mode 100644
index 7fda29b1e..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-off@.target
+++ /dev/null
@@ -1,7 +0,0 @@
-[Unit]
-Description=Power%i (Off)
-Wants=multi-user.target
-After=obmc-power-stop@%i.target
-Conflicts=obmc-chassis-poweron@%i.target
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-on@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-on@.target
deleted file mode 100644
index b55d90907..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-on@.target
+++ /dev/null
@@ -1,7 +0,0 @@
-[Unit]
-Description=Power%i (On)
-Wants=multi-user.target
-After=obmc-power-start@%i.target
-Conflicts=obmc-chassis-poweroff@%i.target
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-reset-on@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-reset-on@.target
deleted file mode 100644
index d24d401bf..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-reset-on@.target
+++ /dev/null
@@ -1,5 +0,0 @@
-[Unit]
-Description=Chassis%i power on after reset
-Conflicts=obmc-chassis-poweroff@%i.target
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-start-pre@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-start-pre@.target
deleted file mode 100644
index 2b5fdbbd7..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-start-pre@.target
+++ /dev/null
@@ -1,7 +0,0 @@
-[Unit]
-Description=Power%i On (Pre)
-Wants=multi-user.target
-After=multi-user.target
-Conflicts=obmc-chassis-poweroff@%i.target
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-start@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-start@.target
deleted file mode 100644
index 720548e2d..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-start@.target
+++ /dev/null
@@ -1,7 +0,0 @@
-[Unit]
-Description=Power%i On
-After=obmc-power-start-pre@%i.target
-Wants=multi-user.target
-Conflicts=obmc-chassis-poweroff@%i.target
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-stop-pre@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-stop-pre@.target
deleted file mode 100644
index 5460914b2..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-stop-pre@.target
+++ /dev/null
@@ -1,9 +0,0 @@
-[Unit]
-Description=Power%i Off (Pre)
-Wants=multi-user.target
-After=multi-user.target
-Wants=obmc-host-stopped@%i.target
-After=obmc-host-stopped@%i.target
-Conflicts=obmc-chassis-poweron@%i.target
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-stop@.target b/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-stop@.target
deleted file mode 100644
index fc22eb1f3..000000000
--- a/meta-phosphor/recipes-core/systemd/obmc-targets/obmc-power-stop@.target
+++ /dev/null
@@ -1,9 +0,0 @@
-[Unit]
-Description=Power%i Off
-Wants=obmc-power-stop-pre@%i.target
-After=obmc-power-stop-pre@%i.target
-Wants=multi-user.target
-Conflicts=obmc-chassis-poweron@%i.target
-Conflicts=fsi-disable.service
-RefuseManualStart=yes
-RefuseManualStop=yes
diff --git a/meta-phosphor/recipes-core/systemd/systemd_%.bbappend b/meta-phosphor/recipes-core/systemd/systemd_%.bbappend
index a813a4557..de1aa2e1d 100644
--- a/meta-phosphor/recipes-core/systemd/systemd_%.bbappend
+++ b/meta-phosphor/recipes-core/systemd/systemd_%.bbappend
@@ -8,7 +8,6 @@ FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
SRC_URI += "file://default.network"
SRC_URI += "file://0001-sd-bus-Don-t-automatically-add-ObjectManager.patch"
-RRECOMMENDS_${PN} += "obmc-targets"
FILES_${PN} += "${systemd_unitdir}/network/default.network"
do_install_append() {
diff --git a/meta-phosphor/recipes-phosphor/ipmi/phosphor-ipmi-host_git.bb b/meta-phosphor/recipes-phosphor/ipmi/phosphor-ipmi-host_git.bb
index e41da0be3..6bd95e86f 100644
--- a/meta-phosphor/recipes-phosphor/ipmi/phosphor-ipmi-host_git.bb
+++ b/meta-phosphor/recipes-phosphor/ipmi/phosphor-ipmi-host_git.bb
@@ -23,7 +23,7 @@ def ipmi_whitelists(d):
DEPENDS += "autoconf-archive-native"
DEPENDS += "nlohmann-json"
-DEPENDS += "obmc-targets"
+DEPENDS += "phosphor-state-manager"
DEPENDS += "${@ipmi_whitelists(d)}"
DEPENDS += "phosphor-dbus-interfaces"
DEPENDS += "phosphor-logging"
diff --git a/meta-phosphor/recipes-phosphor/state/files/obmc/phosphor-reboot-host/reboot.conf b/meta-phosphor/recipes-phosphor/state/files/obmc/phosphor-reboot-host/reboot.conf
deleted file mode 100644
index 2e3ca1a5b..000000000
--- a/meta-phosphor/recipes-phosphor/state/files/obmc/phosphor-reboot-host/reboot.conf
+++ /dev/null
@@ -1 +0,0 @@
-REBOOT_DELAY=5
diff --git a/meta-phosphor/recipes-phosphor/state/files/phosphor-discover-system-state@.service b/meta-phosphor/recipes-phosphor/state/files/phosphor-discover-system-state@.service
deleted file mode 100644
index 4a5e6a7e5..000000000
--- a/meta-phosphor/recipes-phosphor/state/files/phosphor-discover-system-state@.service
+++ /dev/null
@@ -1,19 +0,0 @@
-[Unit]
-Description=Reboot If Enabled
-Wants=mapper-wait@-xyz-openbmc_project-control-host0-power_restore_policy.service
-After=mapper-wait@-xyz-openbmc_project-control-host0-power_restore_policy.service
-Wants=mapper-wait@-xyz-openbmc_project-state-host%i.service
-After=mapper-wait@-xyz-openbmc_project-state-host%i.service
-Wants=mapper-wait@-xyz-openbmc_project-state-chassis%i.service
-After=mapper-wait@-xyz-openbmc_project-state-chassis%i.service
-After=op-reset-chassis-on@%i.service
-ConditionPathExists=!/run/openbmc/chassis@%i-on
-
-[Service]
-Restart=no
-Type=oneshot
-ExecStart=/usr/bin/env phosphor-discover-system-state --host %i
-SyslogIdentifier=phosphor-discover-system-state
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta-phosphor/recipes-phosphor/state/files/phosphor-reboot-host@.service b/meta-phosphor/recipes-phosphor/state/files/phosphor-reboot-host@.service
deleted file mode 100644
index 27479f2de..000000000
--- a/meta-phosphor/recipes-phosphor/state/files/phosphor-reboot-host@.service
+++ /dev/null
@@ -1,18 +0,0 @@
-[Unit]
-Description=Reboot host%i
-Wants=obmc-host-stop@%i.target
-After=obmc-host-stop@%i.target
-
-[Service]
-#ExecStart={base_bindir}/systemctl start obmc-host-start@%i.target
-# This service is starting another target that conflicts with the
-# target this service is running in. OpenBMC needs a refactor of
-# how it does its host reset path. Until then, this short term
-# solution does the job.
-# Since this is a part of the reboot target, call the startmin
-# target which does the minimum required to start the host.
-ExecStart=/bin/sh -c "sleep ${{REBOOT_DELAY}} && systemctl start obmc-host-startmin@%i.target"
-EnvironmentFile={envfiledir}/obmc/phosphor-reboot-host/reboot.conf
-
-[Install]
-WantedBy=obmc-host-reboot@%i.target
diff --git a/meta-phosphor/recipes-phosphor/state/files/phosphor-reset-host-check@.service b/meta-phosphor/recipes-phosphor/state/files/phosphor-reset-host-check@.service
deleted file mode 100644
index 075ac500b..000000000
--- a/meta-phosphor/recipes-phosphor/state/files/phosphor-reset-host-check@.service
+++ /dev/null
@@ -1,19 +0,0 @@
-[Unit]
-Description=Check Host%i status on BMC reset
-Wants=phosphor-ipmi-host.service
-After=phosphor-ipmi-host.service
-Wants=obmc-host-reset-running@%i.target
-Before=obmc-host-reset-running@%i.target
-Wants=op-reset-chassis-on@%i.service
-After=op-reset-chassis-on@%i.service
-Conflicts=obmc-host-stop@%i.target
-ConditionPathExists=/run/openbmc/chassis@%i-on
-
-[Service]
-RemainAfterExit=yes
-Type=oneshot
-ExecStart=/usr/bin/env phosphor-host-check
-SyslogIdentifier=phosphor-host-check
-
-[Install]
-WantedBy=obmc-host-reset@%i.target
diff --git a/meta-phosphor/recipes-phosphor/state/files/phosphor-reset-host-reboot-attempts@.service b/meta-phosphor/recipes-phosphor/state/files/phosphor-reset-host-reboot-attempts@.service
deleted file mode 100644
index 35de4304b..000000000
--- a/meta-phosphor/recipes-phosphor/state/files/phosphor-reset-host-reboot-attempts@.service
+++ /dev/null
@@ -1,13 +0,0 @@
-[Unit]
-Description=Reset host reboot counter
-Wants=mapper-wait@-xyz-openbmc_project-state-host%i.service
-After=mapper-wait@-xyz-openbmc_project-state-host%i.service
-ConditionPathExists=!/run/openbmc/host@%i-on
-
-[Service]
-Restart=no
-Type=oneshot
-ExecStart=/bin/sh -c "busctl set-property `mapper get-service /xyz/openbmc_project/state/host%i` /xyz/openbmc_project/state/host%i xyz.openbmc_project.Control.Boot.RebootAttempts AttemptsLeft u 3"
-
-[Install]
-WantedBy=obmc-host-start@%i.target
diff --git a/meta-phosphor/recipes-phosphor/state/files/phosphor-reset-host-running@.service b/meta-phosphor/recipes-phosphor/state/files/phosphor-reset-host-running@.service
deleted file mode 100644
index a49bbdd16..000000000
--- a/meta-phosphor/recipes-phosphor/state/files/phosphor-reset-host-running@.service
+++ /dev/null
@@ -1,13 +0,0 @@
-[Unit]
-Description=Start host%i running after BMC reset
-After=obmc-host-reset-running@%i.target
-Requires=obmc-host-reset-running@%i.target
-ConditionPathExists=/run/openbmc/host@%i-on
-
-[Service]
-RemainAfterExit=no
-ExecStart=/bin/systemctl start obmc-host-start@%i.target
-
-
-[Install]
-WantedBy=obmc-host-reset@%i.target
diff --git a/meta-phosphor/recipes-phosphor/state/files/phosphor-reset-sensor-states@.service b/meta-phosphor/recipes-phosphor/state/files/phosphor-reset-sensor-states@.service
deleted file mode 100644
index 689372f4a..000000000
--- a/meta-phosphor/recipes-phosphor/state/files/phosphor-reset-sensor-states@.service
+++ /dev/null
@@ -1,15 +0,0 @@
-[Unit]
-Description=Reset host sensors
-After=phosphor-reset-host-check@%i.service
-Wants=mapper-wait@-xyz-openbmc_project-state-host%i.service
-After=mapper-wait@-xyz-openbmc_project-state-host%i.service
-ConditionPathExists=!/run/openbmc/host@%i-on
-
-[Service]
-Restart=no
-Type=oneshot
-ExecStart=/bin/sh -c "busctl set-property `mapper get-service /xyz/openbmc_project/state/host0` /xyz/openbmc_project/state/host0 xyz.openbmc_project.State.Boot.Progress BootProgress s xyz.openbmc_project.State.Boot.Progress.ProgressStages.Unspecified"
-ExecStart=/bin/sh -c "busctl set-property `mapper get-service /xyz/openbmc_project/state/host0` /xyz/openbmc_project/state/host0 xyz.openbmc_project.State.OperatingSystem.Status OperatingSystemState s xyz.openbmc_project.State.OperatingSystem.Status.OSStatus.Inactive"
-
-[Install]
-WantedBy=obmc-host-reset@%i.target
diff --git a/meta-phosphor/recipes-phosphor/state/files/xyz.openbmc_project.State.BMC.service b/meta-phosphor/recipes-phosphor/state/files/xyz.openbmc_project.State.BMC.service
deleted file mode 100644
index de1da5add..000000000
--- a/meta-phosphor/recipes-phosphor/state/files/xyz.openbmc_project.State.BMC.service
+++ /dev/null
@@ -1,16 +0,0 @@
-[Unit]
-Description=Phosphor BMC State Manager
-Before=mapper-wait@-xyz-openbmc_project-state-bmc.service
-Wants=obmc-mapper.target
-After=obmc-mapper.target
-
-
-[Service]
-ExecStart=/usr/bin/env phosphor-bmc-state-manager
-SyslogIdentifier=phosphor-bmc-state-manager
-Restart=always
-Type=dbus
-BusName={BUSNAME}
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta-phosphor/recipes-phosphor/state/files/xyz.openbmc_project.State.Chassis.service b/meta-phosphor/recipes-phosphor/state/files/xyz.openbmc_project.State.Chassis.service
deleted file mode 100644
index 1cab07fcf..000000000
--- a/meta-phosphor/recipes-phosphor/state/files/xyz.openbmc_project.State.Chassis.service
+++ /dev/null
@@ -1,16 +0,0 @@
-[Unit]
-Description=Phosphor Chassis State Manager
-Before=mapper-wait@-xyz-openbmc_project-state-chassis.service
-Wants=obmc-mapper.target
-After=obmc-mapper.target
-After=org.openbmc.control.Power@0.service
-
-[Service]
-ExecStart=/usr/bin/env phosphor-chassis-state-manager
-SyslogIdentifier=phosphor-chassis-state-manager
-Restart=always
-Type=dbus
-BusName={BUSNAME}
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta-phosphor/recipes-phosphor/state/files/xyz.openbmc_project.State.Host.service b/meta-phosphor/recipes-phosphor/state/files/xyz.openbmc_project.State.Host.service
deleted file mode 100644
index 780f26071..000000000
--- a/meta-phosphor/recipes-phosphor/state/files/xyz.openbmc_project.State.Host.service
+++ /dev/null
@@ -1,18 +0,0 @@
-[Unit]
-Description=Phosphor Host State Manager
-Wants=mapper-wait@-xyz-openbmc_project-control-host0-auto_reboot.service
-After=mapper-wait@-xyz-openbmc_project-control-host0-auto_reboot.service
-Before=mapper-wait@-xyz-openbmc_project-state-host.service
-After=phosphor-reset-host-running@0.service
-Wants=obmc-mapper.target
-After=obmc-mapper.target
-
-[Service]
-ExecStart=/usr/bin/env phosphor-host-state-manager
-SyslogIdentifier=phosphor-host-state-manager
-Restart=always
-Type=dbus
-BusName={BUSNAME}
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta-phosphor/recipes-phosphor/state/phosphor-state-manager_git.bb b/meta-phosphor/recipes-phosphor/state/phosphor-state-manager_git.bb
index 674add7b1..caa0352a6 100644
--- a/meta-phosphor/recipes-phosphor/state/phosphor-state-manager_git.bb
+++ b/meta-phosphor/recipes-phosphor/state/phosphor-state-manager_git.bb
@@ -16,6 +16,7 @@ STATE_MGR_PACKAGES = " \
${PN}-host-check \
${PN}-reset-sensor-states \
${PN}-systemd-target-monitor \
+ ${PN}-obmc-targets \
"
PACKAGE_BEFORE_PN += "${STATE_MGR_PACKAGES}"
ALLOW_EMPTY_${PN} = "1"
@@ -35,6 +36,9 @@ SYSTEMD_PACKAGES = "${PN}-discover \
# recommended to deal properly with these reset scenarios.
RRECOMMENDS_${PN}-host = "${PN}-host-check ${PN}-reset-sensor-states"
+# The obmc-targets are the base targets required to boot a computer system
+RRECOMMENDS_${PN}-host += "${PN}-obmc-targets"
+
inherit meson pkgconfig
inherit obmc-phosphor-dbus-service
@@ -49,7 +53,6 @@ DEPENDS += "cli11"
FILES_${PN}-host = "${bindir}/phosphor-host-state-manager"
DBUS_SERVICE_${PN}-host += "xyz.openbmc_project.State.Host.service"
DBUS_SERVICE_${PN}-host += "phosphor-reboot-host@.service"
-SYSTEMD_ENVIRONMENT_FILE_${PN}-host += "obmc/phosphor-reboot-host/reboot.conf"
SYSTEMD_SERVICE_${PN}-host += "phosphor-reset-host-reboot-attempts@.service"
FILES_${PN}-chassis = "${bindir}/phosphor-chassis-state-manager"
@@ -140,7 +143,89 @@ HOST_RST_RBT_ATTEMPTS_SVC_INST = "phosphor-reset-host-reboot-attempts@{0}.servic
HOST_RST_RBT_ATTEMPTS_SVC_FMT = "../${HOST_RST_RBT_ATTEMPTS_SVC}:${HOST_START_TGTFMT}.requires/${HOST_RST_RBT_ATTEMPTS_SVC_INST}"
SYSTEMD_LINK_${PN}-host += "${@compose_list_zip(d, 'HOST_RST_RBT_ATTEMPTS_SVC_FMT', 'OBMC_HOST_INSTANCES', 'OBMC_HOST_INSTANCES')}"
+
+# Chassis power synchronization targets
+# - start-pre: Services to run before we start power on process
+# - start: Services to run to do the chassis power on
+# - on: Services to run once power is on
+# - stop-pre,stop,off: Same as above but applied to powering off
+# - reset-on: Services to check if chassis power is on after bmc reset
+CHASSIS_SYNCH_TARGETS = "start-pre start on stop-pre stop off reset-on"
+
+# Chassis action power targets
+# - on: Services to run to power on the chassis
+# - off: Services to run to power off the chassis
+# - powered-off: Services to run once chassis power is off
+# - reset: Services to check chassis power state and update chassis "on" target
+# - hard-off: Services to force an immediate power off of the chassis
+CHASSIS_ACTION_TARGETS = "poweron poweroff powered-off powerreset hard-poweroff"
+
+# Track all host synchronization point targets
+# - start-pre: Services to run before we start host boot
+# - starting: Services to run to do the host boot
+# - started: Services to run once the host is booted
+# - stop-pre,stopping,stopped: Same as above but applied to shutting down the host
+# - reset-running: Services to check if host is running after bmc reset
+HOST_SYNCH_TARGETS = "start-pre starting started stop-pre stopping stopped reset-running"
+
+# Track all host action targets
+# - start: Will run startmin target, this target used for any additional
+# services that user needs for an initial power on of host.
+# For example, resetting the host reboot count could be put in
+# this target so on any fresh power on, this count is reset.
+# - startmin: Minimum services required to start the host. This target will
+# be called by reboot and start target.
+# - stop: Services to run to shutdown the host
+# - quiesce: Target to enter on host boot failure
+# - shutdown: Tell host to shutdown, then stop system
+# - reset: Services to check if host is running and update host "start" target
+# - crash: Target to run when host crashes. it is very much similar to
+# quiesce target but the only delta is that this target contains
+# multiple services and one of them is the quiesce target.
+# - timeout: Target to run when host watchdog times out
+# - reboot: Reboot the host
+HOST_ACTION_TARGETS = "start startmin stop quiesce reset shutdown crash timeout reboot"
+
+CHASSIS_SYNCH_FMT = "obmc-power-{0}@.target"
+CHASSIS_ACTION_FMT = "obmc-chassis-{0}@.target"
+HOST_SYNCH_FMT = "obmc-host-{0}@.target"
+HOST_ACTION_FMT = "obmc-host-{0}@.target"
+
+CHASSIS_LINK_SYNCH_FMT = "${CHASSIS_SYNCH_FMT}:obmc-power-{0}@{1}.target"
+CHASSIS_LINK_ACTION_FMT = "${CHASSIS_ACTION_FMT}:obmc-chassis-{0}@{1}.target"
+HOST_LINK_SYNCH_FMT = "${HOST_SYNCH_FMT}:obmc-host-{0}@{1}.target"
+HOST_LINK_ACTION_FMT = "${HOST_ACTION_FMT}:obmc-host-{0}@{1}.target"
+FAN_LINK_FMT = "obmc-fan-control-ready@.target:obmc-fan-control-ready@{0}.target"
+
+# Targets to be executed on checkstop and watchdog timeout
+HOST_ERROR_TARGETS = "crash timeout"
+
+QUIESCE_TMPL = "obmc-host-quiesce@.target"
+CRASH_TIMEOUT_TGTFMT = "obmc-host-{0}@{1}.target"
+QUIESCE_INSTFMT = "obmc-host-quiesce@{1}.target"
+QUIESCE_FMT = "../${QUIESCE_TMPL}:${CRASH_TIMEOUT_TGTFMT}.wants/${QUIESCE_INSTFMT}"
+
+SYSTEMD_SERVICE_${PN}-obmc-targets += " \
+ obmc-mapper.target \
+ obmc-fans-ready.target \
+ obmc-fan-control.target \
+ obmc-fan-control-ready@.target \
+ obmc-fan-watchdog-takeover.target \
+ "
+
+SYSTEMD_SERVICE_${PN}-obmc-targets += "${@compose_list(d, 'CHASSIS_SYNCH_FMT', 'CHASSIS_SYNCH_TARGETS')}"
+SYSTEMD_SERVICE_${PN}-obmc-targets += "${@compose_list(d, 'CHASSIS_ACTION_FMT', 'CHASSIS_ACTION_TARGETS')}"
+SYSTEMD_SERVICE_${PN}-obmc-targets += "${@compose_list(d, 'HOST_SYNCH_FMT', 'HOST_SYNCH_TARGETS')}"
+SYSTEMD_SERVICE_${PN}-obmc-targets += "${@compose_list(d, 'HOST_ACTION_FMT', 'HOST_ACTION_TARGETS')}"
+
+SYSTEMD_LINK_${PN}-obmc-targets += "${@compose_list(d, 'CHASSIS_LINK_SYNCH_FMT', 'CHASSIS_SYNCH_TARGETS', 'OBMC_CHASSIS_INSTANCES')}"
+SYSTEMD_LINK_${PN}-obmc-targets += "${@compose_list(d, 'CHASSIS_LINK_ACTION_FMT', 'CHASSIS_ACTION_TARGETS', 'OBMC_CHASSIS_INSTANCES')}"
+SYSTEMD_LINK_${PN}-obmc-targets += "${@compose_list(d, 'HOST_LINK_SYNCH_FMT', 'HOST_SYNCH_TARGETS', 'OBMC_HOST_INSTANCES')}"
+SYSTEMD_LINK_${PN}-obmc-targets += "${@compose_list(d, 'HOST_LINK_ACTION_FMT', 'HOST_ACTION_TARGETS', 'OBMC_HOST_INSTANCES')}"
+SYSTEMD_LINK_${PN}-obmc-targets += "${@compose_list(d, 'FAN_LINK_FMT', 'OBMC_CHASSIS_INSTANCES')}"
+SYSTEMD_LINK_${PN}-obmc-targets += "${@compose_list(d, 'QUIESCE_FMT', 'HOST_ERROR_TARGETS', 'OBMC_HOST_INSTANCES')}"
+
SRC_URI += "git://github.com/openbmc/phosphor-state-manager"
-SRCREV = "4640d48e998709f1b64b97347db0f1b355b7f423"
+SRCREV = "c101157e5b138f36044a2a3aaf15ad8ac16501fc"
S = "${WORKDIR}/git"