summaryrefslogtreecommitdiffstats
path: root/extensions/openpower-pels/manager.cpp
diff options
context:
space:
mode:
authorMatt Spinler <spinler@us.ibm.com>2019-07-16 15:58:51 -0500
committerMatt Spinler <spinler@us.ibm.com>2019-08-05 12:49:50 -0500
commitcb6b059eec52ddfe099221de003d7dca86ce1db0 (patch)
tree50d851101376d29413e438cffd226e877428b900 /extensions/openpower-pels/manager.cpp
parentdf13bdb6e1423b25e7b737f4bf431af3d5c08d8b (diff)
downloadphosphor-logging-cb6b059eec52ddfe099221de003d7dca86ce1db0.tar.gz
phosphor-logging-cb6b059eec52ddfe099221de003d7dca86ce1db0.zip
PEL: Add PEL class
This class represents a Platform Event Log. A PEL consists of sections, and this commit just adds support for the only required sections - the Private Header and User Header, by including those specific objects. More will be added in the future. The only constructor provided in this commit is to construct the object from an existing flattened PEL buffer. This is for use in the case when a PEL is received from off the BMC, such as from the host. Future commits will add support for creating PELs from OpenBMC event logs. Since there aren't objects yet for every PEL section, the class cannot make a full flattened PEL without still keeping around the original PEL data it received in the constructor as mentioned above. So for now it will keep that data and just overlay the sections it does support when flattening. In the future, a fully formed PEL will be able to be constructed from just flattening the section objects in the correct order. This commit provides a few public methods of note: * data() - returns a flattened PEL * assignID() - sets a unique ID in the log ID field in the Private Header * setCommitTime() - Sets the commit timestamp in the Private Header to the current time * valid() - Says if the PEL is properly formed Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I2a9d82df9cd096ce77ecca7b2f73b097b8368aa2
Diffstat (limited to 'extensions/openpower-pels/manager.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud