Remove elog-errors-HostEvent.hpp from phosphor-logging repo
Resolves openbmc/phosphor-logging#4
Change-Id: I15ccdef0dd63216991bbd113e47beb057df14df8
Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
diff --git a/Makefile.am b/Makefile.am
index 29f18d6..1e2106e 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,8 +1,7 @@
# export these headers
nobase_include_HEADERS = \
phosphor-logging/log.hpp \
- phosphor-logging/elog.hpp \
- phosphor-logging/elog-errors-HostEvent.hpp
+ phosphor-logging/elog.hpp
nobase_nodist_include_HEADERS = \
phosphor-logging/elog-errors.hpp \
diff --git a/log_manager.cpp b/log_manager.cpp
index 5c11b92..d587ec4 100644
--- a/log_manager.cpp
+++ b/log_manager.cpp
@@ -8,7 +8,6 @@
#include <sdbusplus/vtable.hpp>
#include <systemd/sd-bus.h>
#include <systemd/sd-journal.h>
-#include <phosphor-logging/elog-errors-HostEvent.hpp>
#include "config.h"
#include "elog_entry.hpp"
#include <phosphor-logging/log.hpp>
@@ -49,16 +48,8 @@
{
metalist.insert(metamap->second.begin(), metamap->second.end());
}
- const auto& metalistHostEvent = g_errMetaMapHostEvent[errMsg];
- std::vector<std::string> additionalData;
- // TODO Remove once host event error header file is auto-generated.
- // Also make metalist a const variable.
- // Tracking with issue openbmc/phosphor-logging#4
- for (auto& metaVarStrHostEvent : metalistHostEvent)
- {
- metalist.insert(metaVarStrHostEvent);
- }
+ std::vector<std::string> additionalData;
// Read the journal from the end to get the most recent entry first.
// The result from the sd_journal_get_data() is of the form VARIABLE=value.
diff --git a/phosphor-logging/elog-errors-HostEvent.hpp b/phosphor-logging/elog-errors-HostEvent.hpp
deleted file mode 100644
index 2bff981..0000000
--- a/phosphor-logging/elog-errors-HostEvent.hpp
+++ /dev/null
@@ -1,76 +0,0 @@
-// This file was autogenerated. Do not edit!
-// See elog-gen.py for more details
-#pragma once
-
-#include <map>
-#include <string>
-#include <tuple>
-#include <type_traits>
-#include <vector>
-#include <sdbusplus/exception.hpp>
-#include <phosphor-logging/log.hpp>
-
-namespace phosphor
-{
-
-namespace logging
-{
-
-std::map<std::string,std::vector<std::string>> g_errMetaMapHostEvent = {
- {"org.open_power.Error.Host.Event.Event",{"ESEL"}},
-};
-
-std::map<std::string,level> g_errLevelMapHostEvent = {
- {"org.open_power.Error.Host.Event.Event",level::ERR},
-};
-
-namespace org
-{
-namespace open_power
-{
-namespace Error
-{
-namespace Host
-{
-namespace _Event
-{
-struct ESEL
-{
- static constexpr auto str = "ESEL=%s";
- static constexpr auto str_short = "ESEL";
- using type = std::tuple<std::decay_t<decltype(str)>,const char*>;
- explicit constexpr ESEL(const char* a) : _entry(entry(str, a)) {};
- type _entry;
-};
-
-} // namespace _Event
-
-struct Event : public sdbusplus::exception_t
-{
- static constexpr auto errName = "org.open_power.Error.Host.Event.Event";
- static constexpr auto errDesc = "A host system event was received";
- static constexpr auto L = level::ERR;
- using ESEL = _Event::ESEL;
- using metadata_types = std::tuple<ESEL>;
- const char* name() const noexcept
- {
- return errName;
- }
-
- const char* description() const noexcept
- {
- return errDesc;
- }
-
- const char* what() const noexcept
- {
- return errName;
- }
-
-};
-} // namespace Host
-} // namespace Error
-} // namespace open_power
-} // namespace org
-} // namespace logging
-} // namespace phosphor