]>
git.proxmox.com Git - mirror_edk2.git/blob - OvmfPkg/Library/ResetSystemLib/ResetSystemLib.c
2 Reset System Library functions for OVMF
4 Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
5 This program and the accompanying materials
6 are licensed and made available under the terms and conditions of the BSD License
7 which accompanies this distribution. The full text of the license may be found at
8 http://opensource.org/licenses/bsd-license.php
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
17 #include <Library/BaseLib.h>
18 #include <Library/DebugLib.h>
19 #include <Library/IoLib.h>
26 ASSERT (SuspendType
< 6);
28 IoAndThenOr16 (0x404, ~0x3c00, SuspendType
<< 10);
29 IoOr16 (0x404, BIT13
);
34 Calling this function causes a system-wide reset. This sets
35 all circuitry within the system to its initial state. This type of reset
36 is asynchronous to system operation and operates without regard to
39 System reset should not return, if it returns, it means the system does
40 not support cold reset.
48 IoWrite8 (0x64, 0xfe);
52 Calling this function causes a system-wide initialization. The processors
53 are set to their initial state, and pending cycles are not corrupted.
55 System reset should not return, if it returns, it means the system does
56 not support warm reset.
64 IoWrite8 (0x64, 0xfe);
68 Calling this function causes the system to enter a power state equivalent
69 to the ACPI G2/S5 or G3 states.
71 System shutdown should not return, if it returns, it means the system does
72 not support shut down reset.
86 Calling this function causes the system to enter a power state for capsule
89 Reset update should not return, if it returns, it means the system does
90 not support capsule update.
95 EnterS3WithImmediateWake (