summaryrefslogtreecommitdiffstats
path: root/settings.cpp
diff options
context:
space:
mode:
authorPatrick Venture <venture@google.com>2018-08-31 11:55:55 -0700
committerPatrick Venture <venture@google.com>2018-09-07 23:45:41 +0000
commit0b02be925a29357f69abbc9e9a58e7c5aaed2eab (patch)
treec1b39f817d98ffda7b987f9e3f864f576e3bf9ea /settings.cpp
parent26f80ab2cc41deadc913190d906f71266c4ed224 (diff)
downloadphosphor-host-ipmid-0b02be925a29357f69abbc9e9a58e7c5aaed2eab.tar.gz
phosphor-host-ipmid-0b02be925a29357f69abbc9e9a58e7c5aaed2eab.zip
add .clang-format
Change-Id: I7c2a527b4751a560703a61fcbe9638b150546af5 Signed-off-by: Patrick Venture <venture@google.com>
Diffstat (limited to 'settings.cpp')
-rw-r--r--settings.cpp29
1 files changed, 12 insertions, 17 deletions
diff --git a/settings.cpp b/settings.cpp
index a1ca62c..770bde0 100644
--- a/settings.cpp
+++ b/settings.cpp
@@ -1,9 +1,11 @@
-#include <phosphor-logging/elog-errors.hpp>
-#include <phosphor-logging/log.hpp>
-#include "xyz/openbmc_project/Common/error.hpp"
#include "settings.hpp"
+
#include "utils.hpp"
+#include <phosphor-logging/elog-errors.hpp>
+#include <phosphor-logging/log.hpp>
+#include <xyz/openbmc_project/Common/error.hpp>
+
namespace settings
{
@@ -15,14 +17,12 @@ constexpr auto mapperPath = "/xyz/openbmc_project/object_mapper";
constexpr auto mapperIntf = "xyz.openbmc_project.ObjectMapper";
Objects::Objects(sdbusplus::bus::bus& bus,
- const std::vector<Interface>& filter):
+ const std::vector<Interface>& filter) :
bus(bus)
{
auto depth = 0;
- auto mapperCall = bus.new_method_call(mapperService,
- mapperPath,
- mapperIntf,
+ auto mapperCall = bus.new_method_call(mapperService, mapperPath, mapperIntf,
"GetSubTree");
mapperCall.append(root);
mapperCall.append(depth);
@@ -66,10 +66,8 @@ Objects::Objects(sdbusplus::bus::bus& bus,
Service Objects::service(const Path& path, const Interface& interface) const
{
using Interfaces = std::vector<Interface>;
- auto mapperCall = bus.new_method_call(mapperService,
- mapperPath,
- mapperIntf,
- "GetObject");
+ auto mapperCall =
+ bus.new_method_call(mapperService, mapperPath, mapperIntf, "GetObject");
mapperCall.append(path);
mapperCall.append(Interfaces({interface}));
@@ -118,12 +116,9 @@ std::tuple<Path, OneTimeEnabled> setting(const Objects& objects,
const Path& oneTimeSetting = paths[index];
const Path& regularSetting = paths[!index];
- auto method =
- objects.bus.new_method_call(
- objects.service(oneTimeSetting, iface).c_str(),
- oneTimeSetting.c_str(),
- ipmi::PROP_INTF,
- "Get");
+ auto method = objects.bus.new_method_call(
+ objects.service(oneTimeSetting, iface).c_str(), oneTimeSetting.c_str(),
+ ipmi::PROP_INTF, "Get");
method.append(enabledIntf, "Enabled");
auto reply = objects.bus.call(method);
if (reply.is_method_error())
OpenPOWER on IntegriCloud