Skip to content

Commit

Permalink
PHAL: mpreboot- exit with failure if no functional processor found
Browse files Browse the repository at this point in the history
On some special cases noticed DeviceTree was returning no
functional processor when queried.

As there are no functional processors present MPreboot was
not performed and no error/PEL was created to notify the user.
Rather the method was exiting with SUCCESS.

Now modified to log an error message and create a PEL if
no functional processors are found to perform MPReboot.

openpower-proc-control[3663]: Starting memory preserving reboot
openpower-proc-control[3663]: EnterMPReboot is not executed on any
processors
phosphor-log-manager[320]: Event not found in PEL message registry:
org.open_power.Processor.Error.MemoryPreservingReboot
phosphor-log-manager[320]: Created PEL 0x50014017 (BMC ID 750) with SRC BD752004

Signed-off-by: Marri Devender Rao <[email protected]>
Change-Id: Id781fc1bc9fac869c96c29562f62260c1a7c909d
  • Loading branch information
devenrao committed Jun 11, 2022
1 parent ae663a0 commit 62c8c93
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions procedures/phal/enter_mpreboot.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,14 @@ void enterMpReboot()
}
}

// if no functional proc found exit with failure
if (pidList.size() == 0)
{
log<level::ERR>("EnterMPReboot is not executed on any processors");
openpower::pel::createPEL("org.open_power.PHAL.Error.MPReboot");
std::exit(EXIT_FAILURE);
}

for (auto& p : pidList)
{
int status = 0;
Expand Down

0 comments on commit 62c8c93

Please sign in to comment.