97f7abcf | 06-Nov-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Add license prologue to test source files
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I67c62ab5ac6e69ad0a84937834581f9a280a9167 |
186ce8c9 | 20-Oct-2019 |
Aatir <aatrapps@gmail.com> |
PEL: PELTool Application
PELTooL application would be used to interact with PELs. This commit has the first functionality, where a PEL file is passed and all PEL sections are hexdumped in a JSON obj
PEL: PELTool Application
PELTooL application would be used to interact with PELs. This commit has the first functionality, where a PEL file is passed and all PEL sections are hexdumped in a JSON object.
Signed-off-by: Aatir <aatrapps@gmail.com> Change-Id: I155d75bb58cbd14a297b094314f7fd1f271f4f37
show more ...
|
e07f915b | 01-Nov-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Make action flags optional in the registry
A future commit will fill in the field if it isn't present.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I67371433162ce2198a362796d274
PEL: Make action flags optional in the registry
A future commit will fill in the field if it isn't present.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I67371433162ce2198a362796d274695a1bd6a6dc
show more ...
|
97d19b48 | 29-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Const accessors for Private/UserHeader
Change the combined non-const accessor/setter functions for the PrivateHeader and UserHeader fields to the standard const accessors, and have separate set
PEL: Const accessors for Private/UserHeader
Change the combined non-const accessor/setter functions for the PrivateHeader and UserHeader fields to the standard const accessors, and have separate setters for the fields that need to be modified.
In addition, make the 'get PrivateHeader' and 'get UserHeader' functions on the PEL class return a const reference.
This allows const enforcement on the PEL class, for things like:
void func(const PEL& pel) { auto id = pel.privateHeader().id(); }
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I840170e72b41e9e2465f716617500269244de6d9
show more ...
|
afa857c7 | 24-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Save AdditionalData in a UserData section
Save the contents of the AdditionalData OpenBMC event log property as JSON in a UserData PEL section.
For example, if the AdditionalData property, whi
PEL: Save AdditionalData in a UserData section
Save the contents of the AdditionalData OpenBMC event log property as JSON in a UserData PEL section.
For example, if the AdditionalData property, which is an array of strings, looks like: ["KEY1=VALUE1", "KEY=VALUE2"]
Then the data stored as ASCII text in the UserData section is: {"KEY1":"VALUE1","KEY2":"VALUE2"}
If one of the keys is "ESEL", then that entry is removed from the UserData output as that contains a full raw PEL from the host sent down as ASCII text.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: Ia6ffabb39fdb4315ec2152744414e44f7d2ec4aa
show more ...
|
aa659477 | 23-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Create FailingMTMS section for new PELs
When a PEL is created from an OpenBMC event log, add the FailingMTMS section to the PEL. This contains the machine type, model, and serial number fields.
PEL: Create FailingMTMS section for new PELs
When a PEL is created from an OpenBMC event log, add the FailingMTMS section to the PEL. This contains the machine type, model, and serial number fields.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I8d08e6dda00260efebd2c6ac165270d2aaf98d67
show more ...
|
67456c2b | 21-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Start creating PELs from event logs
Look up incoming OpenBMC event logs in the message registry and create PELs for them if a registry entry is found.
What happens when an event log can't be f
PEL: Start creating PELs from event logs
Look up incoming OpenBMC event logs in the message registry and create PELs for them if a registry entry is found.
What happens when an event log can't be found in the message registry, such as creating a different PEL, will be addressed in a separate commit.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I45c634830021fdf2efb54e3cbfd6d496fd3d7d01
show more ...
|
bd716f00 | 15-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Create SRC section from message registry
This adds the ability to create an SRC PEL section based on the message registry entry for an OpenBMC event log.
The event log's AdditionalData propert
PEL: Create SRC section from message registry
This adds the ability to create an SRC PEL section based on the message registry entry for an OpenBMC event log.
The event log's AdditionalData property is used as a source for the user defined data words of the SRC, while the other fields in the SRC's data words are filled in either from the message registry fields or from current system state or configuration.
The ASCII string field of the SRC is filled in based on the message registry entry.
This commit doesn't fill in every system status field, as many aren't even available anywhere yet. Also, this commit doesn't support adding callouts to an SRC, that will also be handled in the future.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I67fe44e07e4eda6bdeedb4af2eacfc197deb6eb3
show more ...
|
ceac9690 | 11-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Enhance the real PEL test
Check the SRC ASCII string, and also check the full ID of the last section object.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: Ie5b5ef3783d316a31e370e
PEL: Enhance the real PEL test
Check the SRC ASCII string, and also check the full ID of the last section object.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: Ie5b5ef3783d316a31e370ef898e11ecaf16b9551
show more ...
|
213e5c1b | 11-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Add 3 more sections to the test PEL data
Several testcases use pelDataFactory() for their PEL data. Add SRC, FailingMTMS, and UserData sections to this data to get some better coverage.
Signe
PEL: Add 3 more sections to the test PEL data
Several testcases use pelDataFactory() for their PEL data. Add SRC, FailingMTMS, and UserData sections to this data to get some better coverage.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I2b09fc94c32df1a6fd5bd3cb96c98dc7c3bcc1f2
show more ...
|
42828bd9 | 11-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Refactor the test data factory
This commit has no functional changes, it just does some things to make the PEL data creator for testcases, pelDataFactory(), be more manageable:
- Change to ret
PEL: Refactor the test data factory
This commit has no functional changes, it just does some things to make the PEL data creator for testcases, pelDataFactory(), be more manageable:
- Change to return a plain vector instead of a unique_ptr<vector>. - Keeps the data for each section in separate vectors and then either returns those as-is or combines them into a PEL. - Change the TestPelType enum to TestPELType to match the style guide. - Have pelDataFactory provide the SRC section instead of srcDataFactory.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I4770aa6a8169e89b6b8f685a9994d845c9e93cfe
show more ...
|
f9bae185 | 09-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Add SRC PEL section class
This section consists of: - An 8B header - 8 4B words of hex data - Some data is predefined based on the SRC format, some is free format. - A 32B ASCII character str
PEL: Add SRC PEL section class
This section consists of: - An 8B header - 8 4B words of hex data - Some data is predefined based on the SRC format, some is free format. - A 32B ASCII character string (The AsciiString class) - An optional section for FRU callouts (The Callouts class)
Usually, the term SRC (System Reference Code) refers to the contents of the ASCII string and the hex data words, which can then be looked up in service documentation to find the meaning of the event log. This PEL section wraps this pure SRC with additional data like callouts.
This commit only adds support for unflattening the section from an existing PEL, and flattening it again. Future commits will add support for creating an SRC from message registry data.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I3dd97c6aca59cc6d6d6fadef84465164090d5658
show more ...
|
32f13c91 | 09-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: SRC callouts subsection object
This Callouts class represents the optional subsection of an SRC PEL section that contains FRU callouts. It is only present in the SRC when there are callouts, a
PEL: SRC callouts subsection object
This Callouts class represents the optional subsection of an SRC PEL section that contains FRU callouts. It is only present in the SRC when there are callouts, and it comes at the end of the section.
It is basically just a container for the Callout objects that represent the actual callouts.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I1d4d95b82f9b4943728d7939e3bf89e4a7bcbb75
show more ...
|
6c9662c9 | 09-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: SRC FRU callout structure
This class represents a single FRU callout in the SRC section of a PEL. When there are multiple callouts, there will be multiple instances of this class created. Tech
PEL: SRC FRU callout structure
This class represents a single FRU callout in the SRC section of a PEL. When there are multiple callouts, there will be multiple instances of this class created. Technically, the callout isn't always a FRU, such as it could be a maintenance procedure name, but the spec still refers to this section as the FRU callout section.
The callout priority and location code are in this structure.
There can also be up to one each of three types of substructures in a single callout: * FRU Identity (must be first if present) * Power Controlling Enclosure (PCE) * Manufacturing Replaceable Unit (MRU)
This commit just provides support for creating this object from a flattened PEL, such as one that comes down from the host. A future commit will add support for creating a callout for BMC created event logs.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I49535285e3cbaa15dfe031648cfaf262380a1cf7
show more ...
|
90b4a0a0 | 09-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: MRU callout SRC substructure
This substructure is part of the callout subsection in the SRC section of a PEL, and contains information about Manufacturing Replaceable Units (MRUs). MRUs are co
PEL: MRU callout SRC substructure
This substructure is part of the callout subsection in the SRC section of a PEL, and contains information about Manufacturing Replaceable Units (MRUs). MRUs are components on a parent FRU (Field Replaceable Unit) that may be able to be replaced in a manufacturing environment, hence the name.
This substructure includes a list of <priority, MRU ID> pairs, where the priority is the same priority value type as used elsewhere in the SRC section ('H', 'M', 'L', etc), and the MRU ID is a 4B ID that development will tell manufacturing the meanings of.
This commit only adds support for creating an object from a flattened PEL, such as one that comes down from the host. A future commit will handle creating it from scratch for BMC errors.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I6352e1a3cb84db0516902786faca4c387afef411
show more ...
|
5b3a11db | 08-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Power controlling enc SRC substructure
This substructure is part of the callout subsection in the SRC section of a PEL, and contains enclosure information for when another enclosure controls th
PEL: Power controlling enc SRC substructure
This substructure is part of the callout subsection in the SRC section of a PEL, and contains enclosure information for when another enclosure controls the power of the failing entity. This would be an unusual case, when the piece of hardware that is being called out has its power controlled by another enclosure, for example when an I/O expansion drawer is connected to 2 servers, and only one of them controls its power.
This includes: * The enclosure's name * The enclosure's machine type, model, and serial number
The BMC will never create this section for BMC errors, but it may need to unflatten them for PELs sent down from a host that has to deal with I/O drawers.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: Ie04c1ee3fdfa67ee8666c10fa3bc837f4d33a9ef
show more ...
|
4b59f7ad | 08-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Add string accessors to MTMS class
This class is used by a few other classes, so make it easier to get data out of it.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I2feb4b83a09e
PEL: Add string accessors to MTMS class
This class is used by a few other classes, so make it easier to get data out of it.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I2feb4b83a09e6cb6056c9f1a903ca55e8cacf2ae
show more ...
|
a906c940 | 08-Oct-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: FRU identity SRC substructure
This substructure is part of the callout subsection in the SRC section of a PEL, and contains information about the FRU (Field Replaceable Unit) being called out.
PEL: FRU identity SRC substructure
This substructure is part of the callout subsection in the SRC section of a PEL, and contains information about the FRU (Field Replaceable Unit) being called out.
This includes: * The specific type of FRU (see the flags field definitions) * The FRU part number * The FRU CCIN value (CCIN = a keyword in VPD). * The FRU serial number
Instead of just calling out a FRU, this structure can instead be used to call out a maintenance procedure, which is a string that is used as a key into the service documentation that maps to a procedure to fix the problem.
This commit only adds support for creating an object from a flattened PEL, such as one that comes down from the host. A future commit will handle creating it from scratch for BMC errors.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: Ic2b9489abea48084116bf2f450bd293c2d655979
show more ...
|
6852d722 | 30-Sep-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Represent the SRC ASCII string field
In the SRC section of a PEL, there is a field called the 'ASCII string'. This is the string of 32 characters that shows up on the panel when the SRC functio
PEL: Represent the SRC ASCII string field
In the SRC section of a PEL, there is a field called the 'ASCII string'. This is the string of 32 characters that shows up on the panel when the SRC function is chosen, and usually when people refer to an SRC, the first 8 characters of this field is what they are referring to.
This new class handles that string. It will belong to the SRC section object.
For BMC error SRCs, it looks like: BDSSRRRR Where: BD = "BD", indicating a BMC error SRC SS = subsystem value from PEL spec RRRR = reason code of the error
The remaining 24 characters are spaces (' ').
For example: "BD8D1234 "
For BMC power* related errors, the value is:
"11001234 "
Where the difference is the "11" instead of "BD", and the following 2 bytes are always "00".
* 'power' means comes from the repository that monitors for power faults. This is different purely to help keep field service documentation the same as in previous IBM server generations.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I6e7292e7f5b501428999781b1a5ee5c243a63ac6
show more ...
|
51c9263f | 06-Sep-2019 |
Aatir Manzur <aatrapps@gmail.com> |
PEL: User Data class
This class is used for accessing the UserData section of a PEL.
This section contains free format data that can be identified by the component ID, subtype, and version fields i
PEL: User Data class
This class is used for accessing the UserData section of a PEL.
This section contains free format data that can be identified by the component ID, subtype, and version fields in the section header.
Signed-off-by: Aatir Manzur <aatrapps@gmail.com> Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I1223f84353e81202d1ff63c00f3d926cda4994e5
show more ...
|
07eefc54 | 26-Sep-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Flatten PEL from objects
Now that the Generic section object has been introduced so there are objects for every section, a flatten can be done by flattening every object inside the PEL and the
PEL: Flatten PEL from objects
Now that the Generic section object has been introduced so there are objects for every section, a flatten can be done by flattening every object inside the PEL and the previous workaround to save the original raw data can be removed.
This also adds a test case that uses a real PEL from a previous generation of systems to flatten to give some better coverage than just using hand coded PEL sections.
A side affect of this is that the PEL constructors that take the raw data cannot take a const vector of data, as the Stream class that will be used to read from the vector cannot take a const. Testcases have been updated to ensure this data is not modified.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I64ae1d1d4a742c80e14666d6b2a6e1e0efd5fd62
show more ...
|
131870c7 | 25-Sep-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Create object for every section
When unflattening a PEL, create objects for every PEL section in the log. It will use a factory method to choose which object type to create based on the sectio
PEL: Create object for every section
When unflattening a PEL, create objects for every PEL section in the log. It will use a factory method to choose which object type to create based on the section ID in the section header. All of these object will go into a vector of Section objects, which is the base class for every PEL section class.
The factory will default to creating a Generic object when it doesn't have any other type to create.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: Ief0e4df5c586a46cea66ca47b4479e3444815309
show more ...
|
14d671fa | 25-Sep-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Add a Generic section object
This object will be created when unflattening a PEL when there is no other class to use for that section. It just contains a vector<uint8_t> for its data.
This is
PEL: Add a Generic section object
This object will be created when unflattening a PEL when there is no other class to use for that section. It just contains a vector<uint8_t> for its data.
This is done so that the code can always have objects for all PEL sections, which helps in validating (can at least ensure every section has a valid header and size), printing (will always have an object to get its data to at least hex dump), and re-flattening (no need to keep around the original data buffer).
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I2b79feb4abc0f44179bdb8eab950f0d274e4e472
show more ...
|
d377793c | 24-Sep-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Add Stream ops for std::vector<uint8_t>
Add << and >> operators to the Stream class for use with a std::vector<uint8_t>.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I9656ee4e34
PEL: Add Stream ops for std::vector<uint8_t>
Add << and >> operators to the Stream class for use with a std::vector<uint8_t>.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I9656ee4e34840d311148e6a701131b3420e62d25
show more ...
|
b832363d | 20-Sep-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Create PEL from parameters
Add a constructor to the PEL class so it can be built from the message registry entry for that error along with the event log properties.
When support for new sectio
PEL: Create PEL from parameters
Add a constructor to the PEL class so it can be built from the message registry entry for that error along with the event log properties.
When support for new sections are added, they will be created here as well along with the PrivateHeader and UserHeader section classes.
Eventually, this constructor will be called from the Manager class after it is told a new event log has been created and after it looks up that error's PEL message registry entry.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I2d8ca550736aab45a30ac3db9861723b33e6cd32
show more ...
|