Vernon Mauery | 9e801a2 | 2018-10-12 13:20:49 -0700 | [diff] [blame] | 1 | #include "sol_manager.hpp" |
| 2 | |
| 3 | #include "main.hpp" |
| 4 | #include "sol_context.hpp" |
| 5 | |
Tom Joseph | 22c5ad3 | 2017-03-14 18:04:22 +0530 | [diff] [blame] | 6 | #include <sys/socket.h> |
| 7 | #include <sys/un.h> |
Vernon Mauery | 9e801a2 | 2018-10-12 13:20:49 -0700 | [diff] [blame] | 8 | |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 9 | #include <boost/asio/basic_stream_socket.hpp> |
| 10 | #include <boost/asio/io_context.hpp> |
| 11 | #include <boost/asio/local/stream_protocol.hpp> |
| 12 | #include <boost/asio/write.hpp> |
srikanta mondal | f6e7230 | 2020-06-08 12:46:28 +0000 | [diff] [blame] | 13 | #include <ipmid/utils.hpp> |
George Liu | 7b7f25f | 2022-07-04 17:07:32 +0800 | [diff] [blame] | 14 | #include <phosphor-logging/lg2.hpp> |
Cheng C Yang | 2908695 | 2020-03-09 15:29:18 +0800 | [diff] [blame] | 15 | #include <sdbusplus/message/types.hpp> |
| 16 | |
George Liu | bc8958f | 2022-07-04 09:29:49 +0800 | [diff] [blame] | 17 | #include <chrono> |
| 18 | #include <cmath> |
| 19 | |
Cheng C Yang | 2908695 | 2020-03-09 15:29:18 +0800 | [diff] [blame] | 20 | constexpr const char* solInterface = "xyz.openbmc_project.Ipmi.SOL"; |
| 21 | constexpr const char* solPath = "/xyz/openbmc_project/ipmi/sol/"; |
| 22 | constexpr const char* PROP_INTF = "org.freedesktop.DBus.Properties"; |
Tom Joseph | 22c5ad3 | 2017-03-14 18:04:22 +0530 | [diff] [blame] | 23 | |
| 24 | namespace sol |
| 25 | { |
| 26 | |
srikanta mondal | f6e7230 | 2020-06-08 12:46:28 +0000 | [diff] [blame] | 27 | std::unique_ptr<sdbusplus::bus::match_t> matchPtrSOL(nullptr); |
Jian Zhang | c936eca | 2022-03-22 11:25:29 +0800 | [diff] [blame] | 28 | std::unique_ptr<sdbusplus::bus::match_t> solConfPropertiesSignal(nullptr); |
srikanta mondal | f6e7230 | 2020-06-08 12:46:28 +0000 | [diff] [blame] | 29 | |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 30 | void Manager::initConsoleSocket() |
Tom Joseph | b81f761 | 2017-04-25 17:59:02 +0530 | [diff] [blame] | 31 | { |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 32 | // explicit length constructor for NUL-prefixed abstract path |
| 33 | std::string path(CONSOLE_SOCKET_PATH, CONSOLE_SOCKET_PATH_LEN); |
| 34 | boost::asio::local::stream_protocol::endpoint ep(path); |
| 35 | consoleSocket = |
| 36 | std::make_unique<boost::asio::local::stream_protocol::socket>(*io); |
| 37 | consoleSocket->connect(ep); |
Tom Joseph | b81f761 | 2017-04-25 17:59:02 +0530 | [diff] [blame] | 38 | } |
| 39 | |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 40 | void Manager::consoleInputHandler() |
Tom Joseph | 22c5ad3 | 2017-03-14 18:04:22 +0530 | [diff] [blame] | 41 | { |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 42 | boost::system::error_code ec; |
| 43 | boost::asio::socket_base::bytes_readable cmd(true); |
| 44 | consoleSocket->io_control(cmd, ec); |
| 45 | size_t readSize; |
| 46 | if (!ec) |
Tom Joseph | 22c5ad3 | 2017-03-14 18:04:22 +0530 | [diff] [blame] | 47 | { |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 48 | readSize = cmd.get(); |
| 49 | } |
| 50 | else |
| 51 | { |
George Liu | 7b7f25f | 2022-07-04 17:07:32 +0800 | [diff] [blame] | 52 | lg2::error( |
| 53 | "Reading ready count from host console socket failed: {ERROR}", |
| 54 | "ERROR", ec.value()); |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 55 | return; |
| 56 | } |
| 57 | std::vector<uint8_t> buffer(readSize); |
| 58 | ec.clear(); |
Patrick Williams | 099fb09 | 2023-05-10 07:50:31 -0500 | [diff] [blame] | 59 | size_t readDataLen = consoleSocket->read_some(boost::asio::buffer(buffer), |
| 60 | ec); |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 61 | if (ec) |
| 62 | { |
George Liu | 7b7f25f | 2022-07-04 17:07:32 +0800 | [diff] [blame] | 63 | lg2::error("Reading from host console socket failed: {ERROR}", "ERROR", |
| 64 | ec.value()); |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 65 | return; |
Tom Joseph | 22c5ad3 | 2017-03-14 18:04:22 +0530 | [diff] [blame] | 66 | } |
| 67 | |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 68 | // Update the Console buffer with data read from the socket |
| 69 | buffer.resize(readDataLen); |
| 70 | dataBuffer.write(buffer); |
Tom Joseph | 22c5ad3 | 2017-03-14 18:04:22 +0530 | [diff] [blame] | 71 | } |
| 72 | |
Tingting Chen | ec43741 | 2022-09-27 18:35:22 +0800 | [diff] [blame] | 73 | int Manager::writeConsoleSocket(const std::vector<uint8_t>& input, |
| 74 | bool breakFlag) const |
Tom Joseph | b51f641 | 2017-03-14 18:08:14 +0530 | [diff] [blame] | 75 | { |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 76 | boost::system::error_code ec; |
Tingting Chen | ec43741 | 2022-09-27 18:35:22 +0800 | [diff] [blame] | 77 | if (breakFlag) |
| 78 | { |
| 79 | consoleSocket->send(boost::asio::buffer(input), MSG_OOB, ec); |
| 80 | } |
| 81 | else |
| 82 | { |
| 83 | consoleSocket->send(boost::asio::buffer(input), 0, ec); |
| 84 | } |
| 85 | |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 86 | return ec.value(); |
| 87 | } |
Tom Joseph | b51f641 | 2017-03-14 18:08:14 +0530 | [diff] [blame] | 88 | |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 89 | void Manager::startHostConsole() |
| 90 | { |
| 91 | if (!consoleSocket) |
Tom Joseph | b51f641 | 2017-03-14 18:08:14 +0530 | [diff] [blame] | 92 | { |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 93 | initConsoleSocket(); |
Tom Joseph | b51f641 | 2017-03-14 18:08:14 +0530 | [diff] [blame] | 94 | } |
srikanta mondal | f6e7230 | 2020-06-08 12:46:28 +0000 | [diff] [blame] | 95 | |
| 96 | // Register callback to close SOL session for disable SSH SOL |
| 97 | if (matchPtrSOL == nullptr) |
| 98 | { |
| 99 | registerSOLServiceChangeCallback(); |
| 100 | } |
| 101 | |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 102 | consoleSocket->async_wait(boost::asio::socket_base::wait_read, |
| 103 | [this](const boost::system::error_code& ec) { |
Patrick Williams | 099fb09 | 2023-05-10 07:50:31 -0500 | [diff] [blame] | 104 | if (!ec) |
| 105 | { |
| 106 | consoleInputHandler(); |
| 107 | startHostConsole(); |
| 108 | } |
| 109 | }); |
Rashmi RV | 0f63e01 | 2019-11-21 15:38:50 +0530 | [diff] [blame] | 110 | } // namespace sol |
Tom Joseph | b51f641 | 2017-03-14 18:08:14 +0530 | [diff] [blame] | 111 | |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 112 | void Manager::stopHostConsole() |
| 113 | { |
| 114 | if (consoleSocket) |
| 115 | { |
| 116 | consoleSocket->cancel(); |
| 117 | consoleSocket.reset(); |
| 118 | } |
Tom Joseph | b51f641 | 2017-03-14 18:08:14 +0530 | [diff] [blame] | 119 | } |
| 120 | |
Cheng C Yang | 2908695 | 2020-03-09 15:29:18 +0800 | [diff] [blame] | 121 | void Manager::updateSOLParameter(uint8_t channelNum) |
| 122 | { |
| 123 | std::variant<uint8_t, bool> value; |
Patrick Williams | 0a59062 | 2022-07-22 19:26:53 -0500 | [diff] [blame] | 124 | sdbusplus::bus_t dbus(ipmid_get_sd_bus_connection()); |
Cheng C Yang | 2908695 | 2020-03-09 15:29:18 +0800 | [diff] [blame] | 125 | static std::string solService{}; |
| 126 | ipmi::PropertyMap properties; |
| 127 | std::string ethdevice = ipmi::getChannelName(channelNum); |
| 128 | std::string solPathWitheEthName = solPath + ethdevice; |
| 129 | if (solService.empty()) |
| 130 | { |
| 131 | try |
| 132 | { |
Patrick Williams | 099fb09 | 2023-05-10 07:50:31 -0500 | [diff] [blame] | 133 | solService = ipmi::getService(dbus, solInterface, |
| 134 | solPathWitheEthName); |
Cheng C Yang | 2908695 | 2020-03-09 15:29:18 +0800 | [diff] [blame] | 135 | } |
| 136 | catch (const std::runtime_error& e) |
| 137 | { |
| 138 | solService.clear(); |
George Liu | 7b7f25f | 2022-07-04 17:07:32 +0800 | [diff] [blame] | 139 | lg2::error("Get SOL service failed: {ERROR}", "ERROR", e); |
Cheng C Yang | 2908695 | 2020-03-09 15:29:18 +0800 | [diff] [blame] | 140 | return; |
| 141 | } |
| 142 | } |
| 143 | try |
| 144 | { |
| 145 | properties = ipmi::getAllDbusProperties( |
| 146 | dbus, solService, solPathWitheEthName, solInterface); |
| 147 | } |
George Liu | 7b7f25f | 2022-07-04 17:07:32 +0800 | [diff] [blame] | 148 | catch (const std::runtime_error& e) |
Cheng C Yang | 2908695 | 2020-03-09 15:29:18 +0800 | [diff] [blame] | 149 | { |
George Liu | 7b7f25f | 2022-07-04 17:07:32 +0800 | [diff] [blame] | 150 | lg2::error("Setting sol parameter: {ERROR}", "ERROR", e); |
Cheng C Yang | 2908695 | 2020-03-09 15:29:18 +0800 | [diff] [blame] | 151 | return; |
| 152 | } |
| 153 | |
| 154 | progress = std::get<uint8_t>(properties["Progress"]); |
| 155 | |
| 156 | enable = std::get<bool>(properties["Enable"]); |
| 157 | |
| 158 | forceEncrypt = std::get<bool>(properties["ForceEncryption"]); |
| 159 | |
| 160 | forceAuth = std::get<bool>(properties["ForceAuthentication"]); |
| 161 | |
| 162 | solMinPrivilege = static_cast<session::Privilege>( |
| 163 | std::get<uint8_t>(properties["Privilege"])); |
| 164 | |
| 165 | accumulateInterval = |
| 166 | std::get<uint8_t>((properties["AccumulateIntervalMS"])) * |
| 167 | sol::accIntervalFactor * 1ms; |
| 168 | |
| 169 | sendThreshold = std::get<uint8_t>(properties["Threshold"]); |
| 170 | |
| 171 | retryCount = std::get<uint8_t>(properties["RetryCount"]); |
| 172 | |
| 173 | retryInterval = std::get<uint8_t>(properties["RetryIntervalMS"]) * |
| 174 | sol::retryIntervalFactor * 1ms; |
| 175 | |
| 176 | return; |
| 177 | } |
| 178 | |
Tom Joseph | 2e44e0e | 2017-03-14 18:09:11 +0530 | [diff] [blame] | 179 | void Manager::startPayloadInstance(uint8_t payloadInstance, |
| 180 | session::SessionID sessionID) |
| 181 | { |
| 182 | if (payloadMap.empty()) |
| 183 | { |
Rashmi RV | 0f63e01 | 2019-11-21 15:38:50 +0530 | [diff] [blame] | 184 | try |
| 185 | { |
| 186 | startHostConsole(); |
| 187 | } |
| 188 | catch (const std::exception& e) |
| 189 | { |
George Liu | 7b7f25f | 2022-07-04 17:07:32 +0800 | [diff] [blame] | 190 | lg2::error( |
| 191 | "Encountered exception when starting host console. Hence stopping host console: {ERROR}", |
| 192 | "ERROR", e); |
Rashmi RV | 0f63e01 | 2019-11-21 15:38:50 +0530 | [diff] [blame] | 193 | stopHostConsole(); |
| 194 | throw; |
| 195 | } |
Tom Joseph | 2e44e0e | 2017-03-14 18:09:11 +0530 | [diff] [blame] | 196 | } |
| 197 | |
| 198 | // Create the SOL Context data for payload instance |
Vernon Mauery | a6ad5e1 | 2020-02-21 14:54:24 -0800 | [diff] [blame] | 199 | std::shared_ptr<Context> context = Context::makeContext( |
| 200 | io, retryCount, sendThreshold, payloadInstance, sessionID); |
Tom Joseph | 2e44e0e | 2017-03-14 18:09:11 +0530 | [diff] [blame] | 201 | |
Tom Joseph | 2e44e0e | 2017-03-14 18:09:11 +0530 | [diff] [blame] | 202 | payloadMap.emplace(payloadInstance, std::move(context)); |
| 203 | } |
| 204 | |
Tom Joseph | 4ff14b5 | 2017-03-14 18:10:52 +0530 | [diff] [blame] | 205 | void Manager::stopPayloadInstance(uint8_t payloadInstance) |
| 206 | { |
| 207 | auto iter = payloadMap.find(payloadInstance); |
| 208 | if (iter == payloadMap.end()) |
| 209 | { |
| 210 | throw std::runtime_error("SOL Payload instance not found "); |
| 211 | } |
| 212 | |
| 213 | payloadMap.erase(iter); |
| 214 | |
Tom Joseph | 4ff14b5 | 2017-03-14 18:10:52 +0530 | [diff] [blame] | 215 | if (payloadMap.empty()) |
| 216 | { |
Vernon Mauery | 7e4a651 | 2018-11-09 08:43:36 -0800 | [diff] [blame] | 217 | stopHostConsole(); |
Tom Joseph | de203ce | 2017-08-01 16:48:06 +0530 | [diff] [blame] | 218 | |
| 219 | dataBuffer.erase(dataBuffer.size()); |
Tom Joseph | 4ff14b5 | 2017-03-14 18:10:52 +0530 | [diff] [blame] | 220 | } |
| 221 | } |
| 222 | |
srikanta mondal | f6e7230 | 2020-06-08 12:46:28 +0000 | [diff] [blame] | 223 | void Manager::stopAllPayloadInstance() |
| 224 | { |
| 225 | // Erase all payload instance |
| 226 | payloadMap.erase(payloadMap.begin(), payloadMap.end()); |
| 227 | |
| 228 | stopHostConsole(); |
| 229 | |
| 230 | dataBuffer.erase(dataBuffer.size()); |
| 231 | } |
| 232 | |
| 233 | void registerSOLServiceChangeCallback() |
| 234 | { |
| 235 | using namespace sdbusplus::bus::match::rules; |
Patrick Williams | 0a59062 | 2022-07-22 19:26:53 -0500 | [diff] [blame] | 236 | sdbusplus::bus_t bus{ipmid_get_sd_bus_connection()}; |
srikanta mondal | f6e7230 | 2020-06-08 12:46:28 +0000 | [diff] [blame] | 237 | try |
| 238 | { |
| 239 | auto servicePath = ipmi::getDbusObject( |
| 240 | bus, "xyz.openbmc_project.Control.Service.Attributes", |
Konstantin Aladyshev | cc540bf | 2023-03-28 17:27:13 +0300 | [diff] [blame] | 241 | "/xyz/openbmc_project/control/service", "_6fbmc_2dconsole"); |
srikanta mondal | f6e7230 | 2020-06-08 12:46:28 +0000 | [diff] [blame] | 242 | |
| 243 | if (!std::empty(servicePath.first)) |
| 244 | { |
| 245 | matchPtrSOL = std::make_unique<sdbusplus::bus::match_t>( |
| 246 | bus, |
| 247 | path_namespace(servicePath.first) + |
| 248 | "arg0namespace='xyz.openbmc_project.Control.Service." |
| 249 | "Attributes'" |
| 250 | ", " + |
| 251 | type::signal() + member("PropertiesChanged") + |
| 252 | interface("org.freedesktop.DBus.Properties"), |
Patrick Williams | 0a59062 | 2022-07-22 19:26:53 -0500 | [diff] [blame] | 253 | [](sdbusplus::message_t& msg) { |
Patrick Williams | 099fb09 | 2023-05-10 07:50:31 -0500 | [diff] [blame] | 254 | std::string intfName; |
| 255 | std::map<std::string, std::variant<bool>> properties; |
| 256 | msg.read(intfName, properties); |
srikanta mondal | f6e7230 | 2020-06-08 12:46:28 +0000 | [diff] [blame] | 257 | |
Patrick Williams | 099fb09 | 2023-05-10 07:50:31 -0500 | [diff] [blame] | 258 | const auto it = properties.find("Enabled"); |
| 259 | if (it != properties.end()) |
| 260 | { |
| 261 | const bool* state = std::get_if<bool>(&it->second); |
| 262 | |
| 263 | if (state != nullptr && *state == false) |
srikanta mondal | f6e7230 | 2020-06-08 12:46:28 +0000 | [diff] [blame] | 264 | { |
Patrick Williams | 099fb09 | 2023-05-10 07:50:31 -0500 | [diff] [blame] | 265 | // Stop all the payload session. |
| 266 | sol::Manager::get().stopAllPayloadInstance(); |
srikanta mondal | f6e7230 | 2020-06-08 12:46:28 +0000 | [diff] [blame] | 267 | } |
Patrick Williams | 099fb09 | 2023-05-10 07:50:31 -0500 | [diff] [blame] | 268 | } |
Patrick Williams | 7b53409 | 2023-10-20 11:18:45 -0500 | [diff] [blame] | 269 | }); |
srikanta mondal | f6e7230 | 2020-06-08 12:46:28 +0000 | [diff] [blame] | 270 | } |
| 271 | } |
Patrick Williams | 12d199b | 2021-10-06 12:36:48 -0500 | [diff] [blame] | 272 | catch (const sdbusplus::exception_t& e) |
srikanta mondal | f6e7230 | 2020-06-08 12:46:28 +0000 | [diff] [blame] | 273 | { |
George Liu | 7b7f25f | 2022-07-04 17:07:32 +0800 | [diff] [blame] | 274 | lg2::error( |
| 275 | "Failed to get service path in registerSOLServiceChangeCallback: {ERROR}", |
| 276 | "ERROR", e); |
srikanta mondal | f6e7230 | 2020-06-08 12:46:28 +0000 | [diff] [blame] | 277 | } |
| 278 | } |
| 279 | |
Patrick Williams | 0a59062 | 2022-07-22 19:26:53 -0500 | [diff] [blame] | 280 | void procSolConfChange(sdbusplus::message_t& msg) |
Jian Zhang | c936eca | 2022-03-22 11:25:29 +0800 | [diff] [blame] | 281 | { |
| 282 | using SolConfVariant = std::variant<bool, uint8_t>; |
| 283 | using SolConfProperties = |
| 284 | std::vector<std::pair<std::string, SolConfVariant>>; |
| 285 | |
| 286 | std::string iface; |
| 287 | SolConfProperties properties; |
| 288 | |
| 289 | try |
| 290 | { |
| 291 | msg.read(iface, properties); |
| 292 | } |
| 293 | catch (const std::exception& e) |
| 294 | { |
George Liu | 7b7f25f | 2022-07-04 17:07:32 +0800 | [diff] [blame] | 295 | lg2::error("procSolConfChange get properties FAIL: {ERROR}", "ERROR", |
| 296 | e); |
Jian Zhang | c936eca | 2022-03-22 11:25:29 +0800 | [diff] [blame] | 297 | return; |
| 298 | } |
| 299 | |
| 300 | for (const auto& prop : properties) |
| 301 | { |
| 302 | if (prop.first == "Progress") |
| 303 | { |
| 304 | sol::Manager::get().progress = std::get<uint8_t>(prop.second); |
| 305 | } |
| 306 | else if (prop.first == "Enable") |
| 307 | { |
| 308 | sol::Manager::get().enable = std::get<bool>(prop.second); |
| 309 | } |
| 310 | else if (prop.first == "ForceEncryption") |
| 311 | { |
| 312 | sol::Manager::get().forceEncrypt = std::get<bool>(prop.second); |
| 313 | } |
| 314 | else if (prop.first == "ForceAuthentication") |
| 315 | { |
| 316 | sol::Manager::get().forceAuth = std::get<bool>(prop.second); |
| 317 | } |
| 318 | else if (prop.first == "Privilege") |
| 319 | { |
| 320 | sol::Manager::get().solMinPrivilege = |
| 321 | static_cast<session::Privilege>(std::get<uint8_t>(prop.second)); |
| 322 | } |
| 323 | else if (prop.first == "AccumulateIntervalMS") |
| 324 | { |
| 325 | sol::Manager::get().accumulateInterval = |
| 326 | std::get<uint8_t>(prop.second) * sol::accIntervalFactor * 1ms; |
| 327 | } |
| 328 | else if (prop.first == "Threshold") |
| 329 | { |
| 330 | sol::Manager::get().sendThreshold = std::get<uint8_t>(prop.second); |
| 331 | } |
| 332 | else if (prop.first == "RetryCount") |
| 333 | { |
| 334 | sol::Manager::get().retryCount = std::get<uint8_t>(prop.second); |
| 335 | } |
| 336 | else if (prop.first == "RetryIntervalMS") |
| 337 | { |
Patrick Williams | 099fb09 | 2023-05-10 07:50:31 -0500 | [diff] [blame] | 338 | sol::Manager::get().retryInterval = std::get<uint8_t>(prop.second) * |
| 339 | sol::retryIntervalFactor * 1ms; |
Jian Zhang | c936eca | 2022-03-22 11:25:29 +0800 | [diff] [blame] | 340 | } |
| 341 | } |
| 342 | } |
| 343 | |
| 344 | void registerSolConfChangeCallbackHandler(std::string channel) |
| 345 | { |
| 346 | if (solConfPropertiesSignal == nullptr) |
| 347 | { |
| 348 | using namespace sdbusplus::bus::match::rules; |
Patrick Williams | 0a59062 | 2022-07-22 19:26:53 -0500 | [diff] [blame] | 349 | sdbusplus::bus_t bus{ipmid_get_sd_bus_connection()}; |
Jian Zhang | c936eca | 2022-03-22 11:25:29 +0800 | [diff] [blame] | 350 | try |
| 351 | { |
| 352 | auto servicePath = solPath + channel; |
| 353 | |
| 354 | solConfPropertiesSignal = std::make_unique<sdbusplus::bus::match_t>( |
| 355 | bus, propertiesChangedNamespace(servicePath, solInterface), |
| 356 | procSolConfChange); |
| 357 | } |
| 358 | catch (const sdbusplus::exception_t& e) |
| 359 | { |
George Liu | 7b7f25f | 2022-07-04 17:07:32 +0800 | [diff] [blame] | 360 | lg2::error( |
| 361 | "Failed to get service path in registerSolConfChangeCallbackHandler, channel: {CHANNEL}, error: {ERROR}", |
| 362 | "CHANNEL", channel, "ERROR", e); |
Jian Zhang | c936eca | 2022-03-22 11:25:29 +0800 | [diff] [blame] | 363 | } |
| 364 | } |
| 365 | return; |
| 366 | } |
| 367 | |
Tom Joseph | 22c5ad3 | 2017-03-14 18:04:22 +0530 | [diff] [blame] | 368 | } // namespace sol |