4a375950 | 01-Jul-2022 |
Matt Spinler <spinler@us.ibm.com> |
Fix some cppcheck warnings
Fix some of the warnings in the base phosphor-logging code.
It doesn't fix all of them - some are false positives and some are just suggestions, but it does bring down th
Fix some cppcheck warnings
Fix some of the warnings in the base phosphor-logging code.
It doesn't fix all of them - some are false positives and some are just suggestions, but it does bring down the number a bit to make it easier to spot real issues.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I8a131cbc2941ccba79ef3775151007c770207bd5
show more ...
|
45e83521 | 22-Jul-2022 |
Patrick Williams <patrick@stwcx.xyz> |
sdbusplus: use shorter type aliases
The sdbusplus headers provide shortened aliases for many types. Switch to using them to provide better code clarity and shorter lines. Possible replacements are
sdbusplus: use shorter type aliases
The sdbusplus headers provide shortened aliases for many types. Switch to using them to provide better code clarity and shorter lines. Possible replacements are for: * bus_t * exception_t * manager_t * match_t * message_t * object_t * slot_t
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: Ibc25db433a6926f7ee43ea83312c3ac14f480c33
show more ...
|
9ac0d9b8 | 14-Jul-2022 |
George Liu <liuxiwei@inspur.com> |
PEL: Add BMC uptime to PELs in UserData section
A UserData section has been added to each PEL with additional debug information, now there is a need to add the output of the uptime command to UserDa
PEL: Add BMC uptime to PELs in UserData section
A UserData section has been added to each PEL with additional debug information, now there is a need to add the output of the uptime command to UserData and display it, but for Hostboot doesn't care about this property, so skip adding it here it.
Tested: unit test passed "User Data 0": { "Section Version": "1", "Sub-section type": "1", "Created by": "0x2000", ... "Uptime": "3y 332d 21h 33m 9s", "Load": "1.47 0.94 0.61", },
Signed-off-by: George Liu <liuxiwei@inspur.com> Change-Id: I3d4c78bb1650da9a91804fc83de60597992ffc8a
show more ...
|
8b81ec0e | 12-Jul-2022 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Update D-Bus event sev based on PEL severity
Put in checks to ensure the D-Bus event log severity agrees with the final PEL severity for PELs created by the BMC. The D-bus property is what is
PEL: Update D-Bus event sev based on PEL severity
Put in checks to ensure the D-Bus event log severity agrees with the final PEL severity for PELs created by the BMC. The D-bus property is what is used in the Redfish event log, and we want to avoid cases like having a Critical event log for an informational PEL.
This could happen in the case where the PEL message registry entry for the event has a hardcoded or manufacturing specific severity value that is different than the severity the D-Bus event log is first created with.
This commit ensures that: * If the PEL is nonError/recovered, the D-Bus severity is one of the non error ones. * If the PEL isn't nonError/recovered, then the D-Bus severity also isn't. * If the PEL is critical, the D-Bus severity is also critical.
It doesn't try to update the D-Bus severity for every PEL severity because there isn't a one to one mapping - e.g. Notice, Debug, and Informational D-Bus severities all map to a PEL severity of nonError(informational).
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I6b0006034090e6d8e33e9f8b136ae50cce489f6e
show more ...
|
0003af14 | 08-Jun-2022 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Sanitize D-Bus fields that come from PELs
The Resolution D-Bus property is filled with values from the PEL callout fields like the serial and part numbers. These fields usually come from EEPRO
PEL: Sanitize D-Bus fields that come from PELs
The Resolution D-Bus property is filled with values from the PEL callout fields like the serial and part numbers. These fields usually come from EEPROMs, and may not necessarily be valid printable values if the code that creates the PEL doesn't sanitize the values first. If any of the characters were invalid, the daemon would crash when D-Bus broker disconnects it from D-Bus since it doesn't allow invalid values on D-Bus.
Prevent this crash by converting any non printable characters in the Resolution property to spaces. This also sanitizes the EventId property which contains the SRC ASCII string and hex words just to be safe.
This is really just a concern for non-BMC created PELs, since the BMC code that reads EEPROMs already sanitizes the values when it reads them, but PELs have come in from other subsystems that don't.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: If0e80fd9db27446f5367ed046e4bca2eb62e3fb2
show more ...
|
3c7ec6d8 | 06-May-2022 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Allow pretty symFRU/proc name in callout JSON
When callouts are passed in via JSON FFDC files, allow maintenance procedures and symbolic FRUs to be the pretty names used in the message registry
PEL: Allow pretty symFRU/proc name in callout JSON
When callouts are passed in via JSON FFDC files, allow maintenance procedures and symbolic FRUs to be the pretty names used in the message registry as well as the raw 7 character names.
Do this by attempting to look up the name as a key in the pretty name -> raw name maps, and if found then use the raw name.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I576e56932dd101e32caf495c65de6fed65de43e7
show more ...
|
445665af | 17-Mar-2022 |
Paul Fertser <fercerpav@gmail.com> |
rsyslog-config: fix disabled config
When no remote syslog is used action ~ (drop) isn't appropriate as it inhibits processing of the current message for any additional configs that might come after
rsyslog-config: fix disabled config
When no remote syslog is used action ~ (drop) isn't appropriate as it inhibits processing of the current message for any additional configs that might come after server.conf. This file shouldn't be empty either as there're no other output actions defined in default configuration.
Make it a no-op by sending to /dev/null instead. Add a linefeed at the end so that "cat server.conf" would look nicer.
Signed-off-by: Paul Fertser <fercerpav@gmail.com> Change-Id: I6636c76cf0304b3c36f579225846ab19e992c333
show more ...
|
a2d7b775 | 07-Mar-2022 |
Mike Capps <mikepcapps@gmail.com> |
PEL: Remove PowerFault from message entries, registries, and code
The PowerFault flag is deprecated and should be removed in both the registry and code references. Its functionality is superseded by
PEL: Remove PowerFault from message entries, registries, and code
The PowerFault flag is deprecated and should be removed in both the registry and code references. Its functionality is superseded by the critical_system severity level.
Signed-off-by: Mike Capps <mikepcapps@gmail.com> Change-Id: I1bc1898d9589e0678b5a37b87289c6588859f2ee
show more ...
|
23970b0d | 25-Feb-2022 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Support 'PossibleSubsystems' in msg registry
Add a 'PossibleSubsystems' field to the message registry schema where someone can list which subsystems they might pass into the PEL_SUBSYSTEM Addit
PEL: Support 'PossibleSubsystems' in msg registry
Add a 'PossibleSubsystems' field to the message registry schema where someone can list which subsystems they might pass into the PEL_SUBSYSTEM AdditionalData property field when creating a PEL.
The PossibleSubsystems value will be used by a off-BMC script that generates field documentation for SRCs, so it knows what all SRC ASCII string values are possible for that entry since the subsystem is part of them. For example, if that field was ['processor', 'memory'], then that means the possible SRCs are BD10AAAA and BD20AAAA for reason code 'AAAA'.
The Subsystem and PossibleSubsystems fields are mutually exclusive in the message registry, so code changes had to be made to support the subsystem field now being optional.
There is now a chance that even though the subsystem is supposed to be passed in using PEL_SUBSYSTEM, it isn't. In that case, the 'Other' subsystem will be used, since it seems fairly generic.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: Ic8087fc46b2a192459b7287186f8972610e84730
show more ...
|
027bf285 | 24-Jan-2022 |
Sumit Kumar <sumit_kumar@in.ibm.com> |
PEL: Skip purging PEL if it has associated hw isolation entry
When PELs reaches to certain limits, either in total size or total number of them, the code starts removing older pels based on certain
PEL: Skip purging PEL if it has associated hw isolation entry
When PELs reaches to certain limits, either in total size or total number of them, the code starts removing older pels based on certain criteria. During this process make sure no pel is removed that has an associated hardware isolation entry record or error_log event record.
Signed-off-by: Sumit Kumar <sumit_kumar@in.ibm.com> Change-Id: Ia7c9af6911bcf2ac8f8ec046d4c7a7a12d9b2bbd
show more ...
|
e5f7508b | 24-Jan-2022 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Wait a bit after host up before sending PELs
Wait a minute after the host state switches to running before sending any PELs to the host. This applies both on a normal boot and also when the BM
PEL: Wait a bit after host up before sending PELs
Wait a minute after the host state switches to running before sending any PELs to the host. This applies both on a normal boot and also when the BMC is rebooted when the host is already up.
This is being done for 2 reasons: 1) Give some relief to the PLDM traffic and CPU load that occurs after a BMC reboot when the host is already up, because the host will also be exchanging PLDM PDRs with the BMC then and pretty much every application is also starting up at the time as well. 2) A lot of times on a normal boot the host notifier code ends up having to do a few retries when it first starts sending the PELs because the first few commands fail, possibly because the code on the receiving end isn't quite ready yet.
I arrived at that amount of time by deciding 30 seconds was reasonable, and then doubling it just to be sure. During testing of the reboots the minute timeout gave plenty of time for the BMC to get back to BMC ready.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I0929a4acdda0a9fe8fbdcd624c5821a642ad83a6
show more ...
|
fb978da4 | 21-Jan-2022 |
Matt Spinler <spinler@us.ibm.com> |
Pull file path into elog Entry constructor
The path property on the FilePath interfaces was previously being set after the entry object was created, sending a properties changed signal after the int
Pull file path into elog Entry constructor
The path property on the FilePath interfaces was previously being set after the entry object was created, sending a properties changed signal after the interfaces added signal.
Since the path can be known at the time the entry is constructed, pass it into the constructor instead so no extra signal will be sent.
Change-Id: I1150236d23cecb1df78e3fb4ae641c75b488af37
show more ...
|
f8e750dd | 14-Jan-2022 |
Andrew Geissler <geissonator@yahoo.com> |
openpower-pels: only fail on hw callouts
After further discussion with the IBM service and manufacturing team, it was determined that firmware should only be automatically going to Quiesce and preve
openpower-pels: only fail on hw callouts
After further discussion with the IBM service and manufacturing team, it was determined that firmware should only be automatically going to Quiesce and preventing the system boot in QuiesceOnError mode when the PEL has a hardware callout present (vs. any type of callout).
Tested: - New unit test case - Verified that an unrecoverable PEL with only a symbolic FRU and a maintenance procedure callout did not trigger the Quiesce logic - Verified that a BMC log with a HW callout still triggers the Quiesce logic - Verified a boot in simulation with Quiesce enabled
Signed-off-by: Andrew Geissler <geissonator@yahoo.com> Change-Id: I8912d59fd69b699c7da5a44da887cce4e987f6d2
show more ...
|
50bfa69a | 06-Jan-2022 |
Sumit Kumar <sumit_kumar@in.ibm.com> |
PEL: Pass in subsystem to use with additional data
There is a requirement to pass in the subsystem to use with the additional data field. In the process update the user header code and SRC with the
PEL: Pass in subsystem to use with additional data
There is a requirement to pass in the subsystem to use with the additional data field. In the process update the user header code and SRC with the passed-in subsystem value instead from the message registry.
Signed-off-by: Sumit Kumar <sumit_kumar@in.ibm.com> Change-Id: I08c8c3bab100fec581df9043f4bb27b28cb556e1
show more ...
|
f380c516 | 19-Nov-2021 |
Sumit Kumar <sumit_kumar@in.ibm.com> |
PEL: Fix for error - unable to read PEL ID file
This is a case when PEL daemon can't read pelID file to get the next pel Id to use. It could be that the file got corrupted during code update or fact
PEL: Fix for error - unable to read PEL ID file
This is a case when PEL daemon can't read pelID file to get the next pel Id to use. It could be that the file got corrupted during code update or factory reset leading to zeros data in file. The fix is to delete the file as there is already code later to recreate file if not available.
Signed-off-by: Sumit Kumar <sumit_kumar@in.ibm.com> Change-Id: I42372cc1d79ece5914e7fdb51f3fa2a2d9cb07e7
show more ...
|
3e274432 | 14-Sep-2021 |
Sumit Kumar <sumit_kumar@in.ibm.com> |
PEL: Write terminating SRC to the progress SRC
Check for incoming pels for severity type 0x51 - Critical error, System termination. If found, fetch the SRC and add this SRC to progress SRC interface
PEL: Write terminating SRC to the progress SRC
Check for incoming pels for severity type 0x51 - Critical error, System termination. If found, fetch the SRC and add this SRC to progress SRC interface on dbus. In addition set the terminate bit in BMC created pels only.
Signed-off-by: Sumit Kumar <sumit_kumar@in.ibm.com> Change-Id: I26194a26743263183dcb61e097c745c4705fa006
show more ...
|
39936e34 | 13-Nov-2021 |
Zane Shelley <zshelle@us.ibm.com> |
PEL: pad hex words displayed in error message
In the message registry under "Documentation" and "Message", users can include the hex words as part of the error message. This change pads the displaye
PEL: pad hex words displayed in error message
In the message registry under "Documentation" and "Message", users can include the hex words as part of the error message. This change pads the displayed hex words so that the full eight digit hex number is displayed.
Signed-off-by: Zane Shelley <zshelle@us.ibm.com> Change-Id: I32c4204a1643b585dc1309f67976f4abb44fb04c
show more ...
|
ecaa2fce | 05-Nov-2021 |
Jayanth Othayoth <ojayanth@in.ibm.com> |
PEL: Add guard record entry create function
Added D-Bus wrapper function to create guard record entry D-Bus object.
hardware isolation API's used no no-reply mode to avoid cyclic dependency with lo
PEL: Add guard record entry create function
Added D-Bus wrapper function to create guard record entry D-Bus object.
hardware isolation API's used no no-reply mode to avoid cyclic dependency with log manager. PEL log already have the details of guard records properties. For any failure during record creation is hardware isolation application is ignored by log manager. User will get details on this failure by looking hardware isolation log information.
Tested: verified D-Bus create method.
Signed-off-by: Jayanth Othayoth <ojayanth@in.ibm.com> Change-Id: I8c7703dc28aaf7b39793e3bd1dfe4fac374d9ad5
show more ...
|
66491c61 | 06-Oct-2021 |
Patrick Williams <patrick@stwcx.xyz> |
catch exceptions as const
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: Ic8e6ade739bd5ea6e79cac6b9bb2b182748e10c8 |
242be740 | 16-Sep-2021 |
Vijay Lobo <vijaylobo@gmail.com> |
PEL: Update pel_values to support bmcweb
Updates done to support display of Message property in bmcweb. With the redfish command the message property showed up as --old- "Message": "xyz.openbmc_proj
PEL: Update pel_values to support bmcweb
Updates done to support display of Message property in bmcweb. With the redfish command the message property showed up as --old- "Message": "xyz.openbmc_project.Power.PowerSupply.Error.InputFault" --New-- "Message": "110015F0 event in subsystem: Power Supply",
Note that the "Power Supply" is a $subsystem property and had ':' in the description, to enhance readability the $subsystem for CEC Hardware is update with '-' in place of ':'.
Change-Id: Ic6af0937f4e560753814462692b95185a6d84d07 Signed-off-by: Vijay Lobo <vijaylobo@gmail.com>
show more ...
|
2c36fddc | 21-Sep-2021 |
Sumit Kumar <sumit_kumar@in.ibm.com> |
PEL: Store system boot state in user data section
For every incoming pel data interface watches the dbus property that includes the latest boot progress/state value. This value would be captured and
PEL: Store system boot state in user data section
For every incoming pel data interface watches the dbus property that includes the latest boot progress/state value. This value would be captured and stored in user data section of pel.
Signed-off-by: Sumit Kumar <sumit_kumar@in.ibm.com> Change-Id: Ie48e7ee9fdd965af672f4bd563f8c9fc3bfacc43
show more ...
|
9d43a727 | 24-Aug-2021 |
Sumit Kumar <sumit_kumar@in.ibm.com> |
PEL: Update bmc & platform dump status in SRC section
With every PEL creation, the status of bmc and platform dumps - Hardware and Hypervisor would be checked and status bits in SRC section updated
PEL: Update bmc & platform dump status in SRC section
With every PEL creation, the status of bmc and platform dumps - Hardware and Hypervisor would be checked and status bits in SRC section updated accordingly.
Change-Id: I3ec7626611cf330f2ce235a97ee3046c0d32b6ab Signed-off-by: Sumit Kumar <sumit_kumar@in.ibm.com>
show more ...
|
ea2873dd | 18-Aug-2021 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Change BMCSP01 maint procedure to BMC0001
This name change allows 4 characters of uniqueness instead of just 2.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I12cb883619a3a3c2f84
PEL: Change BMCSP01 maint procedure to BMC0001
This name change allows 4 characters of uniqueness instead of just 2.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I12cb883619a3a3c2f843dd7ccc3db6524dea3459
show more ...
|
479b6927 | 17-Aug-2021 |
Matt Spinler <spinler@us.ibm.com> |
PEL: Remove 'no_vpd_for_fru' maintenance procedure
This procedure was being used in a callout when the location code could not be found on an inventory item. The code was changed to just not add a
PEL: Remove 'no_vpd_for_fru' maintenance procedure
This procedure was being used in a callout when the location code could not be found on an inventory item. The code was changed to just not add a callout in this case.
This was done for the following reasons: 1) There's no expected reason that the inventory would be missing a location code for a valid inventory path. 2) There wasn't a way to give a hint to the end user about what the callout should be in that case. Usually maintenance procedures should have steps one can take to still do the appropriate replacement. 3) Because of 1), this case indicates a bad inventory path passed in by the caller. Theoretically there is a way to have a 'bmc_code' callout, but that wouldn't be appropriate to add in this log since the intent of this one is for another problem. 3a) There is no way to create a new error log from inside a PEL section, and I don't think this one case warrants coming up with a way to do so. 4) The inventory path in question is still being added into a UserData section so that development can debug it.
Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I0757080f04942807cc34029d8667387db6b959fe
show more ...
|
2ccdcef9 | 31-Jul-2021 |
Sumit Kumar <sumit_kumar@in.ibm.com> |
PEL: Guard against hostboot sending down duplicate PEL Ids
This commit is to guard against hostboot sending down PEL Id that we already have in our repository. This caused PEL to get orphaned in the
PEL: Guard against hostboot sending down duplicate PEL Ids
This commit is to guard against hostboot sending down PEL Id that we already have in our repository. This caused PEL to get orphaned in the filesystem without a corresponding valid openbmc event log Id. The action is to move such PELs to archive folder.
Signed-off-by: Sumit Kumar <sumit_kumar@in.ibm.com> Change-Id: I46bb865b4b87ec0b59f362e3f79a1b5a6710a45c
show more ...
|