2 ; This is the assembly code for transferring to control to OS S3 waking vector
5 ; Copyright (c) 2006, Intel Corporation. All rights reserved.<BR>
7 ; This program and the accompanying materials
8 ; are licensed and made available under the terms and conditions of the BSD License
9 ; which accompanies this distribution. The full text of the license may be found at
10 ; http://opensource.org/licenses/bsd-license.php
12 ; THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
13 ; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
20 EXTERNDEF AsmFixAddress16:DWORD
21 EXTERNDEF AsmJmpAddr32:DWORD
23 ;-----------------------------------------
26 ; IN UINT32 S3WakingVector,
27 ; IN UINT32 AcpiLowMemoryBase
29 ;-----------------------------------------
31 AsmTransferControl PROC
32 ; S3WakingVector :DWORD
33 ; AcpiLowMemoryBase :DWORD
46 DB 0b8h, 30h, 0 ; mov ax, 30h as selector
52 mov eax, cr0 ; Get control register 0
54 DB 83h, 0e0h, 0feh ; and eax, 0fffffffeh ; Clear PE bit (bit #0)
55 DB 0fh, 22h, 0c0h ; mov cr0, eax ; Activate real mode
56 DB 0eah ; jmp far @jmp_addr
59 AsmTransferControl ENDP
61 AsmTransferControl32 PROC
62 jmp AsmTransferControl
63 AsmTransferControl32 ENDP
66 AsmTransferControl16 PROC
69 AsmTransferControl16 ENDP