diff options
author | Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com> | 2017-02-11 19:40:23 +0300 |
---|---|---|
committer | Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com> | 2017-03-03 14:09:00 +0300 |
commit | 7f07e7d28463403b5d26cd403d87f0292b0b2cf2 (patch) | |
tree | c7221ce85449f526095157618b7e795070386466 /meta-phosphor/common/recipes-phosphor/leds | |
parent | db86d27a593f932cd2d4d77307801b3a8e00874f (diff) | |
download | openbmc-7f07e7d28463403b5d26cd403d87f0292b0b2cf2.tar.xz |
Update LED Manager recipe to support Palmetto machine
This has the changes that enables LED group manager on Palmetto
Change-Id: Iaf4d4cc4c798c70e557009e9928225facb1d7d86
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
Diffstat (limited to 'meta-phosphor/common/recipes-phosphor/leds')
6 files changed, 25 insertions, 20 deletions
diff --git a/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager-config-example-native.bb b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager-config-example-native.bb index 8b3703d98f..139b775e71 100644 --- a/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager-config-example-native.bb +++ b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager-config-example-native.bb @@ -5,6 +5,8 @@ inherit native inherit obmc-phosphor-utils require phosphor-led-manager.inc +PROVIDES += "virtual/phosphor-led-manager-config-native" + S = "${WORKDIR}/git" # Copies example led layout yaml file diff --git a/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager-config-mrw-native.bb b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager-config-mrw-native.bb index b88dedcd98..fb3259b4a8 100644 --- a/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager-config-mrw-native.bb +++ b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager-config-mrw-native.bb @@ -5,6 +5,7 @@ inherit native inherit obmc-phosphor-utils inherit obmc-phosphor-license +PROVIDES += "virtual/phosphor-led-manager-config-native" DEPENDS += "mrw-native mrw-perl-tools-native" # Generate a YAML files based on MRW input diff --git a/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager-config-native.bb b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager-config-native.bb deleted file mode 100644 index 73812eab51..0000000000 --- a/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager-config-native.bb +++ /dev/null @@ -1,19 +0,0 @@ -SUMMARY = "Phosphor LED Group Management meta data" -PR = "r1" - -inherit obmc-phosphor-utils -inherit obmc-phosphor-license -inherit native - -# Default is the example set of data. -PHOSPHOR_LED_MANAGER_CONFIG ??= "${BPN}-example-native" - -# Choose appropriate yaml file -def get_depends(d): - if d.getVar('USE_MRW', 'yes'): - return "${BPN}-mrw-native" - else: - return "${PHOSPHOR_LED_MANAGER_CONFIG}" - -USE_MRW = "${@cf_enabled(d, 'obmc-mrw', 'yes')}" -DEPENDS += "${@get_depends(d)}" 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 54996f9994..17871895b3 100644 --- a/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager.bb +++ b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager.bb @@ -9,11 +9,12 @@ require ${PN}.inc DEPENDS += "python-pyyaml-native" DEPENDS += "autoconf-archive-native" DEPENDS += "sdbusplus sdbusplus-native" -DEPENDS += "${PN}-config-native" +DEPENDS += "virtual/${PN}-config-native" RDEPENDS_${PN} += "libsystemd" S = "${WORKDIR}/git" DBUS_SERVICE_${PN} += "xyz.openbmc_project.LED.GroupManager.service" +SYSTEMD_SERVICE_${PN} += "obmc-led-group-start@.service obmc-led-group-stop@.service" EXTRA_OECONF = "YAML_PATH=${STAGING_DATADIR_NATIVE}/${PN}" diff --git a/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager/obmc-led-group-start@.service b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager/obmc-led-group-start@.service new file mode 100644 index 0000000000..7c0207c0d4 --- /dev/null +++ b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager/obmc-led-group-start@.service @@ -0,0 +1,10 @@ +[Unit] +Description=Assert %i LED +Wants=mapper-wait@-xyz-openbmc_project-led-groups-%i.service +After=mapper-wait@-xyz-openbmc_project-led-groups-%i.service + +[Service] +Type=oneshot +RemainAfterExit=yes +Restart=no +ExecStart={sbindir}/mapper call /xyz/openbmc_project/led/groups/%i org.freedesktop.DBus.Properties Set ssv xyz.openbmc_project.Led.Group Asserted b true diff --git a/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager/obmc-led-group-stop@.service b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager/obmc-led-group-stop@.service new file mode 100644 index 0000000000..4ddf0f8e2c --- /dev/null +++ b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager/obmc-led-group-stop@.service @@ -0,0 +1,10 @@ +[Unit] +Description=Assert %i LED +Wants=mapper-wait@-xyz-openbmc_project-led-groups-%i.service +After=mapper-wait@-xyz-openbmc_project-led-groups-%i.service + +[Service] +Type=oneshot +RemainAfterExit=yes +Restart=no +ExecStart={sbindir}/mapper call /xyz/openbmc_project/led/groups/%i org.freedesktop.DBus.Properties Set ssv xyz.openbmc_project.Led.Group Asserted b false |