clang-format: re-format for clang-18

clang-format-18 isn't compatible with the clang-format-17 output, so we
need to reformat the code with the latest version.  The way clang-18
handles lambda formatting also changed, so we have made changes to the
organization default style format to better handle lambda formatting.

See I5e08687e696dd240402a2780158664b7113def0e for updated style.
See Iea0776aaa7edd483fa395e23de25ebf5a6288f71 for clang-18 enablement.

Change-Id: Ica590f8613f1fb89ab1ca676ac51c1cc7e38d67f
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
diff --git a/control/json/actions/action.hpp b/control/json/actions/action.hpp
index 0377a8a..93cd9e2 100644
--- a/control/json/actions/action.hpp
+++ b/control/json/actions/action.hpp
@@ -153,10 +153,11 @@
      */
     virtual void addZone(Zone& zone)
     {
-        auto itZone = std::find_if(_zones.begin(), _zones.end(),
-                                   [&zone](std::reference_wrapper<Zone>& z) {
-            return z.get().getName() == zone.getName();
-        });
+        auto itZone =
+            std::find_if(_zones.begin(), _zones.end(),
+                         [&zone](std::reference_wrapper<Zone>& z) {
+                             return z.get().getName() == zone.getName();
+                         });
         if (itZone == _zones.end())
         {
             _zones.emplace_back(std::reference_wrapper<Zone>(zone));
@@ -223,8 +224,8 @@
         json groups = json::array();
         std::for_each(_groups.begin(), _groups.end(),
                       [&groups](const auto& group) {
-            groups.push_back(group.getName());
-        });
+                          groups.push_back(group.getName());
+                      });
         json output;
         output["groups"] = groups;
         return output;
@@ -331,11 +332,11 @@
         else
         {
             // Construct list of available actions
-            auto acts = std::accumulate(std::next(actions.begin()),
-                                        actions.end(), actions.begin()->first,
-                                        [](auto list, auto act) {
-                return std::move(list) + ", " + act.first;
-            });
+            auto acts = std::accumulate(
+                std::next(actions.begin()), actions.end(),
+                actions.begin()->first, [](auto list, auto act) {
+                    return std::move(list) + ", " + act.first;
+                });
             log<level::ERR>(
                 std::format("Action '{}' is not registered", name).c_str(),
                 entry("AVAILABLE_ACTIONS=%s", acts.c_str()));
diff --git a/control/json/actions/count_state_floor.cpp b/control/json/actions/count_state_floor.cpp
index 25cb3e6..a285a90 100644
--- a/control/json/actions/count_state_floor.cpp
+++ b/control/json/actions/count_state_floor.cpp
@@ -71,10 +71,10 @@
 
     if (!_timer)
     {
-        _timer = std::make_unique<Timer>(util::SDEventPlus::getEvent(),
-                                         [&zone, this](Timer&) {
-            zone.setFloorHold(getUniqueName(), _floor, doCount());
-        });
+        _timer = std::make_unique<Timer>(
+            util::SDEventPlus::getEvent(), [&zone, this](Timer&) {
+                zone.setFloorHold(getUniqueName(), _floor, doCount());
+            });
     }
 
     if (!_timer->isEnabled())
diff --git a/control/json/actions/default_floor.cpp b/control/json/actions/default_floor.cpp
index 95a2219..5ca3c10 100644
--- a/control/json/actions/default_floor.cpp
+++ b/control/json/actions/default_floor.cpp
@@ -43,8 +43,8 @@
         auto isMissingOwner =
             std::any_of(members.begin(), members.end(),
                         [&intf = group.getInterface()](const auto& member) {
-            return !Manager::hasOwner(member, intf);
-        });
+                            return !Manager::hasOwner(member, intf);
+                        });
         if (isMissingOwner)
         {
             zone.setFloor(zone.getDefaultFloor());
diff --git a/control/json/actions/get_managed_objects.cpp b/control/json/actions/get_managed_objects.cpp
index 099a68b..eb5600e 100644
--- a/control/json/actions/get_managed_objects.cpp
+++ b/control/json/actions/get_managed_objects.cpp
@@ -60,11 +60,11 @@
                 }
 
                 // Look for the ObjectManager as an ancestor of the path.
-                auto hasObjMgr = std::any_of(objMgrPaths.begin(),
-                                             objMgrPaths.end(),
-                                             [member](const auto& path) {
-                    return member.find(path) != std::string::npos;
-                });
+                auto hasObjMgr = std::any_of(
+                    objMgrPaths.begin(), objMgrPaths.end(),
+                    [member](const auto& path) {
+                        return member.find(path) != std::string::npos;
+                    });
 
                 if (!hasObjMgr || services.find(service) == services.end())
                 {
@@ -99,8 +99,8 @@
         // Add zone to _actions
         std::for_each(_actions.begin(), _actions.end(),
                       [&zone](std::unique_ptr<ActionBase>& action) {
-            action->addZone(zone);
-        });
+                          action->addZone(zone);
+                      });
     }
 }
 
diff --git a/control/json/actions/mapped_floor.cpp b/control/json/actions/mapped_floor.cpp
index 3de2188..ab50075 100644
--- a/control/json/actions/mapped_floor.cpp
+++ b/control/json/actions/mapped_floor.cpp
@@ -232,12 +232,13 @@
 {
     std::visit(
         [&value](auto&& val) {
-        using V = std::decay_t<decltype(val)>;
-        if constexpr (std::is_same_v<int32_t, V> || std::is_same_v<int64_t, V>)
-        {
-            value = static_cast<double>(val);
-        }
-    },
+            using V = std::decay_t<decltype(val)>;
+            if constexpr (std::is_same_v<int32_t, V> ||
+                          std::is_same_v<int64_t, V>)
+            {
+                value = static_cast<double>(val);
+            }
+        },
         value);
 }
 
@@ -261,17 +262,17 @@
             {
                 std::visit(
                     [&group, this](auto&& val) {
-                    using V = std::decay_t<decltype(val)>;
-                    if constexpr (!std::is_same_v<double, V> &&
-                                  !std::is_same_v<int32_t, V> &&
-                                  !std::is_same_v<int64_t, V>)
-                    {
-                        throw std::runtime_error{std::format(
-                            "{}: Group {} has more than one member but "
-                            "isn't numeric",
-                            ActionBase::getName(), group.getName())};
-                    }
-                },
+                        using V = std::decay_t<decltype(val)>;
+                        if constexpr (!std::is_same_v<double, V> &&
+                                      !std::is_same_v<int32_t, V> &&
+                                      !std::is_same_v<int64_t, V>)
+                        {
+                            throw std::runtime_error{std::format(
+                                "{}: Group {} has more than one member but "
+                                "isn't numeric",
+                                ActionBase::getName(), group.getName())};
+                        }
+                    },
                     value);
                 checked = true;
             }
diff --git a/control/json/actions/missing_owner_target.cpp b/control/json/actions/missing_owner_target.cpp
index deed3cb..40894be 100644
--- a/control/json/actions/missing_owner_target.cpp
+++ b/control/json/actions/missing_owner_target.cpp
@@ -46,8 +46,8 @@
         auto isMissingOwner =
             std::any_of(members.begin(), members.end(),
                         [&intf = group.getInterface()](const auto& member) {
-            return !Manager::hasOwner(member, intf);
-        });
+                            return !Manager::hasOwner(member, intf);
+                        });
         // Update zone's target hold based on action results
         zone.setTargetHold(group.getName(), _target, isMissingOwner);
     }
diff --git a/control/json/actions/net_target_increase.cpp b/control/json/actions/net_target_increase.cpp
index 7341a35..9c712a7 100644
--- a/control/json/actions/net_target_increase.cpp
+++ b/control/json/actions/net_target_increase.cpp
@@ -57,77 +57,80 @@
     for (const auto& group : _groups)
     {
         const auto& members = group.getMembers();
-        std::for_each(members.begin(), members.end(),
-                      [this, &zone, &group, &netDelta](const auto& member) {
-            try
-            {
-                auto value = Manager::getObjValueVariant(
-                    member, group.getInterface(), group.getProperty());
-                if (std::holds_alternative<int64_t>(value) ||
-                    std::holds_alternative<double>(value))
+        std::for_each(
+            members.begin(), members.end(),
+            [this, &zone, &group, &netDelta](const auto& member) {
+                try
                 {
-                    // Where a group of int/doubles are greater than or
-                    // equal to the state(some value) provided, request an
-                    // increase of the configured delta times the difference
-                    // between the group member's value and configured state
-                    // value.
-                    if (value >= _state)
+                    auto value = Manager::getObjValueVariant(
+                        member, group.getInterface(), group.getProperty());
+                    if (std::holds_alternative<int64_t>(value) ||
+                        std::holds_alternative<double>(value))
                     {
-                        uint64_t incDelta = 0;
-                        if (auto dblPtr = std::get_if<double>(&value))
+                        // Where a group of int/doubles are greater than or
+                        // equal to the state(some value) provided, request an
+                        // increase of the configured delta times the difference
+                        // between the group member's value and configured state
+                        // value.
+                        if (value >= _state)
                         {
-                            incDelta = static_cast<uint64_t>(
-                                (*dblPtr - std::get<double>(_state)) * _delta);
+                            uint64_t incDelta = 0;
+                            if (auto dblPtr = std::get_if<double>(&value))
+                            {
+                                incDelta = static_cast<uint64_t>(
+                                    (*dblPtr - std::get<double>(_state)) *
+                                    _delta);
+                            }
+                            else
+                            {
+                                // Increase by at least a single delta
+                                // to attempt bringing under provided 'state'
+                                auto deltaFactor =
+                                    std::max((std::get<int64_t>(value) -
+                                              std::get<int64_t>(_state)),
+                                             int64_t(1));
+                                incDelta =
+                                    static_cast<uint64_t>(deltaFactor * _delta);
+                            }
+                            netDelta = std::max(netDelta, incDelta);
                         }
-                        else
+                    }
+                    else if (std::holds_alternative<bool>(value))
+                    {
+                        // Where a group of booleans equal the state(`true` or
+                        // `false`) provided, request an increase of the
+                        // configured delta
+                        if (_state == value)
                         {
-                            // Increase by at least a single delta
-                            // to attempt bringing under provided 'state'
-                            auto deltaFactor =
-                                std::max((std::get<int64_t>(value) -
-                                          std::get<int64_t>(_state)),
-                                         int64_t(1));
-                            incDelta =
-                                static_cast<uint64_t>(deltaFactor * _delta);
+                            netDelta = std::max(netDelta, _delta);
                         }
-                        netDelta = std::max(netDelta, incDelta);
                     }
-                }
-                else if (std::holds_alternative<bool>(value))
-                {
-                    // Where a group of booleans equal the state(`true` or
-                    // `false`) provided, request an increase of the
-                    // configured delta
-                    if (_state == value)
+                    else if (std::holds_alternative<std::string>(value))
                     {
-                        netDelta = std::max(netDelta, _delta);
+                        // Where a group of strings equal the state(some string)
+                        // provided, request an increase of the configured delta
+                        if (_state == value)
+                        {
+                            netDelta = std::max(netDelta, _delta);
+                        }
                     }
-                }
-                else if (std::holds_alternative<std::string>(value))
-                {
-                    // Where a group of strings equal the state(some string)
-                    // provided, request an increase of the configured delta
-                    if (_state == value)
+                    else
                     {
-                        netDelta = std::max(netDelta, _delta);
+                        // Unsupported group member type for this action
+                        log<level::ERR>(
+                            std::format(
+                                "Action {}: Unsupported group member type "
+                                "given. [object = {} : {} : {}]",
+                                ActionBase::getName(), member,
+                                group.getInterface(), group.getProperty())
+                                .c_str());
                     }
                 }
-                else
+                catch (const std::out_of_range& oore)
                 {
-                    // Unsupported group member type for this action
-                    log<level::ERR>(
-                        std::format("Action {}: Unsupported group member type "
-                                    "given. [object = {} : {} : {}]",
-                                    ActionBase::getName(), member,
-                                    group.getInterface(), group.getProperty())
-                            .c_str());
+                    // Property value not found, netDelta unchanged
                 }
-            }
-            catch (const std::out_of_range& oore)
-            {
-                // Property value not found, netDelta unchanged
-            }
-        });
+            });
     }
     // Request increase to target
     zone.requestIncrease(netDelta);
diff --git a/control/json/actions/override_fan_target.cpp b/control/json/actions/override_fan_target.cpp
index 103008a..33fbd34 100644
--- a/control/json/actions/override_fan_target.cpp
+++ b/control/json/actions/override_fan_target.cpp
@@ -87,8 +87,8 @@
         {
             fanList = std::accumulate(std::next(_fans.begin()), _fans.end(),
                                       _fans[0], [](auto list, auto fan) {
-                return std::move(list) + ", " + fan;
-            });
+                                          return std::move(list) + ", " + fan;
+                                      });
         }
 
         record(std::format("Adding fan target lock of {} on fans [{}] zone {}",
diff --git a/control/json/actions/pcie_card_floors.cpp b/control/json/actions/pcie_card_floors.cpp
index 106d42f..a5cfee5 100644
--- a/control/json/actions/pcie_card_floors.cpp
+++ b/control/json/actions/pcie_card_floors.cpp
@@ -221,8 +221,8 @@
         auto deviceID = getPCIeDeviceProperty(card, deviceIDProp);
         auto vendorID = getPCIeDeviceProperty(card, vendorIDProp);
         auto subsystemID = getPCIeDeviceProperty(card, subsystemIDProp);
-        auto subsystemVendorID = getPCIeDeviceProperty(card,
-                                                       subsystemVendorIDProp);
+        auto subsystemVendorID =
+            getPCIeDeviceProperty(card, subsystemVendorIDProp);
 
         return _cardMetadata->lookup(deviceID, vendorID, subsystemID,
                                      subsystemVendorID);
@@ -251,10 +251,10 @@
 
     // Find the card that plugs in this slot based on if the
     // slot is part of the path, like slotA/cardA
-    auto it = std::find_if(_pcieDevices.begin(), _pcieDevices.end(),
-                           [slotPath](const auto& path) {
-        return path.find(slotPath + '/') != std::string::npos;
-    });
+    auto it = std::find_if(
+        _pcieDevices.begin(), _pcieDevices.end(), [slotPath](const auto& path) {
+            return path.find(slotPath + '/') != std::string::npos;
+        });
 
     if (it == _pcieDevices.end())
     {
diff --git a/control/json/actions/set_parameter_from_group_max.cpp b/control/json/actions/set_parameter_from_group_max.cpp
index 99e184f..811f37c 100644
--- a/control/json/actions/set_parameter_from_group_max.cpp
+++ b/control/json/actions/set_parameter_from_group_max.cpp
@@ -64,20 +64,20 @@
                 bool invalid = false;
                 std::visit(
                     [&group, &invalid, this](auto&& val) {
-                    using V = std::decay_t<decltype(val)>;
-                    if constexpr (!std::is_same_v<double, V> &&
-                                  !std::is_same_v<int32_t, V> &&
-                                  !std::is_same_v<int64_t, V>)
-                    {
-                        log<level::ERR>(std::format("{}: Group {} has more "
-                                                    "than one member but "
-                                                    "isn't numeric",
-                                                    ActionBase::getName(),
-                                                    group.getName())
-                                            .c_str());
-                        invalid = true;
-                    }
-                },
+                        using V = std::decay_t<decltype(val)>;
+                        if constexpr (!std::is_same_v<double, V> &&
+                                      !std::is_same_v<int32_t, V> &&
+                                      !std::is_same_v<int64_t, V>)
+                        {
+                            log<level::ERR>(std::format("{}: Group {} has more "
+                                                        "than one member but "
+                                                        "isn't numeric",
+                                                        ActionBase::getName(),
+                                                        group.getName())
+                                                .c_str());
+                            invalid = true;
+                        }
+                    },
                     value);
                 if (invalid)
                 {
diff --git a/control/json/actions/target_from_group_max.cpp b/control/json/actions/target_from_group_max.cpp
index 45216bb..d92457d 100644
--- a/control/json/actions/target_from_group_max.cpp
+++ b/control/json/actions/target_from_group_max.cpp
@@ -185,19 +185,19 @@
             // considered numeric here.
             std::visit(
                 [&group, &invalid, this](auto&& val) {
-                using V = std::decay_t<decltype(val)>;
-                if constexpr (!std::is_same_v<double, V> &&
-                              !std::is_same_v<int32_t, V> &&
-                              !std::is_same_v<int64_t, V>)
-                {
-                    log<level::ERR>(std::format("{}: Group {}'s member "
-                                                "isn't numeric",
-                                                ActionBase::getName(),
-                                                group.getName())
-                                        .c_str());
-                    invalid = true;
-                }
-            },
+                    using V = std::decay_t<decltype(val)>;
+                    if constexpr (!std::is_same_v<double, V> &&
+                                  !std::is_same_v<int32_t, V> &&
+                                  !std::is_same_v<int64_t, V>)
+                    {
+                        log<level::ERR>(
+                            std::format("{}: Group {}'s member "
+                                        "isn't numeric",
+                                        ActionBase::getName(), group.getName())
+                                .c_str());
+                        invalid = true;
+                    }
+                },
                 value);
             if (invalid)
             {
diff --git a/control/json/actions/timer_based_actions.cpp b/control/json/actions/timer_based_actions.cpp
index 02779bd..21dbc29 100644
--- a/control/json/actions/timer_based_actions.cpp
+++ b/control/json/actions/timer_based_actions.cpp
@@ -42,9 +42,10 @@
 {
     // If any of groups' value == nullopt(i.e. not configured), action is
     // driven by the service owned state of the group members
-    _byOwner = std::any_of(
-        _groups.begin(), _groups.end(),
-        [](const auto& group) { return group.getValue() == std::nullopt; });
+    _byOwner =
+        std::any_of(_groups.begin(), _groups.end(), [](const auto& group) {
+            return group.getValue() == std::nullopt;
+        });
 
     setTimerConf(jsonObj);
     setActions(jsonObj);
@@ -57,12 +58,13 @@
         // If any service providing a group member is not owned, start
         // timer and if all members' services are owned, stop timer.
         if (std::any_of(_groups.begin(), _groups.end(), [](const auto& group) {
-            const auto& members = group.getMembers();
-            return std::any_of(members.begin(), members.end(),
-                               [&group](const auto& member) {
-                return !Manager::hasOwner(member, group.getInterface());
-            });
-        }))
+                const auto& members = group.getMembers();
+                return std::any_of(
+                    members.begin(), members.end(),
+                    [&group](const auto& member) {
+                        return !Manager::hasOwner(member, group.getInterface());
+                    });
+            }))
         {
             startTimer();
         }
@@ -77,16 +79,18 @@
         // If all group members have a given value and it matches what's
         // in the cache, start timer and if any do not match, stop
         // timer.
-        if (std::all_of(_groups.begin(), _groups.end(),
-                        [&mgr](const auto& group) {
-            const auto& members = group.getMembers();
-            return std::all_of(members.begin(), members.end(),
-                               [&mgr, &group](const auto& member) {
-                return group.getValue() ==
-                       mgr->getProperty(member, group.getInterface(),
-                                        group.getProperty());
-            });
-        }))
+        if (std::all_of(
+                _groups.begin(), _groups.end(), [&mgr](const auto& group) {
+                    const auto& members = group.getMembers();
+                    return std::all_of(
+                        members.begin(), members.end(),
+                        [&mgr, &group](const auto& member) {
+                            return group.getValue() ==
+                                   mgr->getProperty(member,
+                                                    group.getInterface(),
+                                                    group.getProperty());
+                        });
+                }))
         {
             // Timer will be started(and never stopped) when _groups is empty
             startTimer();
@@ -143,8 +147,8 @@
         // Add zone to _actions
         std::for_each(_actions.begin(), _actions.end(),
                       [&zone](std::unique_ptr<ActionBase>& action) {
-            action->addZone(zone);
-        });
+                          action->addZone(zone);
+                      });
     }
 }
 
diff --git a/control/json/dbus_zone.cpp b/control/json/dbus_zone.cpp
index 6e269c3..a8cbe01 100644
--- a/control/json/dbus_zone.cpp
+++ b/control/json/dbus_zone.cpp
@@ -49,11 +49,11 @@
     std::transform(value.begin(), value.end(), value.begin(), toupper);
 
     auto supported = ThermalModeIntf::supported();
-    auto isSupported = std::any_of(supported.begin(), supported.end(),
-                                   [&value](auto& s) {
-        std::transform(s.begin(), s.end(), s.begin(), toupper);
-        return value == s;
-    });
+    auto isSupported =
+        std::any_of(supported.begin(), supported.end(), [&value](auto& s) {
+            std::transform(s.begin(), s.end(), s.begin(), toupper);
+            return value == s;
+        });
 
     if (isSupported && value != current)
     {
diff --git a/control/json/event.cpp b/control/json/event.cpp
index 628c222..0e7f1e5 100644
--- a/control/json/event.cpp
+++ b/control/json/event.cpp
@@ -40,8 +40,8 @@
 
 Event::Event(const json& jsonObj, Manager* mgr,
              std::map<configKey, std::unique_ptr<Zone>>& zones) :
-    ConfigBase(jsonObj),
-    _bus(util::SDBusPlus::getBus()), _manager(mgr), _zones(zones)
+    ConfigBase(jsonObj), _bus(util::SDBusPlus::getBus()), _manager(mgr),
+    _zones(zones)
 {
     // Event groups are optional
     if (jsonObj.contains("groups"))
@@ -155,10 +155,11 @@
 
             configKey eventProfile =
                 std::make_pair(jsonGrp["name"].get<std::string>(), profiles);
-            auto grpEntry = std::find_if(availGroups.begin(), availGroups.end(),
-                                         [&eventProfile](const auto& grp) {
-                return Manager::inConfig(grp.first, eventProfile);
-            });
+            auto grpEntry = std::find_if(
+                availGroups.begin(), availGroups.end(),
+                [&eventProfile](const auto& grp) {
+                    return Manager::inConfig(grp.first, eventProfile);
+                });
             if (grpEntry != availGroups.end())
             {
                 auto group = Group(*grpEntry->second);
@@ -188,12 +189,13 @@
             // against all zones matching the event's active profiles
             for (const auto& zone : _zones)
             {
-                configKey eventProfile = std::make_pair(zone.second->getName(),
-                                                        _profiles);
-                auto zoneEntry = std::find_if(_zones.begin(), _zones.end(),
-                                              [&eventProfile](const auto& z) {
-                    return Manager::inConfig(z.first, eventProfile);
-                });
+                configKey eventProfile =
+                    std::make_pair(zone.second->getName(), _profiles);
+                auto zoneEntry = std::find_if(
+                    _zones.begin(), _zones.end(),
+                    [&eventProfile](const auto& z) {
+                        return Manager::inConfig(z.first, eventProfile);
+                    });
                 if (zoneEntry != _zones.end())
                 {
                     actionZones.emplace_back(*zoneEntry->second);
@@ -208,10 +210,11 @@
             {
                 configKey eventProfile =
                     std::make_pair(jsonZone.get<std::string>(), _profiles);
-                auto zoneEntry = std::find_if(_zones.begin(), _zones.end(),
-                                              [&eventProfile](const auto& z) {
-                    return Manager::inConfig(z.first, eventProfile);
-                });
+                auto zoneEntry = std::find_if(
+                    _zones.begin(), _zones.end(),
+                    [&eventProfile](const auto& z) {
+                        return Manager::inConfig(z.first, eventProfile);
+                    });
                 if (zoneEntry != _zones.end())
                 {
                     actionZones.emplace_back(*zoneEntry->second);
@@ -299,8 +302,8 @@
             auto availTrigs = std::accumulate(
                 std::next(trigger::triggers.begin()), trigger::triggers.end(),
                 trigger::triggers.begin()->first, [](auto list, auto trig) {
-                return std::move(list) + ", " + trig.first;
-            });
+                    return std::move(list) + ", " + trig.first;
+                });
             log<level::ERR>(
                 std::format("Trigger '{}' is not recognized", tClass).c_str(),
                 entry("AVAILABLE_TRIGGERS=%s", availTrigs.c_str()));
@@ -314,14 +317,14 @@
     json actionData;
     std::for_each(_actions.begin(), _actions.end(),
                   [&actionData](const auto& action) {
-        actionData[action->getUniqueName()] = action->dump();
-    });
+                      actionData[action->getUniqueName()] = action->dump();
+                  });
 
     std::vector<std::string> groupData;
     std::for_each(_groups.begin(), _groups.end(),
                   [&groupData](const auto& group) {
-        groupData.push_back(group.getName());
-    });
+                      groupData.push_back(group.getName());
+                  });
 
     json eventData;
     eventData["groups"] = groupData;
diff --git a/control/json/fan.cpp b/control/json/fan.cpp
index 5abcfbe..a808003 100644
--- a/control/json/fan.cpp
+++ b/control/json/fan.cpp
@@ -155,8 +155,8 @@
         // if additional locks, re-lock at next-highest target
         if (!_lockedTargets.empty())
         {
-            itr = std::max_element(_lockedTargets.begin(),
-                                   _lockedTargets.end());
+            itr =
+                std::max_element(_lockedTargets.begin(), _lockedTargets.end());
 
             // setTarget wont work if any locked targets exist
             decltype(_lockedTargets) temp;
diff --git a/control/json/manager.cpp b/control/json/manager.cpp
index 0161304..6ae51c9 100644
--- a/control/json/manager.cpp
+++ b/control/json/manager.cpp
@@ -168,12 +168,12 @@
         auto fans = getConfig<Fan>(false);
         for (auto& fan : fans)
         {
-            configKey fanProfile = std::make_pair(fan.second->getZone(),
-                                                  fan.first.second);
-            auto itZone = std::find_if(zones.begin(), zones.end(),
-                                       [&fanProfile](const auto& zone) {
-                return Manager::inConfig(fanProfile, zone.first);
-            });
+            configKey fanProfile =
+                std::make_pair(fan.second->getZone(), fan.first.second);
+            auto itZone = std::find_if(
+                zones.begin(), zones.end(), [&fanProfile](const auto& zone) {
+                    return Manager::inConfig(fanProfile, zone.first);
+                });
             if (itZone != zones.end())
             {
                 if (itZone->second->getTarget() != fan.second->getTarget() &&
@@ -273,19 +273,21 @@
     {
         // Profiles must have one match in the other's profiles(and they must be
         // an active profile) to be used in the config
-        return std::any_of(input.second.begin(), input.second.end(),
-                           [&comp](const auto& lProfile) {
-            return std::any_of(comp.second.begin(), comp.second.end(),
-                               [&lProfile](const auto& rProfile) {
-                if (lProfile != rProfile)
-                {
-                    return false;
-                }
-                auto activeProfs = getActiveProfiles();
-                return std::find(activeProfs.begin(), activeProfs.end(),
-                                 lProfile) != activeProfs.end();
+        return std::any_of(
+            input.second.begin(), input.second.end(),
+            [&comp](const auto& lProfile) {
+                return std::any_of(
+                    comp.second.begin(), comp.second.end(),
+                    [&lProfile](const auto& rProfile) {
+                        if (lProfile != rProfile)
+                        {
+                            return false;
+                        }
+                        auto activeProfs = getActiveProfiles();
+                        return std::find(activeProfs.begin(), activeProfs.end(),
+                                         lProfile) != activeProfs.end();
+                    });
             });
-        });
     }
 }
 
@@ -416,8 +418,8 @@
                 if (servIter != pathIter->second.end())
                 {
                     if (std::find(servIter->second.second.begin(),
-                                  servIter->second.second.end(),
-                                  intf) == servIter->second.second.end())
+                                  servIter->second.second.end(), intf) ==
+                        servIter->second.second.end())
                     {
                         // Add interface to cache
                         servIter->second.second.emplace_back(intf);
@@ -427,8 +429,8 @@
                 {
                     // Service not found in cache
                     auto intfs = {intf};
-                    pathIter->second[itServ.first] = std::make_pair(true,
-                                                                    intfs);
+                    pathIter->second[itServ.first] =
+                        std::make_pair(true, intfs);
                 }
             }
         }
@@ -458,8 +460,8 @@
     return serviceName;
 }
 
-std::vector<std::string> Manager::findPaths(const std::string& serv,
-                                            const std::string& intf)
+std::vector<std::string>
+    Manager::findPaths(const std::string& serv, const std::string& intf)
 {
     std::vector<std::string> paths;
 
@@ -469,8 +471,8 @@
         if (itServ != path.second.end())
         {
             if (std::find(itServ->second.second.begin(),
-                          itServ->second.second.end(),
-                          intf) != itServ->second.second.end())
+                          itServ->second.second.end(), intf) !=
+                itServ->second.second.end())
             {
                 if (std::find(paths.begin(), paths.end(), path.first) ==
                     paths.end())
@@ -598,9 +600,8 @@
     }
 }
 
-const std::optional<PropertyVariantType>
-    Manager::getProperty(const std::string& path, const std::string& intf,
-                         const std::string& prop)
+const std::optional<PropertyVariantType> Manager::getProperty(
+    const std::string& path, const std::string& intf, const std::string& prop)
 {
     // TODO Objects hosted by fan control (i.e. ThermalMode) are required to
     // update the cache upon being set/updated
@@ -691,11 +692,11 @@
 
                     // Look for the ObjectManager as an ancestor from the
                     // member.
-                    auto hasObjMgr = std::any_of(objMgrPaths.begin(),
-                                                 objMgrPaths.end(),
-                                                 [&member](const auto& path) {
-                        return member.find(path) != std::string::npos;
-                    });
+                    auto hasObjMgr = std::any_of(
+                        objMgrPaths.begin(), objMgrPaths.end(),
+                        [&member](const auto& path) {
+                            return member.find(path) != std::string::npos;
+                        });
 
                     if (!hasObjMgr)
                     {
@@ -756,12 +757,12 @@
     // Remove oneshot timers after they expired
     if (data.first == TimerType::oneshot)
     {
-        auto itTimer = std::find_if(_timers.begin(), _timers.end(),
-                                    [&data](const auto& timer) {
-            return (data.first == timer.first->first &&
-                    (std::get<std::string>(data.second) ==
-                     std::get<std::string>(timer.first->second)));
-        });
+        auto itTimer = std::find_if(
+            _timers.begin(), _timers.end(), [&data](const auto& timer) {
+                return (data.first == timer.first->first &&
+                        (std::get<std::string>(data.second) ==
+                         std::get<std::string>(timer.first->second)));
+            });
         if (itTimer != std::end(_timers))
         {
             _timers.erase(itTimer);
@@ -776,8 +777,8 @@
     {
         // Handle the signal callback and only run the actions if the handler
         // updated the cache for the given SignalObject
-        if (std::get<SignalHandler>(pkg)(msg, std::get<SignalObject>(pkg),
-                                         *this))
+        if (std::get<SignalHandler>(
+                pkg)(msg, std::get<SignalObject>(pkg), *this))
         {
             // Perform the actions in the handler package
             auto& actions = std::get<TriggerActions>(pkg);
@@ -799,8 +800,8 @@
 void Manager::setProfiles()
 {
     // Profiles JSON config file is optional
-    auto confFile = fan::JsonConfig::getConfFile(confAppName,
-                                                 Profile::confFileName, true);
+    auto confFile =
+        fan::JsonConfig::getConfFile(confAppName, Profile::confFileName, true);
 
     _profiles.clear();
     if (!confFile.empty())
@@ -834,16 +835,16 @@
     {
         std::for_each(actions.begin(), actions.end(),
                       [&actList = it->second](auto& action) {
-            actList.emplace_back(std::ref(action));
-        });
+                          actList.emplace_back(std::ref(action));
+                      });
     }
     else
     {
         TriggerActions triggerActions;
         std::for_each(actions.begin(), actions.end(),
                       [&triggerActions](auto& action) {
-            triggerActions.emplace_back(std::ref(action));
-        });
+                          triggerActions.emplace_back(std::ref(action));
+                      });
         _parameterTriggers[name] = std::move(triggerActions);
     }
 }
diff --git a/control/json/manager.hpp b/control/json/manager.hpp
index d7657e9..2f66181 100644
--- a/control/json/manager.hpp
+++ b/control/json/manager.hpp
@@ -198,8 +198,8 @@
      *     Map of configuration keys to their corresponding configuration object
      */
     template <typename T, typename... Args>
-    static std::map<configKey, std::unique_ptr<T>> getConfig(bool isOptional,
-                                                             Args&&... args)
+    static std::map<configKey, std::unique_ptr<T>>
+        getConfig(bool isOptional, Args&&... args)
     {
         std::map<configKey, std::unique_ptr<T>> config;
 
@@ -226,16 +226,18 @@
                     if (!profiles.empty() &&
                         !std::any_of(profiles.begin(), profiles.end(),
                                      [](const auto& name) {
-                        return std::find(getActiveProfiles().begin(),
-                                         getActiveProfiles().end(),
-                                         name) != getActiveProfiles().end();
-                    }))
+                                         return std::find(
+                                                    getActiveProfiles().begin(),
+                                                    getActiveProfiles().end(),
+                                                    name) !=
+                                                getActiveProfiles().end();
+                                     }))
                     {
                         continue;
                     }
                 }
-                auto obj = std::make_unique<T>(entry,
-                                               std::forward<Args>(args)...);
+                auto obj =
+                    std::make_unique<T>(entry, std::forward<Args>(args)...);
                 config.emplace(
                     std::make_pair(obj->getName(), obj->getProfiles()),
                     std::move(obj));
diff --git a/control/json/profile.cpp b/control/json/profile.cpp
index 7cb818b..0778820 100644
--- a/control/json/profile.cpp
+++ b/control/json/profile.cpp
@@ -60,11 +60,11 @@
     else
     {
         // Construct list of available methods
-        auto methods = std::accumulate(std::next(_methods.begin()),
-                                       _methods.end(), _methods.begin()->first,
-                                       [](auto list, auto method) {
-            return std::move(list) + ", " + method.first;
-        });
+        auto methods = std::accumulate(
+            std::next(_methods.begin()), _methods.end(),
+            _methods.begin()->first, [](auto list, auto method) {
+                return std::move(list) + ", " + method.first;
+            });
         log<level::ERR>("Configured method not available",
                         entry("JSON=%s", jsonObj["method"].dump().c_str()),
                         entry("METHODS_AVAILABLE=%s", methods.c_str()));
@@ -81,23 +81,26 @@
             "Missing required all_of method properties list");
     }
 
-    return std::all_of(method["properties"].begin(), method["properties"].end(),
-                       [](const json& obj) {
-        if (!obj.contains("path") || !obj.contains("interface") ||
-            !obj.contains("property") || !obj.contains("value"))
-        {
-            log<level::ERR>(
-                "Missing required all_of method property parameters",
-                entry("JSON=%s", obj.dump().c_str()));
-            throw std::runtime_error(
-                "Missing required all_of method parameters");
-        }
-        auto variant = util::SDBusPlus::getPropertyVariant<PropertyVariantType>(
-            obj["path"].get<std::string>(), obj["interface"].get<std::string>(),
-            obj["property"].get<std::string>());
+    return std::all_of(
+        method["properties"].begin(), method["properties"].end(),
+        [](const json& obj) {
+            if (!obj.contains("path") || !obj.contains("interface") ||
+                !obj.contains("property") || !obj.contains("value"))
+            {
+                log<level::ERR>(
+                    "Missing required all_of method property parameters",
+                    entry("JSON=%s", obj.dump().c_str()));
+                throw std::runtime_error(
+                    "Missing required all_of method parameters");
+            }
+            auto variant =
+                util::SDBusPlus::getPropertyVariant<PropertyVariantType>(
+                    obj["path"].get<std::string>(),
+                    obj["interface"].get<std::string>(),
+                    obj["property"].get<std::string>());
 
-        return getJsonValue(obj["value"]) == variant;
-    });
+            return getJsonValue(obj["value"]) == variant;
+        });
 }
 
 } // namespace phosphor::fan::control::json
diff --git a/control/json/triggers/handlers.hpp b/control/json/triggers/handlers.hpp
index 8e8595f..a263295 100644
--- a/control/json/triggers/handlers.hpp
+++ b/control/json/triggers/handlers.hpp
@@ -112,8 +112,8 @@
 
         std::vector<std::string> intfs;
         msg.read(intfs);
-        auto itIntf = std::find(intfs.begin(), intfs.end(),
-                                std::get<Intf>(obj));
+        auto itIntf =
+            std::find(intfs.begin(), intfs.end(), std::get<Intf>(obj));
         if (itIntf == intfs.cend())
         {
             // Object's interface not in list of interfaces removed
diff --git a/control/json/triggers/init.cpp b/control/json/triggers/init.cpp
index bd557d7..3d9a535 100644
--- a/control/json/triggers/init.cpp
+++ b/control/json/triggers/init.cpp
@@ -162,8 +162,8 @@
             auto availMethods = std::accumulate(
                 std::next(methods.begin()), methods.end(),
                 methods.begin()->first, [](auto list, auto method) {
-                return std::move(list) + ", " + method.first;
-            });
+                    return std::move(list) + ", " + method.first;
+                });
             auto msg =
                 std::format("Event '{}' requires a supported method given to "
                             "be init driven, available methods: {}",
diff --git a/control/json/triggers/signal.cpp b/control/json/triggers/signal.cpp
index 537ef50..c0641d9 100644
--- a/control/json/triggers/signal.cpp
+++ b/control/json/triggers/signal.cpp
@@ -100,13 +100,13 @@
     {
         // Setup property changed signal handler on the group member's
         // property
-        const auto match = rules::propertiesChanged(member,
-                                                    group.getInterface());
-        SignalPkg signalPkg = {Handlers::propertiesChanged,
-                               SignalObject(std::cref(member),
-                                            std::cref(group.getInterface()),
-                                            std::cref(group.getProperty())),
-                               actions};
+        const auto match =
+            rules::propertiesChanged(member, group.getInterface());
+        SignalPkg signalPkg = {
+            Handlers::propertiesChanged,
+            SignalObject(std::cref(member), std::cref(group.getInterface()),
+                         std::cref(group.getProperty())),
+            actions};
         auto isSameSig = [&prop = group.getProperty()](SignalPkg& pkg) {
             auto& obj = std::get<SignalObject>(pkg);
             return prop == std::get<Prop>(obj);
@@ -124,13 +124,13 @@
     for (const auto& member : group.getMembers())
     {
         // Setup interfaces added signal handler on the group member
-        const auto match = rules::interfacesAdded() +
-                           rules::argNpath(0, member);
-        SignalPkg signalPkg = {Handlers::interfacesAdded,
-                               SignalObject(std::cref(member),
-                                            std::cref(group.getInterface()),
-                                            std::cref(group.getProperty())),
-                               actions};
+        const auto match =
+            rules::interfacesAdded() + rules::argNpath(0, member);
+        SignalPkg signalPkg = {
+            Handlers::interfacesAdded,
+            SignalObject(std::cref(member), std::cref(group.getInterface()),
+                         std::cref(group.getProperty())),
+            actions};
         auto isSameSig = [&intf = group.getInterface()](SignalPkg& pkg) {
             auto& obj = std::get<SignalObject>(pkg);
             return intf == std::get<Intf>(obj);
@@ -148,13 +148,13 @@
     for (const auto& member : group.getMembers())
     {
         // Setup interfaces removed signal handler on the group member
-        const auto match = rules::interfacesRemoved() +
-                           rules::argNpath(0, member);
-        SignalPkg signalPkg = {Handlers::interfacesRemoved,
-                               SignalObject(std::cref(member),
-                                            std::cref(group.getInterface()),
-                                            std::cref(group.getProperty())),
-                               actions};
+        const auto match =
+            rules::interfacesRemoved() + rules::argNpath(0, member);
+        SignalPkg signalPkg = {
+            Handlers::interfacesRemoved,
+            SignalObject(std::cref(member), std::cref(group.getInterface()),
+                         std::cref(group.getProperty())),
+            actions};
         auto isSameSig = [&intf = group.getInterface()](SignalPkg& pkg) {
             auto& obj = std::get<SignalObject>(pkg);
             return intf == std::get<Intf>(obj);
@@ -252,8 +252,8 @@
         auto availSignals =
             std::accumulate(std::next(signals.begin()), signals.end(),
                             signals.begin()->first, [](auto list, auto signal) {
-            return std::move(list) + ", " + signal.first;
-        });
+                                return std::move(list) + ", " + signal.first;
+                            });
         auto msg =
             std::format("Event '{}' requires a supported signal given to be "
                         "triggered by signal, available signals: {}",
@@ -269,8 +269,8 @@
         TriggerActions signalActions;
         std::for_each(actions.begin(), actions.end(),
                       [&signalActions](auto& action) {
-            signalActions.emplace_back(std::ref(action));
-        });
+                          signalActions.emplace_back(std::ref(action));
+                      });
         for (const auto& group : groups)
         {
             // Call signal subscriber for each group
diff --git a/control/json/utils/flight_recorder.cpp b/control/json/utils/flight_recorder.cpp
index 00325f5..b26d2d8 100644
--- a/control/json/utils/flight_recorder.cpp
+++ b/control/json/utils/flight_recorder.cpp
@@ -70,8 +70,8 @@
 
     std::sort(output.begin(), output.end(),
               [](const auto& left, const auto& right) {
-        return std::get<Timepoint>(left) < std::get<Timepoint>(right);
-    });
+                  return std::get<Timepoint>(left) < std::get<Timepoint>(right);
+              });
 
     auto formatTime = [](const Timepoint& tp) {
         std::stringstream ss;
diff --git a/control/json/utils/pcie_card_metadata.cpp b/control/json/utils/pcie_card_metadata.cpp
index ec6452c..c8c1b37 100644
--- a/control/json/utils/pcie_card_metadata.cpp
+++ b/control/json/utils/pcie_card_metadata.cpp
@@ -112,10 +112,10 @@
         }
 
         Metadata data;
-        data.vendorID = std::stoul(card.at("vendor_id").get<std::string>(),
-                                   nullptr, 16);
-        data.deviceID = std::stoul(card.at("device_id").get<std::string>(),
-                                   nullptr, 16);
+        data.vendorID =
+            std::stoul(card.at("vendor_id").get<std::string>(), nullptr, 16);
+        data.deviceID =
+            std::stoul(card.at("device_id").get<std::string>(), nullptr, 16);
         data.subsystemVendorID = std::stoul(
             card.at("subsystem_vendor_id").get<std::string>(), nullptr, 16);
         data.subsystemID =
@@ -157,21 +157,21 @@
     }
 }
 
-std::optional<std::variant<int32_t, bool>>
-    PCIeCardMetadata::lookup(uint16_t deviceID, uint16_t vendorID,
-                             uint16_t subsystemID,
-                             uint16_t subsystemVendorID) const
+std::optional<std::variant<int32_t, bool>> PCIeCardMetadata::lookup(
+    uint16_t deviceID, uint16_t vendorID, uint16_t subsystemID,
+    uint16_t subsystemVendorID) const
 {
     log<level::DEBUG>(std::format("Lookup {:#x} ${:#x} {:#x} {:#x}", deviceID,
                                   vendorID, subsystemID, subsystemVendorID)
                           .c_str());
-    auto card = std::find_if(_cards.begin(), _cards.end(),
-                             [&deviceID, &vendorID, &subsystemID,
-                              &subsystemVendorID](const auto& card) {
-        return (deviceID == card.deviceID) && (vendorID == card.vendorID) &&
-               (subsystemID == card.subsystemID) &&
-               (subsystemVendorID == card.subsystemVendorID);
-    });
+    auto card = std::find_if(
+        _cards.begin(), _cards.end(),
+        [&deviceID, &vendorID, &subsystemID,
+         &subsystemVendorID](const auto& card) {
+            return (deviceID == card.deviceID) && (vendorID == card.vendorID) &&
+                   (subsystemID == card.subsystemID) &&
+                   (subsystemVendorID == card.subsystemVendorID);
+        });
 
     if (card != _cards.end())
     {
diff --git a/control/json/zone.cpp b/control/json/zone.cpp
index 12f8c02..8dc6044 100644
--- a/control/json/zone.cpp
+++ b/control/json/zone.cpp
@@ -161,9 +161,10 @@
 
 void Zone::lockFanTarget(const std::string& fname, uint64_t target)
 {
-    auto fanItr = std::find_if(
-        _fans.begin(), _fans.end(),
-        [&fname](const auto& fan) { return fan->getName() == fname; });
+    auto fanItr =
+        std::find_if(_fans.begin(), _fans.end(), [&fname](const auto& fan) {
+            return fan->getName() == fname;
+        });
 
     if (_fans.end() != fanItr)
     {
@@ -180,9 +181,10 @@
 
 void Zone::unlockFanTarget(const std::string& fname, uint64_t target)
 {
-    auto fanItr = std::find_if(
-        _fans.begin(), _fans.end(),
-        [&fname](const auto& fan) { return fan->getName() == fname; });
+    auto fanItr =
+        std::find_if(_fans.begin(), _fans.end(), [&fname](const auto& fan) {
+            return fan->getName() == fname;
+        });
 
     if (_fans.end() != fanItr)
     {
@@ -230,8 +232,8 @@
 
     auto itHoldMax = std::max_element(_targetHolds.begin(), _targetHolds.end(),
                                       [](const auto& aHold, const auto& bHold) {
-        return aHold.second < bHold.second;
-    });
+                                          return aHold.second < bHold.second;
+                                      });
     if (itHoldMax == _targetHolds.end())
     {
         _isActive = true;
@@ -293,8 +295,8 @@
 
     auto itHoldMax = std::max_element(_floorHolds.begin(), _floorHolds.end(),
                                       [](const auto& aHold, const auto& bHold) {
-        return aHold.second < bHold.second;
-    });
+                                          return aHold.second < bHold.second;
+                                      });
     if (itHoldMax == _floorHolds.end())
     {
         if (_floor != _defaultFloor)
@@ -461,8 +463,8 @@
             auto intfs = std::accumulate(
                 std::next(_intfPropHandlers.begin()), _intfPropHandlers.end(),
                 _intfPropHandlers.begin()->first, [](auto list, auto intf) {
-                return std::move(list) + ", " + intf.first;
-            });
+                    return std::move(list) + ", " + intf.first;
+                });
             log<level::ERR>("Configured interface not available",
                             entry("JSON=%s", interface.dump().c_str()),
                             entry("AVAILABLE_INTFS=%s", intfs.c_str()));
@@ -496,8 +498,8 @@
                     std::next(propFuncs->second.begin()),
                     propFuncs->second.end(), propFuncs->second.begin()->first,
                     [](auto list, auto prop) {
-                    return std::move(list) + ", " + prop.first;
-                });
+                        return std::move(list) + ", " + prop.first;
+                    });
                 log<level::ERR>("Configured property not available",
                                 entry("JSON=%s", property.dump().c_str()),
                                 entry("AVAILABLE_PROPS=%s", props.c_str()));
@@ -556,8 +558,8 @@
 {
 // Get a set property handler function for the configured values of the
 // "Supported" property
-std::function<void(DBusZone&, Zone&)> supported(const json& jsonObj,
-                                                bool persist)
+std::function<void(DBusZone&, Zone&)>
+    supported(const json& jsonObj, bool persist)
 {
     std::vector<std::string> values;
     if (!jsonObj.contains("values"))
diff --git a/control/json/zone.hpp b/control/json/zone.hpp
index 21fccbc..bb00416 100644
--- a/control/json/zone.hpp
+++ b/control/json/zone.hpp
@@ -381,8 +381,8 @@
     static auto setProperty(const char* intf, const char* prop,
                             T (DBusZone::*func)(T), T&& value, bool persist)
     {
-        return [=, value = std::forward<T>(value)](DBusZone& dbusZone,
-                                                   Zone& zone) {
+        return [=, value =
+                       std::forward<T>(value)](DBusZone& dbusZone, Zone& zone) {
             (dbusZone.*func)(value);
             if (persist)
             {
@@ -551,8 +551,8 @@
  *
  * @return Zone dbus object's set property function for the "Supported" property
  */
-std::function<void(DBusZone&, Zone&)> supported(const json& jsonObj,
-                                                bool persist);
+std::function<void(DBusZone&, Zone&)>
+    supported(const json& jsonObj, bool persist);
 
 /**
  * @brief "Current" property on the "xyz.openbmc_project.Control.ThermalMode"
@@ -564,8 +564,8 @@
  *
  * @return Zone dbus object's set property function for the "Current" property
  */
-std::function<void(DBusZone&, Zone&)> current(const json& jsonObj,
-                                              bool persist);
+std::function<void(DBusZone&, Zone&)>
+    current(const json& jsonObj, bool persist);
 
 } // namespace zone::property