]> git.proxmox.com Git - mirror_edk2.git/blame - MdeModulePkg/Core/Pei/Reset/Reset.c
Removed CommonHeader.h from MdePkg & MdeModulePkg
[mirror_edk2.git] / MdeModulePkg / Core / Pei / Reset / Reset.c
CommitLineData
192f6d4c 1/*++\r
2\r
3Copyright (c) 2006, Intel Corporation \r
4All rights reserved. This program and the accompanying materials \r
5are licensed and made available under the terms and conditions of the BSD License \r
6which accompanies this distribution. The full text of the license may be found at \r
7http://opensource.org/licenses/bsd-license.php \r
8 \r
9THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
10WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
11\r
12Module Name:\r
13\r
14 Reset.c\r
15\r
16Abstract:\r
17\r
18 Pei Core Reset System Support\r
19\r
20Revision History\r
21\r
22--*/\r
23\r
192f6d4c 24#include <PeiMain.h>\r
25\r
26EFI_STATUS\r
27EFIAPI\r
28PeiResetSystem (\r
29 IN EFI_PEI_SERVICES **PeiServices\r
30 )\r
31/*++\r
32\r
33Routine Description:\r
34\r
35 Core version of the Reset System\r
36\r
37Arguments:\r
38\r
39 PeiServices - The PEI core services table.\r
40\r
41Returns:\r
42\r
43 Status - EFI_NOT_AVAILABLE_YET. PPI not available yet.\r
44 - EFI_DEVICE_ERROR. Did not reset system.\r
45 \r
46 Otherwise, resets the system. \r
47\r
48--*/\r
49{\r
50 EFI_STATUS Status;\r
51 EFI_PEI_RESET_PPI *ResetPpi;\r
52\r
53 Status = PeiServicesLocatePpi (\r
54 &gEfiPeiResetPpiGuid, \r
55 0, \r
56 NULL, \r
57 (VOID **)&ResetPpi \r
58 );\r
59\r
60 //\r
61 // LocatePpi returns EFI_NOT_FOUND on error\r
62 //\r
63 if (!EFI_ERROR (Status)) {\r
64 return ResetPpi->ResetSystem (PeiServices);\r
65 } \r
66 return EFI_NOT_AVAILABLE_YET;\r
67}\r
68\r