]>
Commit | Line | Data |
---|---|---|
1 | /** @file\r | |
2 | System reset Library Services. This library class defines a set of\r | |
3 | methods that reset the whole system.\r | |
4 | \r | |
5 | Copyright (c) 2005 - 2019, Intel Corporation. All rights reserved.<BR>\r | |
6 | SPDX-License-Identifier: BSD-2-Clause-Patent\r | |
7 | \r | |
8 | **/\r | |
9 | \r | |
10 | #ifndef __RESET_SYSTEM_LIB_H__\r | |
11 | #define __RESET_SYSTEM_LIB_H__\r | |
12 | \r | |
13 | #include <Uefi/UefiBaseType.h>\r | |
14 | #include <Uefi/UefiMultiPhase.h>\r | |
15 | \r | |
16 | /**\r | |
17 | This function causes a system-wide reset (cold reset), in which\r | |
18 | all circuitry within the system returns to its initial state. This type of reset\r | |
19 | is asynchronous to system operation and operates without regard to\r | |
20 | cycle boundaries.\r | |
21 | \r | |
22 | If this function returns, it means that the system does not support cold reset.\r | |
23 | **/\r | |
24 | VOID\r | |
25 | EFIAPI\r | |
26 | ResetCold (\r | |
27 | VOID\r | |
28 | );\r | |
29 | \r | |
30 | /**\r | |
31 | This function causes a system-wide initialization (warm reset), in which all processors\r | |
32 | are set to their initial state. Pending cycles are not corrupted.\r | |
33 | \r | |
34 | If this function returns, it means that the system does not support warm reset.\r | |
35 | **/\r | |
36 | VOID\r | |
37 | EFIAPI\r | |
38 | ResetWarm (\r | |
39 | VOID\r | |
40 | );\r | |
41 | \r | |
42 | /**\r | |
43 | This function causes the system to enter a power state equivalent\r | |
44 | to the ACPI G2/S5 or G3 states.\r | |
45 | \r | |
46 | If this function returns, it means that the system does not support shutdown reset.\r | |
47 | **/\r | |
48 | VOID\r | |
49 | EFIAPI\r | |
50 | ResetShutdown (\r | |
51 | VOID\r | |
52 | );\r | |
53 | \r | |
54 | /**\r | |
55 | This function causes the system to enter S3 and then wake up immediately.\r | |
56 | \r | |
57 | If this function returns, it means that the system does not support S3 feature.\r | |
58 | **/\r | |
59 | VOID\r | |
60 | EFIAPI\r | |
61 | EnterS3WithImmediateWake (\r | |
62 | VOID\r | |
63 | );\r | |
64 | \r | |
65 | /**\r | |
66 | This function causes a systemwide reset. The exact type of the reset is\r | |
67 | defined by the EFI_GUID that follows the Null-terminated Unicode string passed\r | |
68 | into ResetData. If the platform does not recognize the EFI_GUID in ResetData\r | |
69 | the platform must pick a supported reset type to perform.The platform may\r | |
70 | optionally log the parameters from any non-normal reset that occurs.\r | |
71 | \r | |
72 | @param[in] DataSize The size, in bytes, of ResetData.\r | |
73 | @param[in] ResetData The data buffer starts with a Null-terminated string,\r | |
74 | followed by the EFI_GUID.\r | |
75 | **/\r | |
76 | VOID\r | |
77 | EFIAPI\r | |
78 | ResetPlatformSpecific (\r | |
79 | IN UINTN DataSize,\r | |
80 | IN VOID *ResetData\r | |
81 | );\r | |
82 | \r | |
83 | /**\r | |
84 | The ResetSystem function resets the entire platform.\r | |
85 | \r | |
86 | @param[in] ResetType The type of reset to perform.\r | |
87 | @param[in] ResetStatus The status code for the reset.\r | |
88 | @param[in] DataSize The size, in bytes, of ResetData.\r | |
89 | @param[in] ResetData For a ResetType of EfiResetCold, EfiResetWarm, or EfiResetShutdown\r | |
90 | the data buffer starts with a Null-terminated string, optionally\r | |
91 | followed by additional binary data. The string is a description\r | |
92 | that the caller may use to further indicate the reason for the\r | |
93 | system reset. ResetData is only valid if ResetStatus is something\r | |
94 | other than EFI_SUCCESS unless the ResetType is EfiResetPlatformSpecific\r | |
95 | where a minimum amount of ResetData is always required.\r | |
96 | **/\r | |
97 | VOID\r | |
98 | EFIAPI\r | |
99 | ResetSystem (\r | |
100 | IN EFI_RESET_TYPE ResetType,\r | |
101 | IN EFI_STATUS ResetStatus,\r | |
102 | IN UINTN DataSize,\r | |
103 | IN VOID *ResetData OPTIONAL\r | |
104 | );\r | |
105 | \r | |
106 | #endif\r |