TianoCore EDK2 master
Loading...
Searching...
No Matches
UnitTestHost.c File Reference
#include "UnitTestHost.h"

Go to the source code of this file.

Functions

VOID EFIAPI UnitTestHostBaseLibEnableInterrupts (VOID)
 
VOID EFIAPI UnitTestHostBaseLibDisableInterrupts (VOID)
 
VOID EFIAPI UnitTestHostBaseLibEnableDisableInterrupts (VOID)
 
BOOLEAN EFIAPI UnitTestHostBaseLibGetInterruptState (VOID)
 
VOID EFIAPI EnableInterrupts (VOID)
 
VOID EFIAPI DisableInterrupts (VOID)
 
VOID EFIAPI EnableDisableInterrupts (VOID)
 
BOOLEAN EFIAPI GetInterruptState (VOID)
 

Variables

STATIC BOOLEAN mUnitTestHostBaseLibInterruptState
 

Detailed Description

Common Unit Test Host functions.

Copyright (c) 2020, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent

Definition in file UnitTestHost.c.

Function Documentation

◆ DisableInterrupts()

VOID EFIAPI DisableInterrupts ( VOID  )

Disables CPU interrupts.

Definition at line 98 of file UnitTestHost.c.

◆ EnableDisableInterrupts()

VOID EFIAPI EnableDisableInterrupts ( VOID  )

Enables CPU interrupts for the smallest window required to capture any pending interrupts.

Definition at line 112 of file UnitTestHost.c.

◆ EnableInterrupts()

VOID EFIAPI EnableInterrupts ( VOID  )

Enables CPU interrupts.

Definition at line 85 of file UnitTestHost.c.

◆ GetInterruptState()

BOOLEAN EFIAPI GetInterruptState ( VOID  )

Set the current CPU interrupt state.

Sets the current CPU interrupt state to the state specified by InterruptState. If InterruptState is TRUE, then interrupts are enabled. If InterruptState is FALSE, then interrupts are disabled. InterruptState is returned.

Parameters
InterruptStateTRUE if interrupts should enabled. FALSE if interrupts should be disabled.
Returns
InterruptState

Definition at line 135 of file UnitTestHost.c.

◆ UnitTestHostBaseLibDisableInterrupts()

VOID EFIAPI UnitTestHostBaseLibDisableInterrupts ( VOID  )

Disables CPU interrupts.

Definition at line 35 of file UnitTestHost.c.

◆ UnitTestHostBaseLibEnableDisableInterrupts()

VOID EFIAPI UnitTestHostBaseLibEnableDisableInterrupts ( VOID  )

Enables CPU interrupts for the smallest window required to capture any pending interrupts.

Definition at line 49 of file UnitTestHost.c.

◆ UnitTestHostBaseLibEnableInterrupts()

VOID EFIAPI UnitTestHostBaseLibEnableInterrupts ( VOID  )

Enables CPU interrupts.

Definition at line 22 of file UnitTestHost.c.

◆ UnitTestHostBaseLibGetInterruptState()

BOOLEAN EFIAPI UnitTestHostBaseLibGetInterruptState ( VOID  )

Set the current CPU interrupt state.

Sets the current CPU interrupt state to the state specified by InterruptState. If InterruptState is TRUE, then interrupts are enabled. If InterruptState is FALSE, then interrupts are disabled. InterruptState is returned.

Parameters
InterruptStateTRUE if interrupts should enabled. FALSE if interrupts should be disabled.
Returns
InterruptState

Definition at line 72 of file UnitTestHost.c.

Variable Documentation

◆ mUnitTestHostBaseLibInterruptState

STATIC BOOLEAN mUnitTestHostBaseLibInterruptState

Module global variable for simple system emulation of interrupt state

Definition at line 14 of file UnitTestHost.c.