]> git.proxmox.com Git - mirror_edk2.git/blob - EdkCompatibilityPkg/Compatibility/Include/Guid/SmmBaseThunkCommunication.h
Add 4 Framework/PI SMM thunk drivers. Combined use of these drivers can support usage...
[mirror_edk2.git] / EdkCompatibilityPkg / Compatibility / Include / Guid / SmmBaseThunkCommunication.h
1 /** @file
2 GUID and data structures for communication between SMM Base on SMM Base2 Thunk driver
3 and SmmBaseHelper driver.
4
5 Copyright (c) 2009, Intel Corporation
6 All rights reserved. This program and the accompanying materials
7 are licensed and made available under the terms and conditions of the BSD License
8 which accompanies this distribution. The full text of the license may be found at
9 http://opensource.org/licenses/bsd-license.php
10
11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
12 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
13
14 **/
15 #ifndef _SMM_BASE_THUNK_COMMUNICATION_H_
16 #define _SMM_BASE_THUNK_COMMUNICATION_H_
17
18 #include <Protocol/SmmBase.h>
19
20 #define EFI_SMM_BASE_THUNK_COMMUNICATION_GUID \
21 { 0x6568a3d6, 0x15f, 0x4b4a, { 0x9c, 0x89, 0x1d, 0x14, 0x63, 0x14, 0x13, 0xa } }
22
23 typedef struct {
24 EFI_DEVICE_PATH_PROTOCOL *FilePath;
25 VOID *SourceBuffer;
26 UINTN SourceSize;
27 EFI_HANDLE *ImageHandle;
28 BOOLEAN LegacyIA32Binary;
29 } SMMBASE_REGISTER_ARG;
30
31 typedef struct {
32 EFI_HANDLE ImageHandle;
33 } SMMBASE_UNREGISTER_ARG;
34
35 typedef struct {
36 EFI_HANDLE SmmImageHandle;
37 EFI_SMM_CALLBACK_ENTRY_POINT CallbackAddress;
38 BOOLEAN MakeLast;
39 BOOLEAN FloatingPointSave;
40 } SMMBASE_REGISTER_CALLBACK_ARG;
41
42 typedef struct {
43 EFI_MEMORY_TYPE PoolType;
44 UINTN Size;
45 VOID **Buffer;
46 } SMMBASE_ALLOCATE_POOL_ARG;
47
48 typedef struct {
49 VOID *Buffer;
50 } SMMBASE_FREE_POOL_ARG;
51
52 typedef union {
53 SMMBASE_REGISTER_ARG Register;
54 SMMBASE_UNREGISTER_ARG UnRegister;
55 SMMBASE_REGISTER_CALLBACK_ARG RegisterCallback;
56 SMMBASE_ALLOCATE_POOL_ARG AllocatePool;
57 SMMBASE_FREE_POOL_ARG FreePool;
58 } SMMBASE_FUNCTION_ARGS;
59
60 typedef enum {
61 SMMBASE_REGISTER,
62 SMMBASE_UNREGISTER,
63 SMMBASE_REGISTER_CALLBACK,
64 SMMBASE_ALLOCATE_POOL,
65 SMMBASE_FREE_POOL,
66 } SMMBASE_FUNCTION;
67
68 typedef struct {
69 SMMBASE_FUNCTION Function;
70 EFI_STATUS Status;
71 SMMBASE_FUNCTION_ARGS Args;
72 } SMMBASE_FUNCTION_DATA;
73
74 #pragma pack(1)
75 typedef struct {
76 EFI_GUID HeaderGuid;
77 UINTN MessageLength;
78 SMMBASE_FUNCTION_DATA FunctionData;
79 } SMMBASETHUNK_COMMUNICATION_DATA;
80 #pragma pack()
81
82 extern EFI_GUID gEfiSmmBaseThunkCommunicationGuid;
83
84 #endif
85