+++ /dev/null
-/**@file\r
-\r
-Copyright (c) 2006, Intel Corporation. All rights reserved.<BR>\r
-This program and the accompanying materials \r
-are licensed and made available under the terms and conditions of the BSD License \r
-which accompanies this distribution. The full text of the license may be found at \r
-http://opensource.org/licenses/bsd-license.php \r
- \r
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
-\r
-Module Name:\r
-\r
- Reset.c\r
-\r
-Abstract:\r
-\r
- Reset Architectural Protocol as defined in Tiano under NT Emulation\r
-\r
-**/\r
-\r
-#include <Uefi.h>\r
-#include <WinNtDxe.h>\r
-#include <Protocol/Reset.h>\r
-#include <Library/DebugLib.h>\r
-#include <Library/UefiDriverEntryPoint.h>\r
-#include <Library/WinNtLib.h>\r
-#include <Library/UefiBootServicesTableLib.h>\r
-\r
-\r
-EFI_STATUS\r
-EFIAPI\r
-InitializeNtReset (\r
- IN EFI_HANDLE ImageHandle,\r
- IN EFI_SYSTEM_TABLE *SystemTable\r
- );\r
-\r
-VOID\r
-EFIAPI\r
-WinNtResetSystem (\r
- IN EFI_RESET_TYPE ResetType,\r
- IN EFI_STATUS ResetStatus,\r
- IN UINTN DataSize,\r
- IN VOID *ResetData OPTIONAL\r
- );\r
-\r
-\r
-EFI_STATUS\r
-EFIAPI\r
-InitializeNtReset (\r
- IN EFI_HANDLE ImageHandle,\r
- IN EFI_SYSTEM_TABLE *SystemTable\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-\r
-Arguments:\r
-\r
- ImageHandle of the loaded driver\r
- Pointer to the System Table\r
-\r
-Returns:\r
-\r
- Status\r
---*/\r
-// TODO: SystemTable - add argument and description to function comment\r
-{\r
- EFI_STATUS Status;\r
- EFI_HANDLE Handle;\r
-\r
- SystemTable->RuntimeServices->ResetSystem = WinNtResetSystem;\r
-\r
- Handle = NULL;\r
- Status = gBS->InstallMultipleProtocolInterfaces (\r
- &Handle,\r
- &gEfiResetArchProtocolGuid,\r
- NULL,\r
- NULL\r
- );\r
- ASSERT_EFI_ERROR (Status);\r
-\r
- return Status;\r
-}\r
-\r
-VOID\r
-EFIAPI\r
-WinNtResetSystem (\r
- IN EFI_RESET_TYPE ResetType,\r
- IN EFI_STATUS ResetStatus,\r
- IN UINTN DataSize,\r
- IN VOID *ResetData OPTIONAL\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
- TODO: Add function description\r
-\r
-Arguments:\r
-\r
- ResetType - TODO: add argument description\r
- ResetStatus - TODO: add argument description\r
- DataSize - TODO: add argument description\r
- ResetData - TODO: add argument description\r
-\r
-Returns:\r
-\r
- EFI_SUCCESS - TODO: Add description for return value\r
-\r
---*/\r
-{\r
- //\r
- // BUGBUG Need to kill all console windows later\r
- //\r
- //\r
- // Discard ResetType, always return 0 as exit code\r
- //\r
- gWinNt->ExitProcess (0);\r
-\r
- //\r
- // Should never go here\r
- //\r
- ASSERT (FALSE);\r
-}\r