diff options
author | James Feist <james.feist@linux.intel.com> | 2018-10-12 14:57:06 -0700 |
---|---|---|
committer | James Feist <james.feist@linux.intel.com> | 2018-10-18 00:54:34 +0000 |
commit | 3754442944d08235dc519c371d2222b53bca3fe3 (patch) | |
tree | e9a6d870dd53bc19c3320d6881e3c19fbcbf2c83 /sensorhandler.cpp | |
parent | 2e63352fe8893a65e45690402d8681644b572e12 (diff) | |
download | phosphor-host-ipmid-3754442944d08235dc519c371d2222b53bca3fe3.tar.gz phosphor-host-ipmid-3754442944d08235dc519c371d2222b53bca3fe3.zip |
Remove direct uses of mapbox
sdbusplus is moving to std::variant, remove direct
uses of mapbox to limit breakage.
Tested-by: It built
Change-Id: I3fe0ba0d96b6aad302927363b9596cc1bcce2393
Signed-off-by: James Feist <james.feist@linux.intel.com>
Diffstat (limited to 'sensorhandler.cpp')
-rw-r--r-- | sensorhandler.cpp | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/sensorhandler.cpp b/sensorhandler.cpp index 770f6dc..08a6325 100644 --- a/sensorhandler.cpp +++ b/sensorhandler.cpp @@ -31,6 +31,8 @@ using namespace phosphor::logging; using InternalFailure = sdbusplus::xyz::openbmc_project::Common::Error::InternalFailure; +namespace variant_ns = sdbusplus::message::variant_ns; + void register_netfn_sen_functions() __attribute__((constructor)); struct sensorTypemap_t @@ -451,10 +453,10 @@ void getSensorThresholds(uint8_t sensorNum, auto warnThresholds = ipmi::getAllDbusProperties( bus, service, info.sensorPath, warningThreshIntf); - double warnLow = mapbox::util::apply_visitor(ipmi::VariantToDoubleVisitor(), - warnThresholds["WarningLow"]); - double warnHigh = mapbox::util::apply_visitor( - ipmi::VariantToDoubleVisitor(), warnThresholds["WarningHigh"]); + double warnLow = variant_ns::apply_visitor(ipmi::VariantToDoubleVisitor(), + warnThresholds["WarningLow"]); + double warnHigh = variant_ns::apply_visitor(ipmi::VariantToDoubleVisitor(), + warnThresholds["WarningHigh"]); if (warnLow != 0) { @@ -476,10 +478,10 @@ void getSensorThresholds(uint8_t sensorNum, auto critThresholds = ipmi::getAllDbusProperties( bus, service, info.sensorPath, criticalThreshIntf); - double critLow = mapbox::util::apply_visitor(ipmi::VariantToDoubleVisitor(), - critThresholds["CriticalLow"]); - double critHigh = mapbox::util::apply_visitor( - ipmi::VariantToDoubleVisitor(), critThresholds["CriticalHigh"]); + double critLow = variant_ns::apply_visitor(ipmi::VariantToDoubleVisitor(), + critThresholds["CriticalLow"]); + double critHigh = variant_ns::apply_visitor(ipmi::VariantToDoubleVisitor(), + critThresholds["CriticalHigh"]); if (critLow != 0) { |