3 Copyright (c) 2004 - 2006, Intel Corporation
4 All rights reserved. This program and the accompanying materials
5 are licensed and made available under the terms and conditions of the BSD License
6 which accompanies this distribution. The full text of the license may be found at
7 http://opensource.org/licenses/bsd-license.php
9 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
19 Base Library CPU Functions for all architectures.
23 #include "BaseLibInternals.h"
26 Disables CPU interrupts and returns the interrupt state prior to the disable
29 Disables CPU interrupts and returns the interrupt state prior to the disable
32 @retval TRUE CPU interrupts were enabled on entry to this call.
33 @retval FALSE CPU interrupts were disabled on entry to this call.
38 SaveAndDisableInterrupts (
42 BOOLEAN InterruptState
;
44 InterruptState
= GetInterruptState ();
46 return InterruptState
;
50 Set the current CPU interrupt state.
52 Sets the current CPU interrupt state to the state specified by
53 InterruptState. If InterruptState is TRUE, then interrupts are enabled. If
54 InterruptState is FALSE, then interrupts are disabled. InterruptState is
57 @param InterruptState TRUE if interrupts should enabled. FALSE if
58 interrupts should be disabled.
60 @return InterruptState
66 IN BOOLEAN InterruptState
74 return InterruptState
;