History log of /openbmc/phosphor-logging/extensions/openpower-pels/private_header.cpp (Results 1 – 20 of 20)
Revision Date Author Comments
# 5bc26533 10-Apr-2024 Arya K Padman <aryakpadman@gmail.com>

PEL: Changing the remaining traces to lg2 style

Some of the logging traces of PEL files still uses old style of logging.

Changing the remaining traces in PEL files to lg2 style of logging.Some
of t

PEL: Changing the remaining traces to lg2 style

Some of the logging traces of PEL files still uses old style of logging.

Changing the remaining traces in PEL files to lg2 style of logging.Some
of the traces in phosphor logging code which use the old style is also
considered.

Change-Id: I0daf9589af443881cb61730047c23db17fdec2c3
Signed-off-by: Arya K Padman <aryakpadman@gmail.com>

show more ...


# 1aa90d49 13-Sep-2023 Jayanth Othayoth <ojayanth@in.ibm.com>

PEL: switch fmt::format to use std::format

fmt::format is supported in the c++ std. This will
help to remove fmt package dependency.

Change-Id: I89f0a5b67bbfe54168a20e93c989a1ae87f54503
Signed-

PEL: switch fmt::format to use std::format

fmt::format is supported in the c++ std. This will
help to remove fmt package dependency.

Change-Id: I89f0a5b67bbfe54168a20e93c989a1ae87f54503
Signed-off-by: Jayanth Othayoth <ojayanth@in.ibm.com>

show more ...


# 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 ...


# 9f5c7349 13-Mar-2023 Matt Spinler <spinler@us.ibm.com>

PEL: Fix typo in journal trace

Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Change-Id: I57aff70bebb20e84b443bb2827e94ec913e2584a


# 8ac20500 04-Jan-2023 Matt Spinler <spinler@us.ibm.com>

PEL: Put validation fail details into journal msg

In the PEL section classes, move some journal fields from the journal
metadata section into the journal message itself, to make debug slightly
easie

PEL: Put validation fail details into journal msg

In the PEL section classes, move some journal fields from the journal
metadata section into the journal message itself, to make debug slightly
easier.

Specifically, this is just for when unflattening or validating the
sections fail.

Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Change-Id: I6d5661015b5ce5c07ed2fd6eb7ce864d0c620092

show more ...


# 7f1b9052 22-Mar-2022 Matt Spinler <spinler@us.ibm.com>

Revert "PEL: Create trace wrapper for peltool"

This reverts commit 2ea96f6c6c92bb585668cff7c659cdea606dfc68.

Going to go in a different direction and not build peltool in other
contexts.

Change-Id

Revert "PEL: Create trace wrapper for peltool"

This reverts commit 2ea96f6c6c92bb585668cff7c659cdea606dfc68.

Going to go in a different direction and not build peltool in other
contexts.

Change-Id: I92fefbb3fe5249f2cc0ccf679febe5a3b3340048

show more ...


# 2ea96f6c 23-Feb-2022 Matt Spinler <spinler@us.ibm.com>

PEL: Create trace wrapper for peltool

In preparation for peltool being compiled for non-BMC platforms where
libphosphor_logging.so isn't available, create a wrapper function for
tracing so phosphor:

PEL: Create trace wrapper for peltool

In preparation for peltool being compiled for non-BMC platforms where
libphosphor_logging.so isn't available, create a wrapper function for
tracing so phosphor::logging::log() isn't directly used by the code that
is part of peltool.

For now, the wrapper will just call phosphor::logging::log, but in the
future will be changed to call std::cerr when not on the BMC.

A few files were changed to make use of the new calls. Others will be
done with future commits. Only the code that is built into peltool
needs to use this. This mostly consists of the PEL section classes.

Using this new API does mean no extra data can be stored in the journal
metadata, as the systemd journal may not be available on some platforms
the tool may need to run on, such as AIX. Instead, the data can just be
added into the trace string itself.

In a future commit, the meson.build file will be refactored to remove
the libphosphor_logging dependency so the build will fail if a call to
the phosphor-logging's log() is made within peltool code.

Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Change-Id: I5e6c235d60466b031e15b157860c07a3f8ddb148

show more ...


# 74348c60 26-Oct-2021 Sumit Kumar <sumit_kumar@in.ibm.com>

SW538090: PEL: Fix for pel commit time issue

In PEL commit time logic, commit yearMSB was wrongly interpreted
as created time yearMSB.

Signed-off-by: Sumit Kumar <sumit_kumar@in.ibm.com>
Change-Id:

SW538090: PEL: Fix for pel commit time issue

In PEL commit time logic, commit yearMSB was wrongly interpreted
as created time yearMSB.

Signed-off-by: Sumit Kumar <sumit_kumar@in.ibm.com>
Change-Id: I27285fa5d65f4fab69090153fdf072bf41133d95

show more ...


# bebeb948 12-Mar-2020 Harisuddin Mohamed Isa <harisuddin@gmail.com>

PEL: peltool: Add const strings for section header

Added "Section Version", "Sub-section type" and "Created by" constant strings.

Updated all getJSON() functions to use the new constants.

Signed-o

PEL: peltool: Add const strings for section header

Added "Section Version", "Sub-section type" and "Created by" constant strings.

Updated all getJSON() functions to use the new constants.

Signed-off-by: Harisuddin Mohamed Isa <harisuddin@gmail.com>
Change-Id: I434192afed929972845c3cfb8876cc5ef784eec2

show more ...


# 160c51cb 13-Feb-2020 Harisuddin Mohamed Isa <harisuddin@gmail.com>

PEL: Print Extended User Header section to JSON

"Extended User Header": {
"Section Version": "1",
"Sub-section type": "0",
"Created by": "0x4552",
"Rep

PEL: Print Extended User Header section to JSON

"Extended User Header": {
"Section Version": "1",
"Sub-section type": "0",
"Created by": "0x4552",
"Reporting Machine Type": "OPWR-131",
"Reporting Serial Number": "1318ABA",
"FW Released Ver": "BE868_007",
"FW SubSys Version": "00040905079B0004",
"Common Ref Time": "00/00/0000 00:00:00",
"Symptom Id Len": "0",
"Symptom Id": ""
},

Verified peltool output and all testcases passed.
Signed-off-by: Harisuddin Mohamed Isa <harisuddin@gmail.com>
Change-Id: Id66b9da27d49c89befd157b0e94bbc9defed0d6a

show more ...


# ebffe1c2 15-Jan-2020 Matt Spinler <spinler@us.ibm.com>

PEL: Print OBMC event log ID in peltool

In the PrivateHeader section, add an entry into peltool's JSON
output for the OpenBMC event log ID.

This is a reserved field in the PEL spec, but we are usin

PEL: Print OBMC event log ID in peltool

In the PrivateHeader section, add an entry into peltool's JSON
output for the OpenBMC event log ID.

This is a reserved field in the PEL spec, but we are using it to
associate the PEL to the BMC event log it came from.

Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Change-Id: Id347aa67f79d7f5fac1e572de100755df7b29e6e

show more ...


# 2ecb465b 09-Jan-2020 Harisuddin Mohamed Isa <harisuddin@gmail.com>

PEL: Print Private Header into JSON aligned

"Private Header": {
"Section Version": "1",
"Sub-section type": "0",
"Created by": "0x1000",
"Created at":

PEL: Print Private Header into JSON aligned

"Private Header": {
"Section Version": "1",
"Sub-section type": "0",
"Created by": "0x1000",
"Created at": "12/05/2019 18:32:42",
"Committed at": "12/05/2019 18:32:42",
"Creator Subsystem": "BMC",
"CSSVER": "",
"Platform Log Id": "0x50000C00",
"Entry Id": "0x50000C00"
}

Testing: Manually run peltool and verified output
Signed-off-by: Harisuddin Mohamed Isa <harisuddin@gmail.com>
Change-Id: Ib6ef49f1b29486a97e86700b19ac982e43bede37

show more ...


# c92b4eb4 18-Nov-2019 Aatir <aatrapps@gmail.com>

PEL: private header in JSON

The PELTool application is able to convert sections to JSON. This commit
takes care of converting the private header section to JSON.

private header section in JSON samp

PEL: private header in JSON

The PELTool application is able to convert sections to JSON. This commit
takes care of converting the private header section to JSON.

private header section in JSON sample:

"Private Header":[
{"Section Version": "1"},
{"Sub-section type": "0"},
{"Log Committed by": "0x1000"},
{"Entry Creation": "10/24/2019 15:50:08"},
{"Entry Commit": "10/24/2019 15:50:08"},
{"Creator ID": "BMC"},
{"Creator Implementation": ""},
{"Platform Log ID": "0x50000004"},
{"Log Entry ID": "0x50000004"}
]

Signed-off-by: Aatir <aatrapps@gmail.com>
Change-Id: I8b0d7dc7b70cd2a03f67f7c9a48755803634005d

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 ...


# 711d51d8 06-Nov-2019 Matt Spinler <spinler@us.ibm.com>

PEL: Add license prologue to source files

Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Change-Id: I31b12f509d32b79064a8a427af35e6a310273051


# 31eed996 09-Oct-2019 Matt Spinler <spinler@us.ibm.com>

PEL: Initialize PrivateHeader fields in ctor

In the stream constructor, initialize the member variables to 0 before
unflattening.

This only matters when the data is so short that the 'section count

PEL: Initialize PrivateHeader fields in ctor

In the stream constructor, initialize the member variables to 0 before
unflattening.

This only matters when the data is so short that the 'section count'
field doesn't get initialized and so the code tries to loop through and
unflatten that many optional sections, and since there aren't actually
any it was spitting out extra journal traces about invalid section IDs.

Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Change-Id: If08e9ae244d5ade96cafa2160ad9714bebe34551

show more ...


# 289aa477 20-Sep-2019 Matt Spinler <spinler@us.ibm.com>

PEL: Create PrivateHeader from parameters

Add a constructor to the PrivateHeader class so it can be built from the
creator's component ID, the OpenBMC log ID, and the creation timestamp.

This will

PEL: Create PrivateHeader from parameters

Add a constructor to the PrivateHeader class so it can be built from the
creator's component ID, the OpenBMC log ID, and the creation timestamp.

This will be used when creating PELs from OpenBMC event logs.

Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Change-Id: I2d1217b9ff0317195366bee50fa72953fd5341dc

show more ...


# 1a94cc38 11-Sep-2019 Matt Spinler <spinler@us.ibm.com>

PEL: Move PEL section IDs into a header file

These will eventually need to be known to a piece of code that
unflattens a PEL into the appropriate section class objects based on the
section ID field

PEL: Move PEL section IDs into a header file

These will eventually need to be known to a piece of code that
unflattens a PEL into the appropriate section class objects based on the
section ID field in the PEL data.

Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Change-Id: I90b9d4be49b2e3807a620745fa663f94f7f4e62c

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 ...