Skip to content

Commit

Permalink
ArmPkg/ArmPsciMpServices: Add EFI_NOT_READY return
Browse files Browse the repository at this point in the history
Add EFI_NOT_READY return if the CPU can not be enabled because the
processor is already on.

This can occur in normal use if the CPU is still being turned off from
a previous call when this is called again.

Signed-off-by: Jeff Brasen <[email protected]>
Reviewed-by: Rebecca Cran <[email protected]>
  • Loading branch information
Jeff Brasen via groups.io authored and mergify[bot] committed Oct 18, 2023
1 parent 772ec92 commit 01e1bc2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion ArmPkg/Drivers/ArmPsciMpServicesDxe/ArmPsciMpServicesDxe.c
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,9 @@ DispatchCpu (

ArmCallSmc (&Args);

if (Args.Arg0 != ARM_SMC_PSCI_RET_SUCCESS) {
if (Args.Arg0 == ARM_SMC_PSCI_RET_ALREADY_ON) {
Status = EFI_NOT_READY;
} else if (Args.Arg0 != ARM_SMC_PSCI_RET_SUCCESS) {
DEBUG ((DEBUG_ERROR, "PSCI_CPU_ON call failed: %d\n", Args.Arg0));
Status = EFI_DEVICE_ERROR;
}
Expand Down

0 comments on commit 01e1bc2

Please sign in to comment.