summaryrefslogtreecommitdiffstats
path: root/systemintfcmds.cpp
diff options
context:
space:
mode:
authorVishwanatha Subbanna <vishwa@linux.vnet.ibm.com>2017-03-31 11:34:48 +0530
committerPatrick Williams <patrick@stwcx.xyz>2017-04-04 03:26:28 +0000
commitb891a576f6e23f4a2ebda105236767a503185685 (patch)
tree1fe7badd6ce49af56196749ed224d93b5a016ec8 /systemintfcmds.cpp
parent504ebc2a21d50616f57ca2f2ae4959a99fb064c9 (diff)
downloadphosphor-host-ipmid-b891a576f6e23f4a2ebda105236767a503185685.tar.gz
phosphor-host-ipmid-b891a576f6e23f4a2ebda105236767a503185685.zip
IPMI: Update the dbus object for soft power off with underscores
Fixes openbmc/phosphor-host-ipmid#102 Change-Id: I3e7456401b7265a51578f9aa08bef2ae3f326849 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
Diffstat (limited to 'systemintfcmds.cpp')
-rw-r--r--systemintfcmds.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/systemintfcmds.cpp b/systemintfcmds.cpp
index 07ecec8..62d9524 100644
--- a/systemintfcmds.cpp
+++ b/systemintfcmds.cpp
@@ -1,5 +1,6 @@
#include "systemintfcmds.h"
#include "host-ipmid/ipmid-api.h"
+#include "config.h"
#include <stdio.h>
#include <mapper.h>
@@ -21,8 +22,6 @@ ipmi_ret_t ipmi_app_read_event(ipmi_netfn_t netfn, ipmi_cmd_t cmd,
// mechanism. If we need to make this generically used for some
// other conditions, then we can take advantage of context pointer.
- constexpr auto objname = "/xyz/openbmc_project/ipmi/internal/"
- "softpoweroff";
constexpr auto iface = "org.freedesktop.DBus.Properties";
constexpr auto soft_off_iface = "xyz.openbmc_project.Ipmi.Internal."
"SoftPowerOff";
@@ -41,11 +40,11 @@ ipmi_ret_t ipmi_app_read_event(ipmi_netfn_t netfn, ipmi_cmd_t cmd,
// Nudge the SoftPowerOff application that it needs to stop the
// initial watchdog timer. If we have some errors talking to Soft Off
// object, get going and do our regular job
- mapper_get_service(bus, objname, &busname);
+ mapper_get_service(bus, SOFTOFF_OBJPATH, &busname);
if (busname)
{
// No error object or reply expected.
- auto r = sd_bus_call_method(bus, busname, objname, iface,
+ auto r = sd_bus_call_method(bus, busname, SOFTOFF_OBJPATH, iface,
"Set", nullptr, nullptr, "ssv",
soft_off_iface, property, "s", value);
if (r < 0)
OpenPOWER on IntegriCloud