2 Implementation of SetJump() on IA-32.
4 Copyright (c) 2006 - 2007, Intel Corporation<BR>
5 All rights reserved. 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.
16 // Include common header file for this module.
18 #include <BaseLibInternals.h>
21 Worker function that checks ASSERT condition for JumpBuffer
23 Checks ASSERT condition for JumpBuffer.
25 If JumpBuffer is NULL, then ASSERT().
26 For IPF CPUs, if JumpBuffer is not aligned on a 16-byte boundary, then ASSERT().
28 @param JumpBuffer A pointer to CPU context buffer.
33 InternalAssertJumpBuffer (
34 IN BASE_LIBRARY_JUMP_BUFFER
*JumpBuffer
38 Saves the current CPU context that can be restored with a call to LongJump()
41 Saves the current CPU context in the buffer specified by JumpBuffer and
42 returns 0. The initial call to SetJump() must always return 0. Subsequent
43 calls to LongJump() cause a non-zero value to be returned by SetJump().
45 If JumpBuffer is NULL, then ASSERT().
46 For IPF CPUs, if JumpBuffer is not aligned on a 16-byte boundary, then ASSERT().
48 @param JumpBuffer A pointer to CPU context buffer.
50 @retval 0 Indicates a return from SetJump().
57 OUT BASE_LIBRARY_JUMP_BUFFER
*JumpBuffer
62 call InternalAssertJumpBuffer