style: function names should be lower camel
Fix function names to be lower camel.
Change-Id: I145e1f4c03d7740bc1525dcffbdce2f78fd61075
Signed-off-by: Patrick Venture <venture@google.com>
diff --git a/dbus/dbuspassive.cpp b/dbus/dbuspassive.cpp
index c350ea3..7e86790 100644
--- a/dbus/dbuspassive.cpp
+++ b/dbus/dbuspassive.cpp
@@ -32,7 +32,7 @@
{
return nullptr;
}
- if (!ValidType(type))
+ if (!validType(type))
{
return nullptr;
}
@@ -43,13 +43,13 @@
DbusPassive::DbusPassive(sdbusplus::bus::bus& bus, const std::string& type,
const std::string& id, DbusHelperInterface* helper) :
ReadInterface(),
- _bus(bus), _signal(bus, GetMatch(type, id).c_str(), DbusHandleSignal, this),
+ _bus(bus), _signal(bus, getMatch(type, id).c_str(), dbusHandleSignal, this),
_id(id), _helper(helper)
{
/* Need to get the scale and initial value */
auto tempBus = sdbusplus::bus::new_default();
/* service == busname */
- std::string path = GetSensorPath(type, id);
+ std::string path = getSensorPath(type, id);
/* getService can except, should this be in the factory? */
std::string service = _helper->getService(tempBus, sensorintf, path);
@@ -100,7 +100,7 @@
return _id;
}
-int HandleSensorValue(sdbusplus::message::message& msg, DbusPassive* owner)
+int handleSensorValue(sdbusplus::message::message& msg, DbusPassive* owner)
{
std::string msgSensor;
std::map<std::string, sdbusplus::message::variant<int64_t, double, bool>>
@@ -151,10 +151,10 @@
return 0;
}
-int DbusHandleSignal(sd_bus_message* msg, void* usrData, sd_bus_error* err)
+int dbusHandleSignal(sd_bus_message* msg, void* usrData, sd_bus_error* err)
{
auto sdbpMsg = sdbusplus::message::message(msg);
DbusPassive* obj = static_cast<DbusPassive*>(usrData);
- return HandleSensorValue(sdbpMsg, obj);
+ return handleSensorValue(sdbpMsg, obj);
}
diff --git a/dbus/dbuspassive.hpp b/dbus/dbuspassive.hpp
index 801722d..02e395c 100644
--- a/dbus/dbuspassive.hpp
+++ b/dbus/dbuspassive.hpp
@@ -17,7 +17,7 @@
#include <tuple>
#include <vector>
-int DbusHandleSignal(sd_bus_message* msg, void* data, sd_bus_error* err);
+int dbusHandleSignal(sd_bus_message* msg, void* data, sd_bus_error* err);
/*
* This ReadInterface will passively listen for Value updates from whomever
@@ -62,4 +62,4 @@
std::chrono::high_resolution_clock::time_point _updated;
};
-int HandleSensorValue(sdbusplus::message::message& msg, DbusPassive* owner);
+int handleSensorValue(sdbusplus::message::message& msg, DbusPassive* owner);
diff --git a/dbus/util.cpp b/dbus/util.cpp
index 080f39a..23f06fd 100644
--- a/dbus/util.cpp
+++ b/dbus/util.cpp
@@ -143,7 +143,7 @@
return asserted;
}
-std::string GetSensorPath(const std::string& type, const std::string& id)
+std::string getSensorPath(const std::string& type, const std::string& id)
{
std::string layer = type;
if (type == "fan")
@@ -162,16 +162,16 @@
return std::string("/xyz/openbmc_project/sensors/" + layer + "/" + id);
}
-std::string GetMatch(const std::string& type, const std::string& id)
+std::string getMatch(const std::string& type, const std::string& id)
{
return std::string("type='signal',"
"interface='org.freedesktop.DBus.Properties',"
"member='PropertiesChanged',"
"path='" +
- GetSensorPath(type, id) + "'");
+ getSensorPath(type, id) + "'");
}
-bool ValidType(const std::string& type)
+bool validType(const std::string& type)
{
static std::set<std::string> valid = {"fan", "temp"};
return (valid.find(type) != valid.end());
diff --git a/dbus/util.hpp b/dbus/util.hpp
index 41a0af1..67125b9 100644
--- a/dbus/util.hpp
+++ b/dbus/util.hpp
@@ -77,9 +77,9 @@
const std::string& path) override;
};
-std::string GetSensorPath(const std::string& type, const std::string& id);
-std::string GetMatch(const std::string& type, const std::string& id);
-bool ValidType(const std::string& type);
+std::string getSensorPath(const std::string& type, const std::string& id);
+std::string getMatch(const std::string& type, const std::string& id);
+bool validType(const std::string& type);
struct VariantToFloatVisitor
{