summaryrefslogtreecommitdiff
path: root/meta-phosphor/common/recipes-phosphor/leds
diff options
context:
space:
mode:
authorVishwanatha Subbanna <vishwa@linux.vnet.ibm.com>2017-07-19 10:25:13 +0300
committerPatrick Williams <patrick@stwcx.xyz>2017-08-01 16:16:20 +0300
commite922ca60d7497a59c3700c89e1ca33d4664c0d15 (patch)
tree5ed79b76fcec371d7eabeeee7aff4fedf0c877d1 /meta-phosphor/common/recipes-phosphor/leds
parentba986b88d087366c6925b4f5b32bf2adc847e5c0 (diff)
downloadopenbmc-e922ca60d7497a59c3700c89e1ca33d4664c0d15.tar.xz
Fix a bug driving a LED during BMC boot
It is a requirement that Firmware notifies users about it's READY state and the mechanism was to assert 'bmc_booted` group which would result in user defined behavior on corresponding physical LED. Blinking a particular physical LED is one of the most common ways to let users know. The code was asserting the 'bmc_booted' group soon after the LED daemon was alive and this was incorrect since LED daemon would start early in the boot and not after reaching READY state. This patch waits until reaching READY before asserting the needed LED group. If applied, this commit will resolve openbmc/openbmc#1919 only for systems that are not based on MRW. For fixing this issue on Witherspoon machine, a change needs to be made in openbmc/phosphor-mrw-tools to make sure latest XML is chosen during build. Currently, its pointing to an old XML. Change-Id: Idc711942140295f2cf5d7b691eb9371f4da671d5 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
Diffstat (limited to 'meta-phosphor/common/recipes-phosphor/leds')
-rw-r--r--meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager.bb2
-rw-r--r--meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager/bmc_booted.conf3
2 files changed, 5 insertions, 0 deletions
diff --git a/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager.bb b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager.bb
index 5f1f36d2a6..22c98bcfe2 100644
--- a/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager.bb
+++ b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager.bb
@@ -53,5 +53,7 @@ INSTFMT = "obmc-led-group-{0}@power_on.service"
FMT = "../${TMPLFMT}:${TGTFMT}.wants/${INSTFMT}"
SYSTEMD_LINK_${PN}-ledmanager += "${@compose_list(d, 'FMT', 'STATES')}"
+# Install the override to set up a Conflicts relation
+SYSTEMD_OVERRIDE_${PN}-ledmanager += "bmc_booted.conf:obmc-led-group-start@bmc_booted.service.d/bmc_booted.conf"
EXTRA_OECONF = "YAML_PATH=${STAGING_DATADIR_NATIVE}/${PN}"
diff --git a/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager/bmc_booted.conf b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager/bmc_booted.conf
new file mode 100644
index 0000000000..a300f6ace3
--- /dev/null
+++ b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager/bmc_booted.conf
@@ -0,0 +1,3 @@
+[Unit]
+Wants={SYSTEMD_DEFAULT_TARGET}
+After={SYSTEMD_DEFAULT_TARGET}