diff options
author | Brad Bishop <bradleyb@fuzziesquirrel.com> | 2017-08-01 21:33:30 -0400 |
---|---|---|
committer | Patrick Williams <patrick@stwcx.xyz> | 2017-08-24 11:31:18 +0000 |
commit | 4ce57190dabd779b0d6dbb07f855d41dd83505a0 (patch) | |
tree | 31cc30ff7398ff24af2ff58bb22730a6a84ddd3a /meta-phosphor/common/recipes-phosphor/sensors | |
parent | 4653c60ca19976be5f4d8719811b2409033b124f (diff) | |
download | talos-openbmc-4ce57190dabd779b0d6dbb07f855d41dd83505a0.tar.gz talos-openbmc-4ce57190dabd779b0d6dbb07f855d41dd83505a0.zip |
sensors: Add max31785 MSL checking package
The phosphor-hwmon project recently added a script for setting the MSL
(Minimum Ship Level) on an inventory item given specific MAX31785
firmware revision criteria. Add a package for this script.
The package is not installed by default - machine implementations
must pick it up themselves and configure when it runs and the script
parameters (inventory items, i2c address, revision...) accordingly.
Change-Id: I71aa589ad86b913d5a0637955817046b9d8de15f
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
Diffstat (limited to 'meta-phosphor/common/recipes-phosphor/sensors')
-rw-r--r-- | meta-phosphor/common/recipes-phosphor/sensors/phosphor-hwmon.bb | 7 | ||||
-rw-r--r-- | meta-phosphor/common/recipes-phosphor/sensors/phosphor-hwmon/phosphor-max31785-msl@.service | 10 |
2 files changed, 17 insertions, 0 deletions
diff --git a/meta-phosphor/common/recipes-phosphor/sensors/phosphor-hwmon.bb b/meta-phosphor/common/recipes-phosphor/sensors/phosphor-hwmon.bb index 5acfe9670..4af758122 100644 --- a/meta-phosphor/common/recipes-phosphor/sensors/phosphor-hwmon.bb +++ b/meta-phosphor/common/recipes-phosphor/sensors/phosphor-hwmon.bb @@ -7,7 +7,11 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=fa818a259cbed7ce8bc2a22d35a464fc" inherit autotools pkgconfig obmc-phosphor-systemd +PACKAGE_BEFORE_PN = "max31785-msl" +SYSTEMD_PACKAGES = "${PN} max31785-msl" + SYSTEMD_SERVICE_${PN} = "xyz.openbmc_project.Hwmon@.service" +SYSTEMD_SERVICE_max31785-msl = "phosphor-max31785-msl@.service" DEPENDS += "autoconf-archive-native" DEPENDS += " \ @@ -25,6 +29,9 @@ RDEPENDS_${PN} += "\ RRECOMMENDS_${PN} += "${VIRTUAL-RUNTIME_phosphor-hwmon-config}" +FILES_max31785-msl = "${bindir}/max31785-msl" +RDEPENDS_max31785-msl = "${VIRTUAL-RUNTIME_base-utils} i2c-tools" + SRC_URI += "git://github.com/openbmc/phosphor-hwmon" SRC_URI += "file://70-hwmon.rules" SRC_URI += "file://70-iio.rules" diff --git a/meta-phosphor/common/recipes-phosphor/sensors/phosphor-hwmon/phosphor-max31785-msl@.service b/meta-phosphor/common/recipes-phosphor/sensors/phosphor-hwmon/phosphor-max31785-msl@.service new file mode 100644 index 000000000..1bfda8312 --- /dev/null +++ b/meta-phosphor/common/recipes-phosphor/sensors/phosphor-hwmon/phosphor-max31785-msl@.service @@ -0,0 +1,10 @@ +[Unit] +Description=Phosphor MAX31785 MSL +ConditionFileNotEmpty={envfiledir}/obmc/hwmon-max31785/%I.conf +Wants=mapper-wait@-xyz-openbmc_project-inventory.service +After=mapper-wait@-xyz-openbmc_project-inventory.service + +[Service] +Type=oneshot +ExecStart={bindir}/max31785-msl -p "${{PATHS}}" -b ${{BUS}} -r ${{REVISION}} +EnvironmentFile={envfiledir}/obmc/hwmon-max31785/%I.conf |