]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Include/Guid/SmmVariableCommon.h
MdeModulePkg SmiHandlerProfile: Use fixed data type in data structure
[mirror_edk2.git] / MdeModulePkg / Include / Guid / SmmVariableCommon.h
index e92ab7fe79a6f8c18c8678a4672a4d91798e081f..734eb19681e14e7be758a9cca7d5f0210a89d5cd 100644 (file)
@@ -2,12 +2,12 @@
   The file defined some common structures used for communicating between SMM variable module and SMM variable wrapper module.\r
 \r
 Copyright (c) 2011 - 2015, Intel Corporation. All rights reserved.<BR>\r
-This program and the accompanying materials are licensed and made available under \r
-the terms and conditions of the BSD License that accompanies this distribution.  \r
+This program and the accompanying materials are licensed and made available under\r
+the terms and conditions of the BSD License that accompanies this distribution.\r
 The full text of the license may be found at\r
-http://opensource.org/licenses/bsd-license.php.                                            \r
+http://opensource.org/licenses/bsd-license.php.\r
 \r
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
 **/\r
@@ -23,8 +23,8 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 extern EFI_GUID gSmmVariableWriteGuid;\r
 \r
 //\r
-// This structure is used for SMM variable. the collected statistics data is saved in SMRAM. It can be got from \r
-// SMI handler. The communication buffer should be: \r
+// This structure is used for SMM variable. the collected statistics data is saved in SMRAM. It can be got from\r
+// SMI handler. The communication buffer should be:\r
 // EFI_SMM_COMMUNICATE_HEADER + SMM_VARIABLE_COMMUNICATE_HEADER + payload.\r
 //\r
 typedef struct {\r
@@ -39,26 +39,26 @@ typedef struct {
 #define SMM_VARIABLE_FUNCTION_GET_VARIABLE            1\r
 //\r
 // The payload for this function is SMM_VARIABLE_COMMUNICATE_GET_NEXT_VARIABLE_NAME.\r
-// \r
+//\r
 #define SMM_VARIABLE_FUNCTION_GET_NEXT_VARIABLE_NAME  2\r
 //\r
 // The payload for this function is SMM_VARIABLE_COMMUNICATE_ACCESS_VARIABLE.\r
-// \r
+//\r
 #define SMM_VARIABLE_FUNCTION_SET_VARIABLE            3\r
 //\r
 // The payload for this function is SMM_VARIABLE_COMMUNICATE_QUERY_VARIABLE_INFO.\r
-// \r
+//\r
 #define SMM_VARIABLE_FUNCTION_QUERY_VARIABLE_INFO     4\r
 //\r
 // It is a notify event, no extra payload for this function.\r
-// \r
+//\r
 #define SMM_VARIABLE_FUNCTION_READY_TO_BOOT           5\r
 //\r
 // It is a notify event, no extra payload for this function.\r
-// \r
+//\r
 #define SMM_VARIABLE_FUNCTION_EXIT_BOOT_SERVICE       6\r
 //\r
-// The payload for this function is VARIABLE_INFO_ENTRY. The GUID in EFI_SMM_COMMUNICATE_HEADER \r
+// The payload for this function is VARIABLE_INFO_ENTRY. The GUID in EFI_SMM_COMMUNICATE_HEADER\r
 // is gEfiSmmVariableProtocolGuid.\r
 //\r
 #define SMM_VARIABLE_FUNCTION_GET_STATISTICS          7\r
@@ -71,6 +71,8 @@ typedef struct {
 \r
 #define SMM_VARIABLE_FUNCTION_VAR_CHECK_VARIABLE_PROPERTY_GET  10\r
 \r
+#define SMM_VARIABLE_FUNCTION_GET_PAYLOAD_SIZE        11\r
+\r
 ///\r
 /// Size of SMM communicate header, without including the payload.\r
 ///\r
@@ -88,7 +90,7 @@ typedef struct {
   EFI_GUID    Guid;\r
   UINTN       DataSize;\r
   UINTN       NameSize;\r
-  UINT32      Attributes;  \r
+  UINT32      Attributes;\r
   CHAR16      Name[1];\r
 } SMM_VARIABLE_COMMUNICATE_ACCESS_VARIABLE;\r
 \r
@@ -108,7 +110,7 @@ typedef struct {
   UINT64          MaximumVariableStorageSize;\r
   UINT64          RemainingVariableStorageSize;\r
   UINT64          MaximumVariableSize;\r
-  UINT32          Attributes; \r
+  UINT32          Attributes;\r
 } SMM_VARIABLE_COMMUNICATE_QUERY_VARIABLE_INFO;\r
 \r
 typedef SMM_VARIABLE_COMMUNICATE_GET_NEXT_VARIABLE_NAME SMM_VARIABLE_COMMUNICATE_LOCK_VARIABLE;\r
@@ -120,4 +122,8 @@ typedef struct {
   CHAR16                        Name[1];\r
 } SMM_VARIABLE_COMMUNICATE_VAR_CHECK_VARIABLE_PROPERTY;\r
 \r
-#endif // _SMM_VARIABLE_COMMON_H_
\ No newline at end of file
+typedef struct {\r
+  UINTN                         VariablePayloadSize;\r
+} SMM_VARIABLE_COMMUNICATE_GET_PAYLOAD_SIZE;\r
+\r
+#endif // _SMM_VARIABLE_COMMON_H_\r