regenerate elog-errors.hpp

Regenerate elog-errors.hpp with the minimal set of YAML.

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: Ic8b9ddeaf04bb766b533b806f412afdea35bfa39
diff --git a/elog-errors.hpp b/elog-errors.hpp
index 3dfb09a..ab3cadc 100644
--- a/elog-errors.hpp
+++ b/elog-errors.hpp
@@ -10,197 +10,95 @@
 #include <tuple>
 #include <type_traits>
 
-namespace sdbusplus
-{
-namespace xyz
-{
-namespace openbmc_project
-{
-namespace Common
-{
-namespace Callout
-{
-namespace Error
-{
-struct GPIO;
-} // namespace Error
-} // namespace Callout
-} // namespace Common
-} // namespace openbmc_project
-} // namespace xyz
-} // namespace sdbusplus
-
-namespace sdbusplus
-{
-namespace org
-{
-namespace open_power
-{
-namespace Common
-{
-namespace Callout
-{
-namespace Error
+namespace sdbusplus::error::org::open_power::common::callout
 {
 struct Procedure;
-} // namespace Error
-} // namespace Callout
-} // namespace Common
-} // namespace open_power
-} // namespace org
-} // namespace sdbusplus
-
-namespace sdbusplus
-{
-namespace xyz
-{
-namespace openbmc_project
-{
-namespace Common
-{
-namespace Callout
-{
-namespace Error
-{
-struct Inventory;
-} // namespace Error
-} // namespace Callout
-} // namespace Common
-} // namespace openbmc_project
-} // namespace xyz
-} // namespace sdbusplus
-
-namespace sdbusplus
-{
-namespace xyz
-{
-namespace openbmc_project
-{
-namespace Common
-{
-namespace Callout
-{
-namespace Error
-{
-struct IIC;
-} // namespace Error
-} // namespace Callout
-} // namespace Common
-} // namespace openbmc_project
-} // namespace xyz
-} // namespace sdbusplus
-
-namespace sdbusplus
-{
-namespace org
-{
-namespace open_power
-{
-namespace OCC
-{
-namespace Metrics
-{
-namespace Error
+} // namespace sdbusplus::error::org::open_power::common::callout
+namespace sdbusplus::error::org::open_power::host
 {
 struct Event;
-} // namespace Error
-} // namespace Metrics
-} // namespace OCC
-} // namespace open_power
-} // namespace org
-} // namespace sdbusplus
-
-namespace sdbusplus
-{
-namespace xyz
-{
-namespace openbmc_project
-{
-namespace Common
-{
-namespace Callout
-{
-namespace Error
-{
-struct Device;
-} // namespace Error
-} // namespace Callout
-} // namespace Common
-} // namespace openbmc_project
-} // namespace xyz
-} // namespace sdbusplus
-
-namespace sdbusplus
-{
-namespace org
-{
-namespace open_power
-{
-namespace Host
-{
-namespace Error
+} // namespace sdbusplus::error::org::open_power::host
+namespace sdbusplus::error::org::open_power::host
 {
 struct MaintenanceProcedure;
-} // namespace Error
-} // namespace Host
-} // namespace open_power
-} // namespace org
-} // namespace sdbusplus
-
-namespace sdbusplus
-{
-namespace org
-{
-namespace open_power
-{
-namespace Host
-{
-namespace Error
+} // namespace sdbusplus::error::org::open_power::host
+namespace sdbusplus::error::org::open_power::occ::metrics
 {
 struct Event;
-} // namespace Error
-} // namespace Host
-} // namespace open_power
-} // namespace org
-} // namespace sdbusplus
-
-namespace sdbusplus
+} // namespace sdbusplus::error::org::open_power::occ::metrics
+namespace sdbusplus::error::xyz::openbmc_project::common::callout
 {
-namespace xyz
+struct Device;
+} // namespace sdbusplus::error::xyz::openbmc_project::common::callout
+namespace sdbusplus::error::xyz::openbmc_project::common::callout
 {
-namespace openbmc_project
+struct GPIO;
+} // namespace sdbusplus::error::xyz::openbmc_project::common::callout
+namespace sdbusplus::error::xyz::openbmc_project::common::callout
 {
-namespace Common
-{
-namespace Callout
-{
-namespace Error
+struct IIC;
+} // namespace sdbusplus::error::xyz::openbmc_project::common::callout
+namespace sdbusplus::error::xyz::openbmc_project::common::callout
 {
 struct IPMISensor;
-} // namespace Error
-} // namespace Callout
-} // namespace Common
-} // namespace openbmc_project
-} // namespace xyz
-} // namespace sdbusplus
+} // namespace sdbusplus::error::xyz::openbmc_project::common::callout
+namespace sdbusplus::error::xyz::openbmc_project::common::callout
+{
+struct Inventory;
+} // namespace sdbusplus::error::xyz::openbmc_project::common::callout
 
-namespace phosphor
+namespace phosphor::logging
 {
 
-namespace logging
+namespace org::open_power::occ::metrics
+{
+namespace _Event
+{
+struct ESEL
+{
+    /*
+     * We can't use -fsanitize=undefined if we declare a
+     * 'static constexpr auto str' member, so don't. Instead, open-code the
+     * mako template lookups.
+     */
+    static constexpr auto str_short = "ESEL";
+    using type = std::tuple<std::decay_t<decltype("ESEL=%s")>, const char*>;
+    explicit constexpr ESEL(const char* a) : _entry(entry("ESEL=%s", a)){};
+    type _entry;
+};
+} // namespace _Event
+
+struct Event
+{
+    static constexpr auto L = level::INFO;
+    using ESEL = _Event::ESEL;
+    using metadata_types = std::tuple<ESEL>;
+};
+
+} // namespace org::open_power::occ::metrics
+
+#ifndef SDBUSPP_REMOVE_DEPRECATED_NAMESPACE
+namespace org::open_power::OCC::Metrics
+{
+using Event = phosphor::logging::org::open_power::occ::metrics::Event;
+}
+#endif
+
+namespace details
 {
 
-namespace org
+template <>
+struct map_exception_type<
+    sdbusplus::error::org::open_power::occ::metrics::Event>
 {
-namespace open_power
-{
-namespace Common
-{
-namespace Callout
+    using type = phosphor::logging::org::open_power::occ::metrics::Event;
+};
+
+} // namespace details
+namespace org::open_power::common::callout
 {
 namespace _Procedure
 {
-
 struct PROCEDURE
 {
     /*
@@ -214,7 +112,6 @@
         _entry(entry("PROCEDURE=%u", a)){};
     type _entry;
 };
-
 } // namespace _Procedure
 
 struct Procedure
@@ -224,84 +121,31 @@
     using metadata_types = std::tuple<PROCEDURE>;
 };
 
-} // namespace Callout
-} // namespace Common
-} // namespace open_power
-} // namespace org
+} // namespace org::open_power::common::callout
+
+#ifndef SDBUSPP_REMOVE_DEPRECATED_NAMESPACE
+namespace org::open_power::Common::Callout
+{
+using Procedure =
+    phosphor::logging::org::open_power::common::callout::Procedure;
+}
+#endif
 
 namespace details
 {
 
 template <>
 struct map_exception_type<
-    sdbusplus::org::open_power::Common::Callout::Error::Procedure>
+    sdbusplus::error::org::open_power::common::callout::Procedure>
 {
-    using type = org::open_power::Common::Callout::Procedure;
+    using type = phosphor::logging::org::open_power::common::callout::Procedure;
 };
 
 } // namespace details
-
-namespace org
-{
-namespace open_power
-{
-namespace OCC
-{
-namespace Metrics
-{
-namespace _Event
-{
-
-struct ESEL
-{
-    /*
-     * We can't use -fsanitize=undefined if we declare a
-     * 'static constexpr auto str' member, so don't. Instead, open-code the
-     * mako template lookups.
-     */
-    static constexpr auto str_short = "ESEL";
-    using type = std::tuple<std::decay_t<decltype("ESEL=%s")>, const char*>;
-    explicit constexpr ESEL(const char* a) : _entry(entry("ESEL=%s", a)){};
-    type _entry;
-};
-
-} // namespace _Event
-
-struct Event
-{
-    static constexpr auto L = level::INFO;
-    using ESEL = _Event::ESEL;
-    using metadata_types = std::tuple<ESEL>;
-};
-
-} // namespace Metrics
-} // namespace OCC
-} // namespace open_power
-} // namespace org
-
-namespace details
-{
-
-template <>
-struct map_exception_type<
-    sdbusplus::org::open_power::OCC::Metrics::Error::Event>
-{
-    using type = org::open_power::OCC::Metrics::Event;
-};
-
-} // namespace details
-
-namespace xyz
-{
-namespace openbmc_project
-{
-namespace Common
-{
-namespace Callout
+namespace xyz::openbmc_project::common::callout
 {
 namespace _Device
 {
-
 struct CALLOUT_ERRNO
 {
     /*
@@ -330,7 +174,6 @@
         _entry(entry("CALLOUT_DEVICE_PATH=%s", a)){};
     type _entry;
 };
-
 } // namespace _Device
 
 struct Device
@@ -341,34 +184,31 @@
     using metadata_types = std::tuple<CALLOUT_ERRNO, CALLOUT_DEVICE_PATH>;
 };
 
-} // namespace Callout
-} // namespace Common
-} // namespace openbmc_project
-} // namespace xyz
+} // namespace xyz::openbmc_project::common::callout
+
+#ifndef SDBUSPP_REMOVE_DEPRECATED_NAMESPACE
+namespace xyz::openbmc_project::Common::Callout
+{
+using Device = phosphor::logging::xyz::openbmc_project::common::callout::Device;
+}
+#endif
 
 namespace details
 {
 
 template <>
 struct map_exception_type<
-    sdbusplus::xyz::openbmc_project::Common::Callout::Error::Device>
+    sdbusplus::error::xyz::openbmc_project::common::callout::Device>
 {
-    using type = xyz::openbmc_project::Common::Callout::Device;
+    using type =
+        phosphor::logging::xyz::openbmc_project::common::callout::Device;
 };
 
 } // namespace details
-
-namespace xyz
-{
-namespace openbmc_project
-{
-namespace Common
-{
-namespace Callout
+namespace xyz::openbmc_project::common::callout
 {
 namespace _GPIO
 {
-
 struct CALLOUT_GPIO_NUM
 {
     /*
@@ -383,49 +223,44 @@
         _entry(entry("CALLOUT_GPIO_NUM=%u", a)){};
     type _entry;
 };
-
 } // namespace _GPIO
 
 struct GPIO
 {
     static constexpr auto L = level::ERR;
     using CALLOUT_GPIO_NUM = _GPIO::CALLOUT_GPIO_NUM;
-    using CALLOUT_ERRNO =
-        xyz::openbmc_project::Common::Callout::Device::CALLOUT_ERRNO;
-    using CALLOUT_DEVICE_PATH =
-        xyz::openbmc_project::Common::Callout::Device::CALLOUT_DEVICE_PATH;
+    using CALLOUT_ERRNO = phosphor::logging::xyz::openbmc_project::common::
+        callout::Device::CALLOUT_ERRNO;
+    using CALLOUT_DEVICE_PATH = phosphor::logging::xyz::openbmc_project::
+        common::callout::Device::CALLOUT_DEVICE_PATH;
     using metadata_types =
         std::tuple<CALLOUT_GPIO_NUM, CALLOUT_ERRNO, CALLOUT_DEVICE_PATH>;
 };
 
-} // namespace Callout
-} // namespace Common
-} // namespace openbmc_project
-} // namespace xyz
+} // namespace xyz::openbmc_project::common::callout
+
+#ifndef SDBUSPP_REMOVE_DEPRECATED_NAMESPACE
+namespace xyz::openbmc_project::Common::Callout
+{
+using GPIO = phosphor::logging::xyz::openbmc_project::common::callout::GPIO;
+}
+#endif
 
 namespace details
 {
 
 template <>
 struct map_exception_type<
-    sdbusplus::xyz::openbmc_project::Common::Callout::Error::GPIO>
+    sdbusplus::error::xyz::openbmc_project::common::callout::GPIO>
 {
-    using type = xyz::openbmc_project::Common::Callout::GPIO;
+    using type = phosphor::logging::xyz::openbmc_project::common::callout::GPIO;
 };
 
 } // namespace details
-
-namespace xyz
-{
-namespace openbmc_project
-{
-namespace Common
-{
-namespace Callout
+namespace xyz::openbmc_project::common::callout
 {
 namespace _IIC
 {
-
 struct CALLOUT_IIC_BUS
 {
     /*
@@ -454,7 +289,6 @@
         _entry(entry("CALLOUT_IIC_ADDR=0x%hx", a)){};
     type _entry;
 };
-
 } // namespace _IIC
 
 struct IIC
@@ -462,42 +296,38 @@
     static constexpr auto L = level::ERR;
     using CALLOUT_IIC_BUS = _IIC::CALLOUT_IIC_BUS;
     using CALLOUT_IIC_ADDR = _IIC::CALLOUT_IIC_ADDR;
-    using CALLOUT_ERRNO =
-        xyz::openbmc_project::Common::Callout::Device::CALLOUT_ERRNO;
-    using CALLOUT_DEVICE_PATH =
-        xyz::openbmc_project::Common::Callout::Device::CALLOUT_DEVICE_PATH;
+    using CALLOUT_ERRNO = phosphor::logging::xyz::openbmc_project::common::
+        callout::Device::CALLOUT_ERRNO;
+    using CALLOUT_DEVICE_PATH = phosphor::logging::xyz::openbmc_project::
+        common::callout::Device::CALLOUT_DEVICE_PATH;
     using metadata_types = std::tuple<CALLOUT_IIC_BUS, CALLOUT_IIC_ADDR,
                                       CALLOUT_ERRNO, CALLOUT_DEVICE_PATH>;
 };
 
-} // namespace Callout
-} // namespace Common
-} // namespace openbmc_project
-} // namespace xyz
+} // namespace xyz::openbmc_project::common::callout
+
+#ifndef SDBUSPP_REMOVE_DEPRECATED_NAMESPACE
+namespace xyz::openbmc_project::Common::Callout
+{
+using IIC = phosphor::logging::xyz::openbmc_project::common::callout::IIC;
+}
+#endif
 
 namespace details
 {
 
 template <>
 struct map_exception_type<
-    sdbusplus::xyz::openbmc_project::Common::Callout::Error::IIC>
+    sdbusplus::error::xyz::openbmc_project::common::callout::IIC>
 {
-    using type = xyz::openbmc_project::Common::Callout::IIC;
+    using type = phosphor::logging::xyz::openbmc_project::common::callout::IIC;
 };
 
 } // namespace details
-
-namespace xyz
-{
-namespace openbmc_project
-{
-namespace Common
-{
-namespace Callout
+namespace xyz::openbmc_project::common::callout
 {
 namespace _Inventory
 {
-
 struct CALLOUT_INVENTORY_PATH
 {
     /*
@@ -512,7 +342,6 @@
         _entry(entry("CALLOUT_INVENTORY_PATH=%s", a)){};
     type _entry;
 };
-
 } // namespace _Inventory
 
 struct Inventory
@@ -522,34 +351,32 @@
     using metadata_types = std::tuple<CALLOUT_INVENTORY_PATH>;
 };
 
-} // namespace Callout
-} // namespace Common
-} // namespace openbmc_project
-} // namespace xyz
+} // namespace xyz::openbmc_project::common::callout
+
+#ifndef SDBUSPP_REMOVE_DEPRECATED_NAMESPACE
+namespace xyz::openbmc_project::Common::Callout
+{
+using Inventory =
+    phosphor::logging::xyz::openbmc_project::common::callout::Inventory;
+}
+#endif
 
 namespace details
 {
 
 template <>
 struct map_exception_type<
-    sdbusplus::xyz::openbmc_project::Common::Callout::Error::Inventory>
+    sdbusplus::error::xyz::openbmc_project::common::callout::Inventory>
 {
-    using type = xyz::openbmc_project::Common::Callout::Inventory;
+    using type =
+        phosphor::logging::xyz::openbmc_project::common::callout::Inventory;
 };
 
 } // namespace details
-
-namespace xyz
-{
-namespace openbmc_project
-{
-namespace Common
-{
-namespace Callout
+namespace xyz::openbmc_project::common::callout
 {
 namespace _IPMISensor
 {
-
 struct CALLOUT_IPMI_SENSOR_NUM
 {
     /*
@@ -565,7 +392,6 @@
         _entry(entry("CALLOUT_IPMI_SENSOR_NUM=%u", a)){};
     type _entry;
 };
-
 } // namespace _IPMISensor
 
 struct IPMISensor
@@ -575,32 +401,32 @@
     using metadata_types = std::tuple<CALLOUT_IPMI_SENSOR_NUM>;
 };
 
-} // namespace Callout
-} // namespace Common
-} // namespace openbmc_project
-} // namespace xyz
+} // namespace xyz::openbmc_project::common::callout
+
+#ifndef SDBUSPP_REMOVE_DEPRECATED_NAMESPACE
+namespace xyz::openbmc_project::Common::Callout
+{
+using IPMISensor =
+    phosphor::logging::xyz::openbmc_project::common::callout::IPMISensor;
+}
+#endif
 
 namespace details
 {
 
 template <>
 struct map_exception_type<
-    sdbusplus::xyz::openbmc_project::Common::Callout::Error::IPMISensor>
+    sdbusplus::error::xyz::openbmc_project::common::callout::IPMISensor>
 {
-    using type = xyz::openbmc_project::Common::Callout::IPMISensor;
+    using type =
+        phosphor::logging::xyz::openbmc_project::common::callout::IPMISensor;
 };
 
 } // namespace details
-
-namespace org
-{
-namespace open_power
-{
-namespace Host
+namespace org::open_power::host
 {
 namespace _Event
 {
-
 struct ESEL
 {
     /*
@@ -613,42 +439,40 @@
     explicit constexpr ESEL(const char* a) : _entry(entry("ESEL=%s", a)){};
     type _entry;
 };
-
 } // namespace _Event
 
 struct Event
 {
     static constexpr auto L = level::ERR;
     using ESEL = _Event::ESEL;
-    using CALLOUT_INVENTORY_PATH = xyz::openbmc_project::Common::Callout::
-        Inventory::CALLOUT_INVENTORY_PATH;
+    using CALLOUT_INVENTORY_PATH = phosphor::logging::xyz::openbmc_project::
+        common::callout::Inventory::CALLOUT_INVENTORY_PATH;
     using metadata_types = std::tuple<ESEL, CALLOUT_INVENTORY_PATH>;
 };
 
-} // namespace Host
-} // namespace open_power
-} // namespace org
+} // namespace org::open_power::host
+
+#ifndef SDBUSPP_REMOVE_DEPRECATED_NAMESPACE
+namespace org::open_power::Host
+{
+using Event = phosphor::logging::org::open_power::host::Event;
+}
+#endif
 
 namespace details
 {
 
 template <>
-struct map_exception_type<sdbusplus::org::open_power::Host::Error::Event>
+struct map_exception_type<sdbusplus::error::org::open_power::host::Event>
 {
-    using type = org::open_power::Host::Event;
+    using type = phosphor::logging::org::open_power::host::Event;
 };
 
 } // namespace details
-
-namespace org
-{
-namespace open_power
-{
-namespace Host
+namespace org::open_power::host
 {
 namespace _MaintenanceProcedure
 {
-
 struct ESEL
 {
     /*
@@ -661,33 +485,36 @@
     explicit constexpr ESEL(const char* a) : _entry(entry("ESEL=%s", a)){};
     type _entry;
 };
-
 } // namespace _MaintenanceProcedure
 
 struct MaintenanceProcedure
 {
     static constexpr auto L = level::ERR;
     using ESEL = _MaintenanceProcedure::ESEL;
-    using PROCEDURE = org::open_power::Common::Callout::Procedure::PROCEDURE;
+    using PROCEDURE = phosphor::logging::org::open_power::common::callout::
+        Procedure::PROCEDURE;
     using metadata_types = std::tuple<ESEL, PROCEDURE>;
 };
 
-} // namespace Host
-} // namespace open_power
-} // namespace org
+} // namespace org::open_power::host
+
+#ifndef SDBUSPP_REMOVE_DEPRECATED_NAMESPACE
+namespace org::open_power::Host
+{
+using MaintenanceProcedure =
+    phosphor::logging::org::open_power::host::MaintenanceProcedure;
+}
+#endif
 
 namespace details
 {
 
 template <>
 struct map_exception_type<
-    sdbusplus::org::open_power::Host::Error::MaintenanceProcedure>
+    sdbusplus::error::org::open_power::host::MaintenanceProcedure>
 {
-    using type = org::open_power::Host::MaintenanceProcedure;
+    using type = phosphor::logging::org::open_power::host::MaintenanceProcedure;
 };
 
 } // namespace details
-
-} // namespace logging
-
-} // namespace phosphor
+} // namespace phosphor::logging