]>
Commit | Line | Data |
---|---|---|
9e620719 | 1 | /** @file\r |
2 | Include file for SMM Base Helper SMM driver.\r | |
3 | \r | |
4 | Copyright (c) 2009, Intel Corporation\r | |
5 | All rights reserved. This program and the accompanying materials\r | |
6 | are licensed and made available under the terms and conditions of the BSD License\r | |
7 | which accompanies this distribution. The full text of the license may be found at\r | |
8 | http://opensource.org/licenses/bsd-license.php\r | |
9 | \r | |
10 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r | |
11 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r | |
12 | \r | |
13 | **/\r | |
14 | \r | |
15 | #ifndef _SMM_BASE_HELPER_H_\r | |
16 | #define _SMM_BASE_HELPER_H_\r | |
17 | \r | |
18 | #include <PiSmm.h>\r | |
19 | #include <Library/DebugLib.h>\r | |
20 | #include <Library/UefiBootServicesTableLib.h>\r | |
21 | #include <Library/SmmServicesTableLib.h>\r | |
22 | #include <Library/BaseLib.h>\r | |
23 | #include <Library/BaseMemoryLib.h>\r | |
24 | #include <Library/PeCoffLib.h>\r | |
25 | #include <Library/DevicePathLib.h>\r | |
26 | #include <Library/CacheMaintenanceLib.h>\r | |
27 | #include <Guid/SmmBaseThunkCommunication.h>\r | |
28 | #include <Protocol/SmmBaseHelperReady.h>\r | |
29 | #include <Protocol/SmmCpu.h>\r | |
30 | #include <Protocol/LoadedImage.h>\r | |
d338a721 | 31 | #include "CpuSaveState.h"\r |
9e620719 | 32 | \r |
33 | ///\r | |
34 | /// Structure for tracking paired information of registered Framework SMI handler\r | |
35 | /// and correpsonding dispatch handle for SMI handler thunk.\r | |
36 | ///\r | |
37 | typedef struct {\r | |
38 | LIST_ENTRY Link;\r | |
39 | EFI_HANDLE DispatchHandle;\r | |
40 | EFI_HANDLE SmmImageHandle;\r | |
41 | EFI_SMM_CALLBACK_ENTRY_POINT CallbackAddress;\r | |
42 | } CALLBACK_INFO;\r | |
43 | \r | |
44 | typedef struct {\r | |
45 | ///\r | |
46 | /// PI SMM CPU Save State register index\r | |
47 | ///\r | |
48 | EFI_SMM_SAVE_STATE_REGISTER Register;\r | |
49 | ///\r | |
50 | /// Offset in Framework SMST\r | |
51 | ///\r | |
52 | UINTN Offset;\r | |
53 | } CPU_SAVE_STATE_CONVERSION;\r | |
54 | \r | |
55 | #define CPU_SAVE_STATE_GET_OFFSET(Field) (UINTN)(&(((EFI_SMM_CPU_SAVE_STATE *) 0)->Ia32SaveState.Field))\r | |
56 | \r | |
57 | #endif \r |