+/** @file\r
+\r
+Copyright (c) 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
+The full text of the license may be found at\r
+http://opensource.org/licenses/bsd-license.php. \r
+ \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
+\r
+#ifndef _PI_SMM_COMMUNICATION_REGION_TABLE_H_\r
+#define _PI_SMM_COMMUNICATION_REGION_TABLE_H_\r
+\r
+#define EDKII_PI_SMM_COMMUNICATION_REGION_TABLE_GUID {\\r
+ 0x4e28ca50, 0xd582, 0x44ac, {0xa1, 0x1f, 0xe3, 0xd5, 0x65, 0x26, 0xdb, 0x34} \\r
+}\r
+\r
+//\r
+// This table to declare the generic SMM communication buffer location.\r
+// If this table is present, it means the SMM communication buffer is restricted to\r
+// EfiReservedMemoryType, EfiACPIMemoryNVS, or EfiRuntimeServicesData.\r
+//\r
+// This table is installed to UEFI configuration table by generic driver\r
+// or platform driver, at early DXE phase.\r
+// \r
+// The EFI_MEMORY_DESCRIPTOR entry must contain at least one entry.\r
+// The entries must be normal memory region in EfiReservedMemoryType, EfiACPIMemoryNVS,\r
+// or EfiRuntimeServicesData.\r
+// If the Entry.Type is EfiConventionalMemory, it means this entry is free to use.\r
+// If the Entry.Type is other, it means this entry is occupied.\r
+//\r
+// Any non-SMM component may put communication data there, then use \r
+// UEFI defined SMM Communication ACPI Table, or PI defined EFI_SMM_COMMUNICATION_PROTOCOL\r
+// to communicate with SMI handler. The process is:\r
+// 1) Find an entry whose type is EfiConventional.\r
+// 2) Change type to be EfiReservedMemoryType before use.\r
+// 3) Use it.\r
+// 4) Restore type be EfiConventional.\r
+// The step 2) must be performed as an atomic transaction, if there might be conflict during runtime.\r
+// For example, on IA-32/x64 platforms, this can be done using the CMPXCHG CPU instruction.\r
+// If there is guarantee on no conflict during boot time, these steps can be skipped.\r
+// For example, DXE, UEFI driver and UEFI application runs in sequence.\r
+//\r
+// For example, FPDT driver can use this communication buffer to get SMM\r
+// performance data in SMM. Profile driver can use this communication buffer\r
+// to get SMM profile data in SMM.\r
+//\r
+typedef struct {\r
+ UINT32 Version;\r
+ UINT32 NumberOfEntries;\r
+ UINT32 DescriptorSize;\r
+ UINT32 Reserved;\r
+//EFI_MEMORY_DESCRIPTOR Entry[1];\r
+} EDKII_PI_SMM_COMMUNICATION_REGION_TABLE;\r
+\r
+#define EDKII_PI_SMM_COMMUNICATION_REGION_TABLE_VERSION 0x00000001\r
+\r
+extern EFI_GUID gEdkiiPiSmmCommunicationRegionTableGuid;\r
+\r
+#endif\r