summaryrefslogtreecommitdiff
path: root/meta-openbmc-mods/meta-common/recipes-phosphor/ipmi/phosphor-ipmi-host/0053-Fix-keep-looping-issue-when-entering-OS.patch
diff options
context:
space:
mode:
authorJason M. Bills <jason.m.bills@linux.intel.com>2020-12-08 00:45:20 +0300
committerJason M. Bills <jason.m.bills@linux.intel.com>2020-12-10 01:15:05 +0300
commit82dbc15a05125a812c140a3c8cff81c366482229 (patch)
tree9c8f1ad262a2e281f20340cf8646aca6f8596044 /meta-openbmc-mods/meta-common/recipes-phosphor/ipmi/phosphor-ipmi-host/0053-Fix-keep-looping-issue-when-entering-OS.patch
parent8d6ae7f2a817751fad151168fa10ce28ee0869d8 (diff)
downloadopenbmc-82dbc15a05125a812c140a3c8cff81c366482229.tar.xz
Update to internal 0.26
Signed-off-by: Jason M. Bills <jason.m.bills@linux.intel.com>
Diffstat (limited to 'meta-openbmc-mods/meta-common/recipes-phosphor/ipmi/phosphor-ipmi-host/0053-Fix-keep-looping-issue-when-entering-OS.patch')
-rw-r--r--meta-openbmc-mods/meta-common/recipes-phosphor/ipmi/phosphor-ipmi-host/0053-Fix-keep-looping-issue-when-entering-OS.patch29
1 files changed, 19 insertions, 10 deletions
diff --git a/meta-openbmc-mods/meta-common/recipes-phosphor/ipmi/phosphor-ipmi-host/0053-Fix-keep-looping-issue-when-entering-OS.patch b/meta-openbmc-mods/meta-common/recipes-phosphor/ipmi/phosphor-ipmi-host/0053-Fix-keep-looping-issue-when-entering-OS.patch
index 903ae96a7..7a7fd0859 100644
--- a/meta-openbmc-mods/meta-common/recipes-phosphor/ipmi/phosphor-ipmi-host/0053-Fix-keep-looping-issue-when-entering-OS.patch
+++ b/meta-openbmc-mods/meta-common/recipes-phosphor/ipmi/phosphor-ipmi-host/0053-Fix-keep-looping-issue-when-entering-OS.patch
@@ -23,7 +23,7 @@ diff --git a/host-cmd-manager.cpp b/host-cmd-manager.cpp
index f3aba7f..465eb81 100644
--- a/host-cmd-manager.cpp
+++ b/host-cmd-manager.cpp
-@@ -26,6 +26,8 @@ constexpr auto MAPPER_INTERFACE = "xyz.openbmc_project.ObjectMapper";
+@@ -23,6 +23,8 @@ namespace command
constexpr auto HOST_STATE_PATH = "/xyz/openbmc_project/state/host0";
constexpr auto HOST_STATE_INTERFACE = "xyz.openbmc_project.State.Host";
constexpr auto HOST_TRANS_PROP = "RequestedHostTransition";
@@ -32,7 +32,7 @@ index f3aba7f..465eb81 100644
// For throwing exceptions
using namespace phosphor::logging;
-@@ -106,6 +108,20 @@ void Manager::clearQueue()
+@@ -103,6 +105,20 @@ void Manager::clearQueue()
// `false` indicating Failure
std::get<CallBack>(command)(ipmiCmdData, false);
}
@@ -53,28 +53,37 @@ index f3aba7f..465eb81 100644
}
// Called for alerting the host
-@@ -115,9 +131,6 @@ void Manager::checkQueueAndAlertHost()
+@@ -112,9 +128,7 @@ void Manager::checkQueueAndAlertHost()
{
log<level::DEBUG>("Asserting SMS Attention");
+- std::string HOST_IPMI_SVC("org.openbmc.HostIpmi");
- std::string IPMI_PATH("/org/openbmc/HostIpmi/1");
- std::string IPMI_INTERFACE("org.openbmc.HostIpmi");
--
- auto host = ::ipmi::getService(this->bus, IPMI_INTERFACE, IPMI_PATH);
++ auto host = ::ipmi::getService(this->bus, IPMI_INTERFACE, IPMI_PATH);
// Start the timer for this transaction
-@@ -131,9 +144,8 @@ void Manager::checkQueueAndAlertHost()
+ auto time = std::chrono::duration_cast<std::chrono::microseconds>(
+@@ -127,12 +141,13 @@ void Manager::checkQueueAndAlertHost()
return;
}
- auto method =
-- this->bus.new_method_call(host.c_str(), IPMI_PATH.c_str(),
+- this->bus.new_method_call(HOST_IPMI_SVC.c_str(), IPMI_PATH.c_str(),
- IPMI_INTERFACE.c_str(), "setAttention");
+- auto reply = this->bus.call(method);
+-
+- if (reply.is_method_error())
+ auto method = this->bus.new_method_call(host.c_str(), IPMI_PATH,
+ IPMI_INTERFACE, "setAttention");
- auto reply = this->bus.call(method);
-
- if (reply.is_method_error())
++ try
++ {
++ auto reply = this->bus.call(method);
++ }
++ catch (const std::exception&)
+ {
+ log<level::ERR>("Error in setting SMS attention");
+ elog<InternalFailure>();
--
2.7.4