Remove redfish-enable-proccessor-memory-status

The redfish-enable-proccessor-memory-status option was scheduled to be
removed in 1Q 2024. It is now 2Q, so remove the option. No upstream
layers enabled it and I could not find a downstream layer that did
either.

Redfish deprecated the Processor/Memory Summary Status (state, health,
healthrollup) attributes.

Discussion on discord, when disabling:
[1]: https://discord.com/channels/775381525260664832/855566794994221117/1093939076710793296

Commit disabling this (merged 10 months ago):
[2]: https://github.com/openbmc/bmcweb/commit/5fd0aafb0f14fb3011970e8575647bb608688c7c

Tested: Code builds.

Change-Id: I539cd5f384633afa7badf1cecfc6c7a87062f672
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
diff --git a/redfish-core/lib/systems.hpp b/redfish-core/lib/systems.hpp
index 87b413b..272a24b 100644
--- a/redfish-core/lib/systems.hpp
+++ b/redfish-core/lib/systems.hpp
@@ -210,26 +210,6 @@
         "xyz.openbmc_project.Inventory.Item", "Present",
         std::move(getCpuPresenceState));
 
-    if constexpr (bmcwebEnableProcMemStatus)
-    {
-        auto getCpuFunctionalState =
-            [asyncResp](const boost::system::error_code& ec3,
-                        const bool cpuFunctionalCheck) {
-            if (ec3)
-            {
-                BMCWEB_LOG_ERROR("DBUS response error {}", ec3);
-                return;
-            }
-            modifyCpuFunctionalState(asyncResp, cpuFunctionalCheck);
-        };
-
-        // Get the Functional State
-        sdbusplus::asio::getProperty<bool>(
-            *crow::connections::systemBus, service, path,
-            "xyz.openbmc_project.State.Decorator.OperationalStatus",
-            "Functional", std::move(getCpuFunctionalState));
-    }
-
     sdbusplus::asio::getAllProperties(
         *crow::connections::systemBus, service, path,
         "xyz.openbmc_project.Inventory.Item.Cpu",
@@ -250,39 +230,18 @@
  * @brief processMemoryProperties fields
  *
  * @param[in] asyncResp Shared pointer for completing asynchronous calls
- * @param[in] service dbus service for memory Information
- * @param[in] path dbus path for Memory
  * @param[in] DBUS properties for memory
  *
  * @return None.
  */
 inline void
     processMemoryProperties(const std::shared_ptr<bmcweb::AsyncResp>& asyncResp,
-                            [[maybe_unused]] const std::string& service,
-                            [[maybe_unused]] const std::string& path,
                             const dbus::utility::DBusPropertiesMap& properties)
 {
     BMCWEB_LOG_DEBUG("Got {} Dimm properties.", properties.size());
 
     if (properties.empty())
     {
-        if constexpr (bmcwebEnableProcMemStatus)
-        {
-            sdbusplus::asio::getProperty<bool>(
-                *crow::connections::systemBus, service, path,
-                "xyz.openbmc_project.State."
-                "Decorator.OperationalStatus",
-                "Functional",
-                [asyncResp](const boost::system::error_code& ec3,
-                            bool dimmState) {
-                if (ec3)
-                {
-                    BMCWEB_LOG_ERROR("DBUS response error {}", ec3);
-                    return;
-                }
-                updateDimmProperties(asyncResp, dimmState);
-            });
-        }
         return;
     }
 
@@ -314,11 +273,6 @@
                 static_cast<double>(*memorySizeInKB) / (1024 * 1024) +
                 *preValue;
         }
-        if constexpr (bmcwebEnableProcMemStatus)
-        {
-            asyncResp->res.jsonValue["MemorySummary"]["Status"]["State"] =
-                "Enabled";
-        }
     }
 }
 
@@ -347,7 +301,7 @@
             messages::internalError(asyncResp->res);
             return;
         }
-        processMemoryProperties(asyncResp, service, path, properties);
+        processMemoryProperties(asyncResp, properties);
     });
 }
 
@@ -466,7 +420,6 @@
 
 inline void afterSystemGetSubTree(
     const std::shared_ptr<bmcweb::AsyncResp>& asyncResp,
-    const std::shared_ptr<HealthPopulate>& systemHealth,
     const boost::system::error_code& ec,
     const dbus::utility::MapperGetSubTreeResponse& subtree)
 {
@@ -491,24 +444,6 @@
             continue;
         }
 
-        std::shared_ptr<HealthPopulate> memoryHealth = nullptr;
-        std::shared_ptr<HealthPopulate> cpuHealth = nullptr;
-
-        if constexpr (bmcwebEnableProcMemStatus)
-        {
-            memoryHealth = std::make_shared<HealthPopulate>(
-                asyncResp, "/MemorySummary/Status"_json_pointer);
-            systemHealth->children.emplace_back(memoryHealth);
-
-            if constexpr (bmcwebEnableHealthPopulate)
-            {
-                cpuHealth = std::make_shared<HealthPopulate>(
-                    asyncResp, "/ProcessorSummary/Status"_json_pointer);
-
-                systemHealth->children.emplace_back(cpuHealth);
-            }
-        }
-
         // This is not system, so check if it's cpu, dimm, UUID or
         // BiosVer
         for (const auto& connection : connectionNames)
@@ -520,11 +455,6 @@
                     BMCWEB_LOG_DEBUG("Found Dimm, now get its properties.");
 
                     getMemorySummary(asyncResp, connection.first, path);
-
-                    if constexpr (bmcwebEnableProcMemStatus)
-                    {
-                        memoryHealth->inventory.emplace_back(path);
-                    }
                 }
                 else if (interfaceName ==
                          "xyz.openbmc_project.Inventory.Item.Cpu")
@@ -532,11 +462,6 @@
                     BMCWEB_LOG_DEBUG("Found Cpu, now get its properties.");
 
                     getProcessorSummary(asyncResp, connection.first, path);
-
-                    if constexpr (bmcwebEnableProcMemStatus)
-                    {
-                        cpuHealth->inventory.emplace_back(path);
-                    }
                 }
                 else if (interfaceName == "xyz.openbmc_project.Common.UUID")
                 {
@@ -579,13 +504,11 @@
  * @brief Retrieves computer system properties over dbus
  *
  * @param[in] asyncResp Shared pointer for completing asynchronous calls
- * @param[in] systemHealth  Shared HealthPopulate pointer
  *
  * @return None.
  */
 inline void
-    getComputerSystem(const std::shared_ptr<bmcweb::AsyncResp>& asyncResp,
-                      const std::shared_ptr<HealthPopulate>& systemHealth)
+    getComputerSystem(const std::shared_ptr<bmcweb::AsyncResp>& asyncResp)
 {
     BMCWEB_LOG_DEBUG("Get available system components.");
     constexpr std::array<std::string_view, 5> interfaces = {
@@ -597,7 +520,7 @@
     };
     dbus::utility::getSubTree(
         "/xyz/openbmc_project/inventory", 0, interfaces,
-        std::bind_front(afterSystemGetSubTree, asyncResp, systemHealth));
+        std::bind_front(afterSystemGetSubTree, asyncResp));
 }
 
 /**
@@ -3253,13 +3176,6 @@
     asyncResp->res.jsonValue["SystemType"] = "Physical";
     asyncResp->res.jsonValue["Description"] = "Computer System";
     asyncResp->res.jsonValue["ProcessorSummary"]["Count"] = 0;
-    if constexpr (bmcwebEnableProcMemStatus)
-    {
-        asyncResp->res.jsonValue["ProcessorSummary"]["Status"]["State"] =
-            "Disabled";
-        asyncResp->res.jsonValue["MemorySummary"]["Status"]["State"] =
-            "Disabled";
-    }
     asyncResp->res.jsonValue["MemorySummary"]["TotalSystemMemoryGiB"] =
         double(0);
     asyncResp->res.jsonValue["@odata.id"] = "/redfish/v1/Systems/system";
@@ -3348,7 +3264,7 @@
     getSystemLocationIndicatorActive(asyncResp);
     // TODO (Gunnar): Remove IndicatorLED after enough time has passed
     getIndicatorLedState(asyncResp);
-    getComputerSystem(asyncResp, health);
+    getComputerSystem(asyncResp);
     getHostState(asyncResp);
     getBootProperties(asyncResp);
     getBootProgress(asyncResp);