summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorJames Feist <james.feist@linux.intel.com>2019-03-25 15:29:35 -0700
committerEd Tanous <ed.tanous@intel.com>2019-05-23 21:17:57 +0000
commit73df0db0daca78a62ef262ec3f933c887e7ceaa1 (patch)
tree3d80c40adf18e5a6093dec49405655c4f68e4e18 /include
parent4f9a213046d031b50d162f2ffb41464ab432b144 (diff)
downloadbmcweb-73df0db0daca78a62ef262ec3f933c887e7ceaa1.tar.gz
bmcweb-73df0db0daca78a62ef262ec3f933c887e7ceaa1.zip
PID: Add fan profile support
This adds fan profiles to redfish. This uses the Thermal Mode interface to allow switching between different fan profiles. Only the selected fan profile will be seen. When adding a new controller, they will also be added to the configuration item for that profile. Patching of the profile to switch between supported profiles is also supported. Tested: Could change profiles in redfish. Python test script: def testProfile(): a = { "Oem": { "OpenBmc": { "Fan": { "Profile" : "Acoustic" } } } } return a def dopatch(): resp = requests.patch(address, json=testProfile(), verify=False, auth=("root", "0penBmc")) resp.raise_for_status() Change-Id: Ie2d8582616ed5bde58e3328b21ba8c59437e88ce Signed-off-by: James Feist <james.feist@linux.intel.com>
Diffstat (limited to 'include')
-rw-r--r--include/dbus_utility.hpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/dbus_utility.hpp b/include/dbus_utility.hpp
index e45bb9a..bb2bd65 100644
--- a/include/dbus_utility.hpp
+++ b/include/dbus_utility.hpp
@@ -36,6 +36,11 @@ using ManagedObjectType = std::vector<
std::string,
boost::container::flat_map<std::string, DbusVariantType>>>>;
+using ManagedItem = std::pair<
+ sdbusplus::message::object_path,
+ boost::container::flat_map<
+ std::string, boost::container::flat_map<std::string, DbusVariantType>>>;
+
inline void escapePathForDbus(std::string& path)
{
const std::regex reg("[^A-Za-z0-9_/]");
OpenPOWER on IntegriCloud