2 PEI Reset System Library instance that calls the ResetSystem2() PEI Service.
4 Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved.<BR>
5 SPDX-License-Identifier: BSD-2-Clause-Patent
10 #include <Library/ResetSystemLib.h>
11 #include <Library/PeiServicesLib.h>
14 This function causes a system-wide reset (cold reset), in which
15 all circuitry within the system returns to its initial state. This type of reset
16 is asynchronous to system operation and operates without regard to
19 If this function returns, it means that the system does not support cold reset.
27 PeiServicesResetSystem2 (EfiResetCold
, EFI_SUCCESS
, 0, NULL
);
31 This function causes a system-wide initialization (warm reset), in which all processors
32 are set to their initial state. Pending cycles are not corrupted.
34 If this function returns, it means that the system does not support warm reset.
42 PeiServicesResetSystem2 (EfiResetWarm
, EFI_SUCCESS
, 0, NULL
);
46 This function causes the system to enter a power state equivalent
47 to the ACPI G2/S5 or G3 states.
49 If this function returns, it means that the system does not support shut down reset.
57 PeiServicesResetSystem2 (EfiResetShutdown
, EFI_SUCCESS
, 0, NULL
);
61 This function causes the system to enter S3 and then wake up immediately.
63 If this function returns, it means that the system does not support S3 feature.
67 EnterS3WithImmediateWake (
74 This function causes a systemwide reset. The exact type of the reset is
75 defined by the EFI_GUID that follows the Null-terminated Unicode string passed
76 into ResetData. If the platform does not recognize the EFI_GUID in ResetData
77 the platform must pick a supported reset type to perform.The platform may
78 optionally log the parameters from any non-normal reset that occurs.
80 @param[in] DataSize The size, in bytes, of ResetData.
81 @param[in] ResetData The data buffer starts with a Null-terminated string,
82 followed by the EFI_GUID.
86 ResetPlatformSpecific (
91 PeiServicesResetSystem2 (EfiResetPlatformSpecific
, EFI_SUCCESS
, DataSize
, ResetData
);
95 The ResetSystem function resets the entire platform.
97 @param[in] ResetType The type of reset to perform.
98 @param[in] ResetStatus The status code for the reset.
99 @param[in] DataSize The size, in bytes, of ResetData.
100 @param[in] ResetData For a ResetType of EfiResetCold, EfiResetWarm, or EfiResetShutdown
101 the data buffer starts with a Null-terminated string, optionally
102 followed by additional binary data. The string is a description
103 that the caller may use to further indicate the reason for the
104 system reset. ResetData is only valid if ResetStatus is something
105 other than EFI_SUCCESS unless the ResetType is EfiResetPlatformSpecific
106 where a minimum amount of ResetData is always required.
111 IN EFI_RESET_TYPE ResetType
,
112 IN EFI_STATUS ResetStatus
,
114 IN VOID
*ResetData OPTIONAL
117 PeiServicesResetSystem2 (ResetType
, ResetStatus
, DataSize
, ResetData
);