summaryrefslogtreecommitdiff
path: root/meta-openbmc-mods/meta-common/recipes-phosphor/interfaces/bmcweb/0018-bmcweb-Add-BMC-Time-update-log-to-the-registry.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta-openbmc-mods/meta-common/recipes-phosphor/interfaces/bmcweb/0018-bmcweb-Add-BMC-Time-update-log-to-the-registry.patch')
-rw-r--r--meta-openbmc-mods/meta-common/recipes-phosphor/interfaces/bmcweb/0018-bmcweb-Add-BMC-Time-update-log-to-the-registry.patch74
1 files changed, 74 insertions, 0 deletions
diff --git a/meta-openbmc-mods/meta-common/recipes-phosphor/interfaces/bmcweb/0018-bmcweb-Add-BMC-Time-update-log-to-the-registry.patch b/meta-openbmc-mods/meta-common/recipes-phosphor/interfaces/bmcweb/0018-bmcweb-Add-BMC-Time-update-log-to-the-registry.patch
new file mode 100644
index 000000000..ab4f65b8b
--- /dev/null
+++ b/meta-openbmc-mods/meta-common/recipes-phosphor/interfaces/bmcweb/0018-bmcweb-Add-BMC-Time-update-log-to-the-registry.patch
@@ -0,0 +1,74 @@
+From d36121d09db4e044b0d7599eae84ad7dc3240fca Mon Sep 17 00:00:00 2001
+From: mansijos <mansi.joshi@intel.com>
+Date: Wed, 26 May 2021 17:40:04 +0530
+Subject: [PATCH] Add BMC Time update log to the registry
+
+Add message in registry to log an event that indicates BMC time
+is set via NTP, Host or Manually.
+During early stage of system boot if any critical events occur,
+they are getting logged with 1970 timestamp till the time BMC
+time update happens. This is expected behavior, but to call it out
+explicitly it is good to log when BMC time is updated.
+
+Tested:
+Built and validator passes.
+Confirmed that the event is getting logged correctly in Redfish.
+
+Signed-off-by: mansijos <mansi.joshi@intel.com>
+---
+ .../registries/openbmc_message_registry.hpp | 32 ++++++++++++++++++-
+ 1 file changed, 31 insertions(+), 1 deletion(-)
+
+diff --git a/redfish-core/include/registries/openbmc_message_registry.hpp b/redfish-core/include/registries/openbmc_message_registry.hpp
+index bedaf6a..4837d2b 100644
+--- a/redfish-core/include/registries/openbmc_message_registry.hpp
++++ b/redfish-core/include/registries/openbmc_message_registry.hpp
+@@ -29,7 +29,7 @@ const Header header = {
+ "0.3.1",
+ "OpenBMC",
+ };
+-constexpr std::array<MessageEntry, 195> registry = {
++constexpr std::array<MessageEntry, 198> registry = {
+ MessageEntry{
+ "ADDDCCorrectable",
+ {
+@@ -263,6 +263,36 @@ constexpr std::array<MessageEntry, 195> registry = {
+ {},
+ "None.",
+ }},
++ MessageEntry{
++ "BMCTimeUpdatedViaHost",
++ {
++ "Indicates that BMC time has been set via Host.",
++ "BMC time has been set via Host. Date Time is set to %1 from %2.",
++ "OK",
++ 2,
++ {"string", "string"},
++ "None.",
++ }},
++ MessageEntry{
++ "BMCTimeUpdatedManually",
++ {
++ "Indicates that BMC time has been set Manually.",
++ "BMC time has been set Manually. Date Time is set to %1 from %2.",
++ "OK",
++ 2,
++ {"string", "string"},
++ "None.",
++ }},
++ MessageEntry{
++ "BMCTimeUpdatedViaNTP",
++ {
++ "Indicates that BMC time has been set via NTP.",
++ "BMC time has been set via NTP. Date Time is set to %1 from %2.",
++ "OK",
++ 2,
++ {"string", "string"},
++ "None.",
++ }},
+ MessageEntry{"ChassisIntrusionDetected",
+ {
+ "Indicates that a physical security event "
+--
+2.25.1
+