#
c488bac1 |
| 17-Mar-2025 |
Chris Cain <cjcain@us.ibm.com> |
Clear flags when the host changes to powered off state
When the host is powered off, the OCCs will be stopped, so clear any reset pending flags as well as any outstanding HRESET requests.
This will
Clear flags when the host changes to powered off state
When the host is powered off, the OCCs will be stopped, so clear any reset pending flags as well as any outstanding HRESET requests.
This will ensure the next boot will start clean and not react to something that happened on prior boot.
Tested on Rainier for several error scenarios.
Change-Id: Ie4156975a844e823787f7162ee0542d7f099bd12 Signed-off-by: Chris Cain <cjcain@us.ibm.com>
show more ...
|
#
2d6ec909 |
| 01-Feb-2025 |
Patrick Williams <patrick@stwcx.xyz> |
clang-format: update latest spec and reformat
Copy the latest format file from the docs repository and apply.
Change-Id: I289fffda3d8b39bb9b16eab30928d0aa7c8e1821 Signed-off-by: Patrick Williams <p
clang-format: update latest spec and reformat
Copy the latest format file from the docs repository and apply.
Change-Id: I289fffda3d8b39bb9b16eab30928d0aa7c8e1821 Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
show more ...
|
#
f0295f52 |
| 12-Sep-2024 |
Chris Cain <cjcain@us.ibm.com> |
Improve BMC error handling for OCC comm failures
- Delay starting OCC reset until all OCCs have been detected (or timeout). It will prevent multiple resets from being triggered and to help detecting
Improve BMC error handling for OCC comm failures
- Delay starting OCC reset until all OCCs have been detected (or timeout). It will prevent multiple resets from being triggered and to help detecting when reset is completed (active sensor being set after reset is complete) - Wait for PLDM response to OCC reset and HRESET requests and retry if they fail - If HRESET returns NOT_READY, collect SBE FFDC and try OCC reset. A persistent failure will put the system in safe state.
- Prevent overwriting dvfs over-temp filename for p10 and beyond since that old file is only present in old kernel - Prevent assert when opening sysfs files. (added catch and then created an OCC Comm failure PEL, which will force an OCC reset.) - Check return code after reading sysfs files to confirm success. If read fails, try reset to recover.
- Updated traces to include which processor/OCC encountered issues. - Better recovery to close windows that were leaving system in partial good state.
JIRA: PFES-66 Change-Id: I0b087d0e05bd8562682062e1c662f9e18164a720 Signed-off-by: Chris Cain <cjcain@us.ibm.com>
show more ...
|
#
6213f199 |
| 01-Jul-2024 |
Lakshmi Yadlapati <lakshmiy@us.ibm.com> |
Add kernel MCTP (AF_MCTP) support and transport-implementation option
-Added support for kernel MCTP (AF_MCTP) to enable MCTP communication using AF_MCTP sockets.
- Introduced a new configuration
Add kernel MCTP (AF_MCTP) support and transport-implementation option
-Added support for kernel MCTP (AF_MCTP) to enable MCTP communication using AF_MCTP sockets.
- Introduced a new configuration option 'transport-implementation'
The 'transport-implementation' option can be set to either: - 'mctp-demux': Uses the existing mctp-demux transport method. - 'af-mctp': Uses the new kernel AF_MCTP transport method.
Change-Id: I2978273fe4579d1dce00368dabb7f90815dbbce8 Signed-off-by: Lakshmi Yadlapati <lakshmiy@us.ibm.com> Signed-off-by: Eddie James <eajames@linux.ibm.com>
show more ...
|
#
d7542c83 |
| 16-Aug-2024 |
Patrick Williams <patrick@stwcx.xyz> |
clang-format: re-format for clang-18
clang-format-18 isn't compatible with the clang-format-17 output, so we need to reformat the code with the latest version. The way clang-18 handles lambda forma
clang-format: re-format for clang-18
clang-format-18 isn't compatible with the clang-format-17 output, so we need to reformat the code with the latest version. The way clang-18 handles lambda formatting also changed, so we have made changes to the organization default style format to better handle lambda formatting.
See I5e08687e696dd240402a2780158664b7113def0e for updated style. See Iea0776aaa7edd483fa395e23de25ebf5a6288f71 for clang-18 enablement.
Change-Id: I94e2bfdc8fae9bc14e30c701a0e622709ee9b0fe Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
show more ...
|
#
52328cb4 |
| 14-Feb-2023 |
Rashmica Gupta <rashmica@linux.ibm.com> |
Move to libpldm pldm_transport APIs
- Replaced the deprecated pldm transport APIs with the new libpldm pldm_transport APIs.
This change migrates the application off of the deprecated "requester"
Move to libpldm pldm_transport APIs
- Replaced the deprecated pldm transport APIs with the new libpldm pldm_transport APIs.
This change migrates the application off of the deprecated "requester" APIs in libpldm.
We don't currently have the infrastructure in place to get the correct TIDs, so to keep everything working as before use the EID as the TID in the EID-to-TID mapping.
Change-Id: Iedbfe936a710d37f75e737c3d307295ff55cf07b Signed-off-by: Rashmica Gupta <rashmica@linux.ibm.com> Signed-off-by: Lakshmi Yadlapati <lakshmiy@us.ibm.com>
show more ...
|
#
db38e91a |
| 24-May-2023 |
Rashmica Gupta <rashmica@linux.ibm.com> |
Move to libpldm instance id APIs
Signed-off-by: Rashmica Gupta <rashmica@linux.ibm.com> Change-Id: I2955097a78c673f65054fa9bff1ef5243da136a2 Signed-off-by: Lakshmi Yadlapati <lakshmiy@us.ibm.com>
|
#
aeba51cd |
| 16-Feb-2023 |
Rashmica Gupta <rashmica@linux.ibm.com> |
Change "mctp instance id" to "pldm instance id"
It's not a MCTP thing.
Change-Id: I922d28f848c8948d43ea4b8926d2310c8fb50228 Signed-off-by: Rashmica Gupta <rashmica@linux.ibm.com> Signed-off-by: Lak
Change "mctp instance id" to "pldm instance id"
It's not a MCTP thing.
Change-Id: I922d28f848c8948d43ea4b8926d2310c8fb50228 Signed-off-by: Rashmica Gupta <rashmica@linux.ibm.com> Signed-off-by: Lakshmi Yadlapati <lakshmiy@us.ibm.com>
show more ...
|
#
755af102 |
| 27-Feb-2024 |
Chris Cain <cjcain@us.ibm.com> |
Handle other PLDM_STATE_SET_OPERATIONAL states
- Code will no longer assume the OCC is not running if an unexpected state is received. It will continue to look for a good/known state. - Added code t
Handle other PLDM_STATE_SET_OPERATIONAL states
- Code will no longer assume the OCC is not running if an unexpected state is received. It will continue to look for a good/known state. - Added code that will throttle the occ-control pldm journal traces if unable to read the OCC active sensor states. In some error conditions, this tracing would flood the trace and the repeated traces are not helpful for debug. - Change some journal entries to ERR when the state indicated that the system was in safe mode (OCCs disabled) - If request for occ active sensor state was sent, and then a PLDM sensor event comes in for that instance, the event status is used and the response is ignored. - Added README for occ-control
Signed-off-by: Chris Cain <cjcain@us.ibm.com> Change-Id: Ic26f1d0c4dc59e7a61b965b052d649e4bc152fde
show more ...
|
#
af40808f |
| 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: I9541d521bf67882215a4a66dce020e38ac2df065
show more ...
|
#
157467d0 |
| 24-Jun-2022 |
Chris Cain <cjcain@us.ibm.com> |
Revert clearing PDRs if host power is off
Code was added to clear the PDRs when the host was powered off, but the next power on occ-control never saw the OCC StateSensor updates. This change will be
Revert clearing PDRs if host power is off
Code was added to clear the PDRs when the host was powered off, but the next power on occ-control never saw the OCC StateSensor updates. This change will be reverted to resolve this issue.
Tested on multiple machines with multiple reboots and guarded procs
Change-Id: Ibea28ede25c81f22e4e9fe2574c1668c4a81352c Signed-off-by: Chris Cain <cjcain@us.ibm.com>
show more ...
|
#
72d01aab |
| 14-Jun-2022 |
Chris Cain <cjcain@us.ibm.com> |
Fix correlation between OCC StateSensorPDRs and procs
occ-control was not correlating the OCC Active sensors with the correct processor. Code change will now use the Sensor ID to know which OCC/proc
Fix correlation between OCC StateSensorPDRs and procs
occ-control was not correlating the OCC Active sensors with the correct processor. Code change will now use the Sensor ID to know which OCC/proc is active. Hostboot will also be making a change to ensure that the Sensor IDs are always numbered according to processor order (p0, p1, etc)
Wait for PHYP to start before reading PLDM sensors: occ-control caches the PLDM sensor IDs to limit the dbus queries. The cache was supposed to be cleared when the OS was powered off, but the existing code only cleared it when CurrentHostState was Off. Got a defect where occ-control was using invalid/old sensor IDs when getting notifications of OCC Active sensors. This causes the app to try communicating with the wrong or invalid OCC.
Code change will clear the sensor cache anytime PHYP is not running, and will populate the cache once PHYP is running.
Tested on hardware with various boot types and resets.
Change-Id: I4b32aa848768296065d6570466475f5b17771d2e Signed-off-by: Chris Cain <cjcain@us.ibm.com>
show more ...
|
#
8b508bfb |
| 26-May-2022 |
Chris Cain <cjcain@us.ibm.com> |
Reuse MCTP instance IDs for PLDM retries
occ-control will request a new instance ID when it times out waiting for the PLDM response. Code change will not request a new ID unless the prior response w
Reuse MCTP instance IDs for PLDM retries
occ-control will request a new instance ID when it times out waiting for the PLDM response. Code change will not request a new ID unless the prior response was received successfully.
Change-Id: I8a3509d7ea583bb706ad2ef41bf90cc5d0f0275b Signed-off-by: Chris Cain <cjcain@us.ibm.com>
show more ...
|
#
31a2f13a |
| 20-May-2022 |
Sheldon Bailey <baileysh@us.ibm.com> |
Add safe mode to user interface
putting in code that puts safe mode onto dbus. Tested: inject error that puts in safe mode, dbus CMD to read dbus safeMode. Signed-off-by: Sheldon Bailey <baileysh@us
Add safe mode to user interface
putting in code that puts safe mode onto dbus. Tested: inject error that puts in safe mode, dbus CMD to read dbus safeMode. Signed-off-by: Sheldon Bailey <baileysh@us.ibm.com> Change-Id: I48c5b41a48d0883a8d1e2916da8725391a7bcbc2
show more ...
|
#
12d0b828 |
| 22-Apr-2022 |
Chris Cain <cjcain@us.ibm.com> |
Ignore HRESET status when we did not request
Code was monitoring StateSensorEvents for HRESET changes and acting on them even if we did not make the request. This change will ignore the state chang
Ignore HRESET status when we did not request
Code was monitoring StateSensorEvents for HRESET changes and acting on them even if we did not make the request. This change will ignore the state change if we do not have an outstanding request.
Change-Id: Iaa61a6bc4d0ebb9e21a6e0960e771f84a6553dc6 Signed-off-by: Chris Cain <cjcain@us.ibm.com>
show more ...
|
#
bae4d07e |
| 28-Feb-2022 |
Chris Cain <cjcain@us.ibm.com> |
Wait for OCC Active PDR to become available
occ-control was attempting to communicate with OCCs before the OCC Active sensor PDR was available. This commit will wait until all PDRs are available bef
Wait for OCC Active PDR to become available
occ-control was attempting to communicate with OCCs before the OCC Active sensor PDR was available. This commit will wait until all PDRs are available before allowing communication with the OCCs. It will also read the OCC Active sensor to determine the state before allowing communication.
When Hostboot moves a system to safe mode it will set the PLDM state of the OCC Active sensor to PLDM_STATE_SET_OPERATIONAL_RUNNING_STATUS_DORMANT This commit will also handle processing of that DORMANT status.
Change-Id: I348cf14455d9373898deec2ac4a04b3752e81c4a Signed-off-by: Chris Cain <cjcain@us.ibm.com>
show more ...
|
#
d1b6826a |
| 28-Feb-2022 |
Chris Cain <cjcain@us.ibm.com> |
Make PLDM call to reset OCCs an asynchronous call
The current signal to reset the OCCs/PM Complex waits for a response from hostboot. If there is an issue with the connection to Hostboot, the pldm_s
Make PLDM call to reset OCCs an asynchronous call
The current signal to reset the OCCs/PM Complex waits for a response from hostboot. If there is an issue with the connection to Hostboot, the pldm_send_recv call will hang. This code change will make the call asynchronous. If hostboot recovers, a notification indicating the OCCs are active will get re-sent.
Change-Id: I809f00fd03277d29749989cd1b546525072d3adf Signed-off-by: Chris Cain <cjcain@us.ibm.com>
show more ...
|
#
f3a4a69f |
| 27-Dec-2021 |
George Liu <liuxiwei@inspur.com> |
Fix some warnings by cppcheck
Warning message: ../../../occ_events.hpp:16:9: warning: Value stored to 'event' is never read [deadcode.DeadStores] event = sd_event_unref(event); ^
Fix some warnings by cppcheck
Warning message: ../../../occ_events.hpp:16:9: warning: Value stored to 'event' is never read [deadcode.DeadStores] event = sd_event_unref(event); ^ ~~~~~~~~~~~~~~~~~~~~~ ../../../occ_events.hpp:26:9: warning: Value stored to 'eventSource' is never read [deadcode.DeadStores] eventSource = sd_event_source_unref(eventSource);
occ_dbus.cpp:34:47: performance: Searching before insertion is not necessary. [stlFindInsert] path, std::make_unique<SensorIntf>(utils::getBus(), path.c_str())); ^ occ_dbus.cpp:61:47: performance: Searching before insertion is not necessary. [stlFindInsert] path, std::make_unique<SensorIntf>(utils::getBus(), path.c_str())); ^ occ_dbus.cpp:88:47: performance: Searching before insertion is not necessary. [stlFindInsert] path, std::make_unique<SensorIntf>(utils::getBus(), path.c_str())); ^ occ_dbus.cpp:115:47: performance: Searching before insertion is not necessary. [stlFindInsert] path, std::make_unique<SensorIntf>(utils::getBus(), path.c_str())); ^ occ_dbus.cpp:158:80: performance: Searching before insertion is not necessary. [stlFindInsert] operationalStatus.emplace(path, std::make_unique<OperationalStatusIntf>( ^ occ_pass_through.hpp:42:5: style: Class 'PassThrough' has a constructor with 1 argument that is not explicit. [noExplicitConstructor] PassThrough(const char* path); ^ powercap.hpp:41:5: style: Class 'PowerCap' has a constructor with 1 argument that is not explicit. [noExplicitConstructor] PowerCap(Status& occStatus, ^ occ_manager.hpp:77:5: style: Struct 'Manager' has a constructor with 1 argument that is not explicit. [noExplicitConstructor] Manager(EventPtr& event) : ^ occ_status.hpp:307:26: style: Local variable 'path' shadows outer variable [shadowVariable] auto path = fs::path(estimatedPath); ^ occ_status.hpp:207:17: note: Shadowed declaration std::string path; ^ occ_status.hpp:307:26: note: Shadow variable auto path = fs::path(estimatedPath); ^ pldm.hpp:55:14: warning: Member variable 'Interface::OCCSensorOffset' is not initialized in the constructor. [uninitMemberVar] explicit Interface( ^ pldm.hpp:55:14: warning: Member variable 'Interface::SBESensorOffset' is not initialized in the constructor. [uninitMemberVar] explicit Interface( ^ powermode.hpp:60:5: style: Class 'PowerMode' has a constructor with 1 argument that is not explicit. [noExplicitConstructor] PowerMode(Status& occStatus) : ^ powermode.hpp:96:5: style: Class 'PowerIPS' has a constructor with 1 argument that is not explicit. [noExplicitConstructor] PowerIPS(Status& occStatus) : ^ occ_manager.cpp:321:24: style: The scope of the variable 'path' can be reduced. [variableScope] constexpr auto path = "/org/openpower/dump"; ^ occ_manager.cpp:322:24: style: The scope of the variable 'interface' can be reduced. [variableScope] constexpr auto interface = "xyz.openbmc_project.Dump.Create"; ^ occ_manager.cpp:323:24: style: The scope of the variable 'function' can be reduced. [variableScope] constexpr auto function = "CreateDump"; ^ pldm.cpp:78:16: style: Local variable 'pdr' shadows outer variable [shadowVariable] for (auto& pdr : pdrs) ^ pldm.cpp:48:10: note: Shadowed declaration auto pdr = ^ pldm.cpp:78:16: note: Shadow variable for (auto& pdr : pdrs) ^ pldm.cpp:248:16: style: Local variable 'pdr' shadows outer variable [shadowVariable] for (auto& pdr : pdrs) ^ pldm.cpp:221:10: note: Shadowed declaration auto pdr = ^ pldm.cpp:248:16: note: Shadow variable for (auto& pdr : pdrs) ^ powermode.cpp:28:22: style: Variable 'pmode' is assigned a value that is never used. [unreadVariable] SysPwrMode pmode = SysPwrMode::NO_CHANGE;
Tested: Use cppcheck to build successfully and eliminate the above warning message.
Signed-off-by: George Liu <liuxiwei@inspur.com> Change-Id: I72751dc94db684fc558b4bb57b1924be64ce6760
show more ...
|
#
432dc486 |
| 19-Nov-2021 |
Eddie James <eajames@linux.ibm.com> |
pldm: Fix HRESET handling and incorrect entity ID
The HRESET state signal wasn't being handled, since the message sensor offsets are the same for OCC and SBE; both maps need to be checked and action
pldm: Fix HRESET handling and incorrect entity ID
The HRESET state signal wasn't being handled, since the message sensor offsets are the same for OCC and SBE; both maps need to be checked and action taken if the sensor ID is found. In addition, the OCC reset effecter was incorrectly using the processor module entity ID, rather than the processor.
Signed-off-by: Eddie James <eajames@linux.ibm.com> Change-Id: I9e601560e1144101ce6515809a265fdd7db01b06
show more ...
|
#
cbad219e |
| 07-Oct-2021 |
Eddie James <eajames@linux.ibm.com> |
Add SBE timeout handling
Add an Error instance to detect SBE timeouts in the driver. Refactor the PLDM code to handle another requeset type (the HRESET) and another type of sensor event (success or
Add SBE timeout handling
Add an Error instance to detect SBE timeouts in the driver. Refactor the PLDM code to handle another requeset type (the HRESET) and another type of sensor event (success or failure of the HRESET). Handle the timeout and the PLDM event state change in the Manager by changing the SBE state and requesting an SBE dump if necessary.
Signed-off-by: Eddie James <eajames@linux.ibm.com> Change-Id: I30d8f9de1914d9808ddb7b547cc57085a5e5779e
show more ...
|
#
b5ca1015 |
| 09-Sep-2021 |
George Liu <liuxiwei@inspur.com> |
Update clang-format
refer: https://github.com/openbmc/docs/blob/master/style/cpp/.clang-format
Tested: built openpower-occ-control successfully.
Signed-off-by: George Liu <liuxiwei@inspur.com> Cha
Update clang-format
refer: https://github.com/openbmc/docs/blob/master/style/cpp/.clang-format
Tested: built openpower-occ-control successfully.
Signed-off-by: George Liu <liuxiwei@inspur.com> Change-Id: I136870023229ff906d471dd4d8debfd404812ff1
show more ...
|
#
05e95596 |
| 02-Sep-2021 |
Patrick Williams <patrick@stwcx.xyz> |
dos2unix conversion
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: Ie0fd9e423bd832eea6b31e9fbd683cbf7d1c4567
|
#
48330578 |
| 22-Jun-2021 |
Chris Cain <cjcain@us.ibm.com> |
Fix getBus namespaces in pldm Interface object
Compile was failing when '--with-host-communication-protocol=pldm' was specified.
Change-Id: If15a583584b761cc42c34154a2c5c4194b84d2a1 Signed-off-by:
Fix getBus namespaces in pldm Interface object
Compile was failing when '--with-host-communication-protocol=pldm' was specified.
Change-Id: If15a583584b761cc42c34154a2c5c4194b84d2a1 Signed-off-by: Chris Cain <cjcain@us.ibm.com>
show more ...
|
#
f3b7514e |
| 09-Jun-2021 |
George Liu <liuxiwei@inspur.com> |
Refactor D-Bus object
- The intent behind this commit is to refactor D-Bus, and abstract the bus, getService, getProperty and other methods into the utils file, and other file operations D-Bus o
Refactor D-Bus object
- The intent behind this commit is to refactor D-Bus, and abstract the bus, getService, getProperty and other methods into the utils file, and other file operations D-Bus only need to include uitls.hpp.
- We can also continue to add other general methods such as setPropery, getSubTree in the utils file in the future.
- Also, removed redundant files(occ_finder.hpp and occ_finder.cpp).
Tested: built openpower-occ-control successfully and worked.
Signed-off-by: George Liu <liuxiwei@inspur.com> Change-Id: I53e61e30a76173c154a9f47fc122936468abbc4b
show more ...
|
#
00325238 |
| 29-Jul-2020 |
Tom Joseph <tomjoseph@in.ibm.com> |
pldm: Add support for OCC reset
BMC initiated OCC reset is translated to a SetStateEffecterStates request for state effecter corresponding to the OCC instance.
Tested:
Invoked resetOCC path explic
pldm: Add support for OCC reset
BMC initiated OCC reset is translated to a SetStateEffecterStates request for state effecter corresponding to the OCC instance.
Tested:
Invoked resetOCC path explicitly and verified that the SetStateEffecterStates request message for OCCReset is accurate.
Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com> Change-Id: I4e0d211b51151d24bf0112819fc9f201698bfac0
show more ...
|