TianoCore EDK2 master
Loading...
Searching...
No Matches
MockUefiBootServicesTableLib.h
Go to the documentation of this file.
1
8#ifndef MOCK_UEFI_BOOT_SERVICES_TABLE_LIB_H_
9#define MOCK_UEFI_BOOT_SERVICES_TABLE_LIB_H_
10
13extern "C" {
14 #include <Uefi.h>
16}
17
18//
19// Declarations to handle usage of the UefiBootServiceTableLib by creating mock
20//
22 MOCK_INTERFACE_DECLARATION (MockUefiBootServicesTableLib);
23
24 MOCK_FUNCTION_DECLARATION (
26 gBS_GetMemoryMap,
27 (IN OUT UINTN *MemoryMapSize,
28 OUT EFI_MEMORY_DESCRIPTOR *MemoryMap,
29 OUT UINTN *MapKey,
30 OUT UINTN *DescriptorSize,
31 OUT UINT32 *DescriptorVersion)
32 );
33
34 MOCK_FUNCTION_DECLARATION (
36 gBS_CreateEvent,
37 (IN UINT32 Type,
38 IN EFI_TPL NotifyTpl,
40 IN VOID *NotifyContext,
41 OUT EFI_EVENT *Event)
42 );
43
44 MOCK_FUNCTION_DECLARATION (
46 gBS_CloseEvent,
47 (IN EFI_EVENT Event)
48 );
49
50 MOCK_FUNCTION_DECLARATION (
52 gBS_HandleProtocol,
53 (IN EFI_HANDLE Handle,
54 IN EFI_GUID *Protocol,
55 OUT VOID **Interface)
56 );
57
58 MOCK_FUNCTION_DECLARATION (
60 gBS_LocateProtocol,
61 (IN EFI_GUID *Protocol,
62 IN VOID *Registration OPTIONAL,
63 OUT VOID **Interface)
64 );
65
66 MOCK_FUNCTION_DECLARATION (
68 gBS_CreateEventEx,
69 (IN UINT32 Type,
70 IN EFI_TPL NotifyTpl,
72 IN CONST VOID *NotifyContext OPTIONAL,
73 IN CONST EFI_GUID *EventGroup OPTIONAL,
74 OUT EFI_EVENT *Event)
75 );
76};
77
78#endif // MOCK_UEFI_BOOT_SERVICES_TABLE_LIB_H_
UINT64 UINTN
#define CONST
Definition: Base.h:259
#define IN
Definition: Base.h:279
#define OUT
Definition: Base.h:284
VOID EFIAPI NotifyFunction(IN EFI_EVENT Event, IN VOID *Context)
Definition: ScsiBus.c:1492
RETURN_STATUS EFI_STATUS
Definition: UefiBaseType.h:29
VOID * EFI_EVENT
Definition: UefiBaseType.h:37
UINTN EFI_TPL
Definition: UefiBaseType.h:41
VOID * EFI_HANDLE
Definition: UefiBaseType.h:33
VOID(EFIAPI * EFI_EVENT_NOTIFY)(IN EFI_EVENT Event, IN VOID *Context)
Definition: UefiSpec.h:463
Definition: Base.h:213