TianoCore EDK2 master
Loading...
Searching...
No Matches
EfiMpServiceProtocolDynamicCmdUnitTest.c
Go to the documentation of this file.
1
13
14CHAR16 *mMpProtocolUnitTestCommandHelp = L".TH MpProtocolUnitTest 0\r\n.SH NAME\r\nDisplay unit test results of EFI MP services protocol.\r\n";
15
17EFIAPI
19 VOID
20 );
21
36EFIAPI
39 IN EFI_SYSTEM_TABLE *SystemTable,
40 IN EFI_SHELL_PARAMETERS_PROTOCOL *ShellParameters,
42 )
43{
45}
46
57CHAR16 *
58EFIAPI
61 IN CONST CHAR8 *Language
62 )
63{
64 return AllocateCopyPool (StrSize (mMpProtocolUnitTestCommandHelp), mMpProtocolUnitTestCommandHelp);
65}
66
67EFI_SHELL_DYNAMIC_COMMAND_PROTOCOL mMpProtocolUnitTestDynamicCommand = {
68 L"MpProtocolUnitTest",
71};
72
86EFIAPI
88 IN EFI_HANDLE ImageHandle,
89 IN EFI_SYSTEM_TABLE *SystemTable
90 )
91{
92 EFI_STATUS Status;
93
94 Status = gBS->InstallProtocolInterface (
95 &ImageHandle,
96 &gEfiShellDynamicCommandProtocolGuid,
98 &mMpProtocolUnitTestDynamicCommand
99 );
100 ASSERT_EFI_ERROR (Status);
101
102 return Status;
103}
104
114EFIAPI
116 IN EFI_HANDLE ImageHandle
117 )
118{
119 EFI_STATUS Status;
120
121 Status = gBS->UninstallProtocolInterface (
122 ImageHandle,
123 &gEfiShellDynamicCommandProtocolGuid,
124 &mMpProtocolUnitTestDynamicCommand
125 );
126 ASSERT_EFI_ERROR (Status);
127
128 return Status;
129}
UINTN EFIAPI StrSize(IN CONST CHAR16 *String)
Definition: String.c:72
CHAR16 *EFIAPI MpProtocolUnitTestCommandGetHelp(IN EFI_SHELL_DYNAMIC_COMMAND_PROTOCOL *This, IN CONST CHAR8 *Language)
SHELL_STATUS EFIAPI MpProtocolUnitTestCommandHandler(IN EFI_SHELL_DYNAMIC_COMMAND_PROTOCOL *This, IN EFI_SYSTEM_TABLE *SystemTable, IN EFI_SHELL_PARAMETERS_PROTOCOL *ShellParameters, IN EFI_SHELL_PROTOCOL *Shell)
EFI_STATUS EFIAPI MpProtocolUnitTestCommandInitialize(IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable)
EFI_STATUS EFIAPI MpProtocolUnitTestUnload(IN EFI_HANDLE ImageHandle)
EFI_STATUS EFIAPI EfiMpServiceProtocolUnitTest(VOID)
VOID *EFIAPI AllocateCopyPool(IN UINTN AllocationSize, IN CONST VOID *Buffer)
#define CONST
Definition: Base.h:259
#define IN
Definition: Base.h:279
#define ASSERT_EFI_ERROR(StatusParameter)
Definition: DebugLib.h:462
SHELL_STATUS
Definition: Shell.h:21
RETURN_STATUS EFI_STATUS
Definition: UefiBaseType.h:29
VOID * EFI_HANDLE
Definition: UefiBaseType.h:33
EFI_BOOT_SERVICES * gBS
@ EFI_NATIVE_INTERFACE
Definition: UefiSpec.h:1193
EFI_SHELL_DYNAMIC_COMMAND_PROTOCOL protocol structure.