PEL: Don't fix user specified action flags

Previously, the PEL object would never trust the action flags field
specified in the PEL registry and would always set some of the flags in
it itself based on a set of rules.

It turns out there are some cases where what the user needs doesn't
match the rules, so now only fix up the action flags if they weren't
specified in the registry and leave the flags alone if they were.

Most PELs in the registry should be able to leave out the action flags
field and let the PEL code set them.

Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Change-Id: I80263d779c842acac042023c468b7e979ec7158c
diff --git a/extensions/openpower-pels/pel.cpp b/extensions/openpower-pels/pel.cpp
index 2113c0f..64b0f59 100644
--- a/extensions/openpower-pels/pel.cpp
+++ b/extensions/openpower-pels/pel.cpp
@@ -275,11 +275,17 @@
 
 void PEL::checkRulesAndFix()
 {
-    auto [actionFlags, eventType] =
-        pel_rules::check(_uh->actionFlags(), _uh->eventType(), _uh->severity());
+    // Only fix if the action flags are at their default value which
+    // means they weren't specified in the registry.  Otherwise
+    // assume the user knows what they are doing.
+    if (_uh->actionFlags() == actionFlagsDefault)
+    {
+        auto [actionFlags, eventType] =
+            pel_rules::check(0, _uh->eventType(), _uh->severity());
 
-    _uh->setActionFlags(actionFlags);
-    _uh->setEventType(eventType);
+        _uh->setActionFlags(actionFlags);
+        _uh->setEventType(eventType);
+    }
 }
 
 void PEL::printSectionInJSON(const Section& section, std::string& buf,