VirtualBox

source: vbox/trunk/src/VBox/Devices/EFI/FirmwareNew/MdePkg/Library/BaseLib/X86GetInterruptState.c@ 108793

Last change on this file since 108793 was 99404, checked in by vboxsync, 2 years ago

Devices/EFI/FirmwareNew: Update to edk2-stable202302 and make it build, bugref:4643

  • Property svn:eol-style set to native
File size: 576 bytes
Line 
1/** @file
2 IA-32/x64 GetInterruptState()
3
4 Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
5 SPDX-License-Identifier: BSD-2-Clause-Patent
6
7**/
8
9#include "BaseLibInternals.h"
10
11/**
12 Retrieves the current CPU interrupt state.
13
14 Returns TRUE is interrupts are currently enabled. Otherwise
15 returns FALSE.
16
17 @retval TRUE CPU interrupts are enabled.
18 @retval FALSE CPU interrupts are disabled.
19
20**/
21BOOLEAN
22EFIAPI
23GetInterruptState (
24 VOID
25 )
26{
27 IA32_EFLAGS32 EFlags;
28
29 EFlags.UintN = AsmReadEflags ();
30 return (BOOLEAN)(1 == EFlags.Bits.IF);
31}
Note: See TracBrowser for help on using the repository browser.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette