#
b832aa5e |
| 21-Mar-2023 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Print component names in peltool
Every PEL section has a 2 byte component ID field in its header that peltool prints. Currently, it just prints the hex version, like "0x1000".
There are JSON
PEL: Print component names in peltool
Every PEL section has a 2 byte component ID field in its header that peltool prints. Currently, it just prints the hex version, like "0x1000".
There are JSON files in the flash already that contain mappings of component IDs to to component names, and this commit starts looking up the component names from those files and using those in the peltool output.
An example of a file is: /usr/share/phosphor-logging/pels/O_component_ids.json: { "1000": "bmc common function", "2000": "bmc error logging", ... }
Where the 'O' in the filename is the creator ID field of the PEL. There is also a file for hostboot, which is B_component_ids.json.
Also, for PELs with a PHYP creator ID, just convert the ID to two characters, like 0x4552 - > "ER" as that is what they are.
peltool output examples: "Created by": "bmc error logging", "Created by": "hostboot: errl", "Created by": "IO",
This matches what is already done by the python peltool.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: Id616739e1b7ca67c85dc7efa85dc34acf6aca9b5
show more ...
|
#
d26fa3e7 |
| 21-Apr-2021 |
Patrick Williams <patrick@stwcx.xyz> |
openpower-pels: clean up various compile warnings
Compile warnings observed when compiling parts of the openpower-pels (or corresponding tests) under stricter compiler warning flags of Meson.
Issue
openpower-pels: clean up various compile warnings
Compile warnings observed when compiling parts of the openpower-pels (or corresponding tests) under stricter compiler warning flags of Meson.
Issues fixed: - many unused parameters - invalid case fall-through - excess semi-colons - incorrect 'const' on return-by-value type - removal of variable length array in test case - uncaught return from 'system' call in test case
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: I8af69184042cf8661d1307a02ecf3afcab4724a1
show more ...
|
#
c8d6cc61 |
| 19-Aug-2020 |
Harisuddin Mohamed Isa <harisuddin@gmail.com> |
PEL: SRC Details Python parser support
This change enables the calling of python3 parsers for SRC details. Modules will be searched under the namespace "srcparsers" from python3 sys.path directories
PEL: SRC Details Python parser support
This change enables the calling of python3 parsers for SRC details. Modules will be searched under the namespace "srcparsers" from python3 sys.path directories (including the current directory).
Example:
/usr/lib/python3.8/site-packages/srcparsers/bsrc/bsrc.py
or
./srcparsers/bsrc/bsrc.py
where
b = Creator Subsystem ID for Hostboot in ASCII lowercase
The parsers will need to provide a function called "parseSRCToJson" with input parameters:
1. (str) ASCII string (Hex Word 1) 2. (str) Hex Word 2 3. (str) Hex Word 3 4. (str) Hex Word 4 5. (str) Hex Word 5 6. (str) Hex Word 6 7. (str) Hex Word 7 8. (str) Hex Word 8 9. (str) Hex Word 9
The return value must be a valid JSON string.
Signed-off-by: Harisuddin Mohamed Isa <harisuddin@gmail.com> Change-Id: I2cb0248e5ee2803869eab28d3232b414e2d743af
show more ...
|
#
3fdcd4e8 |
| 25-Aug-2020 |
Harisuddin Mohamed Isa <harisuddin@gmail.com> |
PEL: Fixed Userdata section parsing
A previous commit incorrectly tries to call python parsers when they do not exist. This fixes it.
Signed-off-by: Harisuddin Mohamed Isa <harisuddin@gmail.com> Ch
PEL: Fixed Userdata section parsing
A previous commit incorrectly tries to call python parsers when they do not exist. This fixes it.
Signed-off-by: Harisuddin Mohamed Isa <harisuddin@gmail.com> Change-Id: I6e65bc89e60b9ac31077009921d4376ddc8254bf
show more ...
|
#
f67bafd0 |
| 06-Jul-2020 |
Harisuddin Mohamed Isa <harisuddin@gmail.com> |
PEL: Python3 module support for UserData parsing
This change enables the calling of python3 parsers for UserData section. Modules will be searched under the namespace "udparsers" from python3 sys.pa
PEL: Python3 module support for UserData parsing
This change enables the calling of python3 parsers for UserData section. Modules will be searched under the namespace "udparsers" from python3 sys.path directories (including the current directory).
Example:
/usr/lib/python3.8/site-packages/udparsers/bxxxx/bxxxx.py
or
./udparsers/bxxxx/bxxxx.py
where
b = Creator Subsystem ID for Hostboot xxxx = Component ID of UserData section
The parsers will need to provide a function called "parseUDToJson" with input parameters:
1. (int) Sub-section type 2. (int) Section version 3. (memoryview): Data
The return value needs to be a valid JSON string.
Signed-off-by: Harisuddin Mohamed Isa <harisuddin@gmail.com> Change-Id: I4d3523083bc48ad0c329c525d83c4a61d36ff611
show more ...
|
#
85f61a63 |
| 03-Jun-2020 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Let SRC class create a debug section
Add functionality so that when the SRC PEL section is being created, it can save debug data (a vector of strings) along the way, and the PEL class will then
PEL: Let SRC class create a debug section
Add functionality so that when the SRC PEL section is being created, it can save debug data (a vector of strings) along the way, and the PEL class will then add that data into a JSON UserData section with any other debug data. The PEL class will then also write the debug data to the journal.
This will be used for things like failure messages when looking up callouts, additional information for device callouts, etc.
The functionality to save debug data is in the Section base class, so in the future other Section classes can also save debug data for display in the PEL.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I2f7923303e953c100c94ac81ba7c85152080fb72
show more ...
|
#
cbf3c4d4 |
| 24-Mar-2020 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Allow shrinking of a UserData section
Add a shrink() function to the UserData class (with a virtual version of it in the Section base class) that will shrink the class to a new size.
This is d
PEL: Allow shrinking of a UserData section
Add a shrink() function to the UserData class (with a virtual version of it in the Section base class) that will shrink the class to a new size.
This is done so that when UserData sections are added to PELs the sections can be shrunk if necessary to keep the PEL under the maximum size, which is 16KB.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: Iade52dee8a110f7805c40aa50d6e5df45db050bf
show more ...
|
#
a214ed30 |
| 28-Feb-2020 |
Harisuddin Mohamed Isa <harisuddin@gmail.com> |
PEL: peltool: Print all PELs into JSON array
Added -a option to display all PELS at once into a JSON array.
Read message registry once to parse SRC sections in PELs.
Signed-off-by: Harisuddin Moha
PEL: peltool: Print all PELs into JSON array
Added -a option to display all PELS at once into a JSON array.
Read message registry once to parse SRC sections in PELs.
Signed-off-by: Harisuddin Mohamed Isa <harisuddin@gmail.com> Change-Id: I19690a866a3348cf2d8a9a89be38bc09e3eb7f9f
show more ...
|
#
ad0e0476 |
| 07-Oct-2019 |
Aatir Manzur <aatrapps@gmail.com> |
PEL: user header in JSON
The PELTool application is able to convert sections to JSON. This commit takes care of converting the user header section to JSON.
user header section in JSON sample:
"Use
PEL: user header in JSON
The PELTool application is able to convert sections to JSON. This commit takes care of converting the user header section to JSON.
user header section in JSON sample:
"User Header":[ {"Section Version": "1"}, {"Sub-section type": "0"}, {"Log Committed by": "0x2000"}, {"Subsystem": "bmc_firmware"}, {"Event Scope": "entire_platform"}, {"Event Severity":"unrecoverable"}, {"Event Type": "na"} ]
Signed-off-by: Aatir Manzur <aatrapps@gmail.com> Change-Id: I0dca1d87019b9e62d711ee6d034f2e8bc0574c2e
show more ...
|
#
0688545b |
| 06-Nov-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Make PEL::flatten() const
This includes making the flatten() method const in the PEL section base class and in all of its derived classes.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Chan
PEL: Make PEL::flatten() const
This includes making the flatten() method const in the PEL section base class and in all of its derived classes.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I6be787962c6d7dfa01bdced2f9024564e6ac1b08
show more ...
|
#
cf5a8d0f |
| 05-Sep-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Add a flatten() to Section base class
To prepare for supporting PEL sections that can be in any order, which will probably be stored in a std::vector<unique_ptr<Section>>, add a pure virtual fu
PEL: Add a flatten() to Section base class
To prepare for supporting PEL sections that can be in any order, which will probably be stored in a std::vector<unique_ptr<Section>>, add a pure virtual function in the Section base class so this list of sections can just be iterated on and have every object in it flattened.
This flatten() call replaces the operator<<(Stream&, <object>) functions currently in use, so also convert the operator>> to unflatten() to make things consistent.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: Id68f16fe4197b389a8495c21539a64f9f583c800
show more ...
|
#
d3335dfa |
| 10-Jul-2019 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Add PrivateHeader class
The first section in a PEL is always the 'Private Header' section. This commit adds a class to represent that. Right now, the only constructor available is filling in
PEL: Add PrivateHeader class
The first section in a PEL is always the 'Private Header' section. This commit adds a class to represent that. Right now, the only constructor available is filling in its data fields from a PEL stream.
The Section base class, which will be the base class of all PEL sections, is also being introduced here. It contains the section header structure, and a valid flag that derived classes can use.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: Ia5806017155fe1ef29ea57bf8ab202ff861bde2e
show more ...
|