diff options
author | Raptor Engineering Development Team <support@raptorengineering.com> | 2018-01-21 06:41:07 -0600 |
---|---|---|
committer | Raptor Engineering Development Team <support@raptorengineering.com> | 2018-04-12 21:09:45 -0500 |
commit | 2357a8aa30aa5a07cf0cc46d3a3a951cdf02a502 (patch) | |
tree | 8ffaebe9b315ef4dbc68912f6e4b59d3cd74033b | |
parent | 040ef72021d31eca0b5cf1303ca1b9ca13474b73 (diff) | |
download | talos-openbmc-2357a8aa30aa5a07cf0cc46d3a3a951cdf02a502.tar.gz talos-openbmc-2357a8aa30aa5a07cf0cc46d3a3a951cdf02a502.zip |
Enable OCC service after IPL completion
4 files changed, 16 insertions, 6 deletions
diff --git a/meta-openbmc-machines/meta-openpower/common/recipes-phosphor/occ/openpower-occ-control/occ-active.sh b/meta-openbmc-machines/meta-openpower/common/recipes-phosphor/occ/openpower-occ-control/occ-active.sh index a6097e527..c005c7dd8 100755 --- a/meta-openbmc-machines/meta-openpower/common/recipes-phosphor/occ/openpower-occ-control/occ-active.sh +++ b/meta-openbmc-machines/meta-openpower/common/recipes-phosphor/occ/openpower-occ-control/occ-active.sh @@ -14,6 +14,9 @@ fi OCC_CONTROL_SERVICE="org.open_power.OCC.Control" +# Rescan bus to find OCCs +openpower-proc-control scanFSI + busctl tree $OCC_CONTROL_SERVICE --list | grep occ | xargs -r -n1 -I{} \ busctl set-property $OCC_CONTROL_SERVICE {} org.open_power.OCC.Status \ OccActive b $value diff --git a/meta-openbmc-machines/meta-openpower/common/recipes-phosphor/occ/openpower-occ-control/op-occ-enable@.service b/meta-openbmc-machines/meta-openpower/common/recipes-phosphor/occ/openpower-occ-control/op-occ-enable@.service index b97253cf0..2e969b8e8 100644 --- a/meta-openbmc-machines/meta-openpower/common/recipes-phosphor/occ/openpower-occ-control/op-occ-enable@.service +++ b/meta-openbmc-machines/meta-openpower/common/recipes-phosphor/occ/openpower-occ-control/op-occ-enable@.service @@ -4,14 +4,12 @@ Conflicts=obmc-host-stop@%i.target Conflicts=op-occ-disable@%i.service Wants=org.open_power.OCC.Control.service After=org.open_power.OCC.Control.service -Wants=fsi-scan@%i.service -After=fsi-scan@%i.service -ConditionPathExists=/run/openbmc/host@%i-on +Wants=obmc-host-ipl-complete@%i.target +After=obmc-host-ipl-complete@%i.target +ConditionPathExists=/run/openbmc/host@0-ipl-complete [Service] ExecStart=/usr/bin/env occ-active.sh enable SyslogIdentifier=occ-active.sh Type=oneshot -[Install] -WantedBy=obmc-host-start@%i.target diff --git a/meta-phosphor/common/recipes-core/systemd/obmc-targets.bb b/meta-phosphor/common/recipes-core/systemd/obmc-targets.bb index ac7835e6b..3e9541669 100644 --- a/meta-phosphor/common/recipes-core/systemd/obmc-targets.bb +++ b/meta-phosphor/common/recipes-core/systemd/obmc-targets.bb @@ -47,7 +47,8 @@ HOST_SYNCH_TARGETS = "start-pre starting started stop-pre stopping stopped reset # 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" +# - ipl-complete: IPL has finished, OK to start OCC monitors +HOST_ACTION_TARGETS = "start startmin stop quiesce reset shutdown crash timeout reboot ipl-complete" CHASSIS_SYNCH_FMT = "obmc-power-{0}@.target" CHASSIS_ACTION_FMT = "obmc-chassis-{0}@.target" diff --git a/meta-phosphor/common/recipes-core/systemd/obmc-targets/obmc-host-ipl-complete@.target b/meta-phosphor/common/recipes-core/systemd/obmc-targets/obmc-host-ipl-complete@.target new file mode 100644 index 000000000..2c8614595 --- /dev/null +++ b/meta-phosphor/common/recipes-core/systemd/obmc-targets/obmc-host-ipl-complete@.target @@ -0,0 +1,8 @@ +[Unit] +Description=Host%i IPL Complete +Wants={SYSTEMD_DEFAULT_TARGET} +After={SYSTEMD_DEFAULT_TARGET} +Conflicts=obmc-host-stop@%i.target +RefuseManualStop=yes +ConditionPathExists=/run/openbmc/host@0-ipl-complete +Wants=op-occ-enable@%i.service |