From 97d92bdaf05d9307d494444cead97c41272eca62 Mon Sep 17 00:00:00 2001 From: bxing Date: Mon, 15 May 2006 11:14:20 +0000 Subject: Updated BaseLib for THUNK functions and some CPU functions git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@158 6f19259b-4bc3-4df7-8a09-765794883524 --- MdePkg/Library/BaseLib/Ipf/CpuBreakpoint.c | 18 ++++++++++++++++++ MdePkg/Library/BaseLib/Ipf/CpuPause.s | 25 +++++++++++++++++++++++++ 2 files changed, 43 insertions(+) create mode 100644 MdePkg/Library/BaseLib/Ipf/CpuPause.s (limited to 'MdePkg/Library/BaseLib/Ipf') diff --git a/MdePkg/Library/BaseLib/Ipf/CpuBreakpoint.c b/MdePkg/Library/BaseLib/Ipf/CpuBreakpoint.c index 987fc9c846..7923e92fa9 100644 --- a/MdePkg/Library/BaseLib/Ipf/CpuBreakpoint.c +++ b/MdePkg/Library/BaseLib/Ipf/CpuBreakpoint.c @@ -99,3 +99,21 @@ GetInterruptState ( { return FALSE; } + +/** + Enables CPU interrupts for the smallest window required to capture any + pending interrupts. + + Enables CPU interrupts for the smallest window required to capture any + pending interrupts. + +**/ +VOID +EFIAPI +EnableDisableInterrupts ( + VOID + ) +{ + EnableInterrupts (); + DisableInterrupts (); +} diff --git a/MdePkg/Library/BaseLib/Ipf/CpuPause.s b/MdePkg/Library/BaseLib/Ipf/CpuPause.s new file mode 100644 index 0000000000..f52692f438 --- /dev/null +++ b/MdePkg/Library/BaseLib/Ipf/CpuPause.s @@ -0,0 +1,25 @@ +/// @file +/// CpuPause() function for Itanium-based architecture. +/// +/// Copyright (c) 2006, Intel Corporation +/// All rights reserved. This program and the accompanying materials +/// are licensed and made available under the terms and conditions of the BSD License +/// which accompanies this distribution. The full text of the license may be found at +/// http://opensource.org/licenses/bsd-license.php +/// +/// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, +/// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. +/// +/// Module Name: CpuPause.s +/// +/// + +.auto +.text + +.proc CpuPause +.type CpuPause, @function +CpuPause:: + hint @pause + br.ret.sptk.many b0 +.endp -- cgit v1.2.3