EDK2 doxygen online documents - Firmware Encoding Index 1
EDK2 doxygen online documents - Firmware Encoding Index

EdkCompatibilityPkg/Foundation/Efi/Protocol/AcpiTable/AcpiTable.h

Go to the documentation of this file.
00001 /*++
00002 
00003 Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
00004 This program and the accompanying materials                          
00005 are licensed and made available under the terms and conditions of the BSD License         
00006 which accompanies this distribution.  The full text of the license may be found at        
00007 http://opensource.org/licenses/bsd-license.php                                            
00008                                                                                           
00009 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
00010 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
00011 
00012 Module Name:
00013 
00014   AcpiTable.h
00015 
00016 Abstract:
00017 
00018   ACPI Table Protocol from the UEFI 2.1 specification.
00019 
00020   This protocol may be used to install or remove an ACPI table from a platform.
00021 
00022 --*/
00023 
00024 #ifndef __ACPI_TABLE_H__
00025 #define __ACPI_TABLE_H__
00026 
00027 #include "Acpi.h"
00028 
00029 //
00030 // Global ID for the Acpi Table Protocol
00031 //
00032 #define EFI_ACPI_TABLE_PROTOCOL_GUID \
00033   { \
00034     0xffe06bdd, 0x6107, 0x46a6, {0x7b, 0xb2, 0x5a, 0x9c, 0x7e, 0xc5, 0x27, 0x5c} \
00035   }
00036 
00037 EFI_FORWARD_DECLARATION (EFI_ACPI_TABLE_PROTOCOL);
00038 
00039 #define UEFI_ACPI_TABLE_SIGNATURE    EFI_SIGNATURE_32 ('U', 'E', 'F', 'I')
00040 
00041 #pragma pack(1)
00042 
00043 typedef struct {
00044   EFI_ACPI_DESCRIPTION_HEADER  Header;
00045   EFI_GUID                     Identifier;
00046   UINT16                       DataOffset;
00047 } EFI_ACPI_TABLE;
00048 
00049 #pragma pack()
00050 
00051 typedef
00052 EFI_STATUS
00053 (EFIAPI *EFI_ACPI_TABLE_INSTALL_ACPI_TABLE) (
00054   IN EFI_ACPI_TABLE_PROTOCOL                    *This,
00055   IN VOID                                       *AcpiTableBuffer,
00056   IN UINTN                                      AcpiTableBufferSize,
00057   OUT UINTN                                     *TableKey
00058   )
00059 /*++
00060 
00061   Routine Description:
00062     Installs an ACPI table into the RSDT/XSDT.
00063 
00064   Arguments:
00065     This                  - Protocol instance pointer.
00066     AcpiTableBuffer       - A pointer to a buffer containing the ACPI table to be installed.
00067     AcpiTableBufferSize   - Specifies the size, in bytes, of the AcpiTableBuffer buffer.
00068     TableKey              - Reurns a key to refer to the ACPI table.
00069 
00070   Returns:
00071     EFI_SUCCESS           - The table was successfully inserted.
00072     EFI_INVALID_PARAMETER - Either AcpiTableBuffer is NULL, TableKey is NULL, or AcpiTableBufferSize 
00073                             and the size field embedded in the ACPI table pointed to by AcpiTableBuffer
00074                             are not in sync.
00075     EFI_OUT_OF_RESOURCES  - Insufficient resources exist to complete the request.
00076 
00077 --*/
00078 ;
00079 
00080 typedef
00081 EFI_STATUS
00082 (EFIAPI *EFI_ACPI_TABLE_UNINSTALL_ACPI_TABLE) (
00083   IN EFI_ACPI_TABLE_PROTOCOL                    *This,
00084   IN UINTN                                      TableKey
00085   )
00086 /*++
00087 
00088   Routine Description:
00089     Removes an ACPI table from the RSDT/XSDT.
00090 
00091   Arguments:
00092     This          - Protocol instance pointer.
00093     TableKey      - Specifies the table to uninstall.  The key was returned from InstallAcpiTable().
00094 
00095   Returns:
00096     EFI_SUCCESS   - The table was successfully uninstalled.
00097     EFI_NOT_FOUND - TableKey does not refer to a valid key for a table entry.
00098 
00099 --*/
00100 ;
00101 
00102 //
00103 // Interface structure for the ACPI Table Protocol
00104 //
00105 struct _EFI_ACPI_TABLE_PROTOCOL {
00106   EFI_ACPI_TABLE_INSTALL_ACPI_TABLE    InstallAcpiTable;
00107   EFI_ACPI_TABLE_UNINSTALL_ACPI_TABLE  UninstallAcpiTable;
00108 };
00109 
00110 extern EFI_GUID gEfiAcpiTableProtocolGuid;
00111 
00112 #endif
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Defines