4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync This file declares Section Extraction Protocol.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync This interface provides a means of decoding a set of sections into a linked list of
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync leaf sections. This provides for an extensible and flexible file format.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncCopyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncThis program and the accompanying materials are licensed and made available under
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncthe terms and conditions of the BSD License that accompanies this distribution.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncThe full text of the license may be found at
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncTHE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncWITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @par Revision Reference:
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync This protocol is defined in Firmware Volume Specification.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Version 0.9.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync// Protocol GUID definition
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync 0x448F5DA4, 0x6DD7, 0x4FE1, {0x93, 0x07, 0x69, 0x22, 0x41, 0x92, 0x21, 0x5D } \
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsynctypedef struct _EFI_SECTION_EXTRACTION_PROTOCOL EFI_SECTION_EXTRACTION_PROTOCOL;
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync// Protocol member functions
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Creates and returns a new section stream handle to represent the new section stream.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param This Indicates the EFI_SECTION_EXTRACTION_PROTOCOL instance.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param SectionStreamLength The size in bytes of the section stream.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param SectionStream A buffer containing the new section stream.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param SectionStreamHandle A pointer to a caller-allocated UINTN that,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync on output, contains the new section stream handle.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @retval EFI_SUCCESS The SectionStream was successfully processed, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the section stream handle was returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @retval EFI_OUT_OF_RESOURCES The system has insufficient resources to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync process the request.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @retval EFI_INVALID_PARAMETER The section stream may be corrupt or the value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync of SectionStreamLength may be incorrect.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads and returns a single section from a section stream.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param This Indicates the EFI_SECTION_EXTRACTION_PROTOCOL instance.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param SectionStreamHandle Indicates from which section stream to read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param SectionType The pointer to an EFI_SECTION_TYPE. If SectionType == NULL,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the contents of the entire section stream are returned
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync in Buffer. If SectionType is not NULL, only the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync requested section is returned. EFI_SECTION_ALL
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync matches all section types and can be used as a
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync wild card to extract all sections in order.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param SectionDefinitionGuid The pointer to an EFI_GUID. If SectionType ==
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync EFI_SECTION_GUID_DEFINED, SectionDefinitionGuid
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync indicates what section GUID to search for. If
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync SectionType !=EFI_SECTION_GUID_DEFINED, then
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync SectionDefinitionGuid is unused and is ignored.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param SectionInstance Indicates which instance of the requested section
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync type to return when SectionType is not NULL.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param SectionStreamHandle A pointer to a caller-allocated UINTN that, on output,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync contains the new section stream handle.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Buffer Pointer to a pointer to a buffer in which the section
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync contents are returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param BufferSize A pointer to a caller-allocated UINTN.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AuthenticationStatus A pointer to a caller-allocated UINT32 in
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync which any meta-data from encapsulation GUID-defined
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync sections is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @retval EFI_SUCCESS The SectionStream was successfully processed and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the section contents were returned in Buffer.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @retval EFI_PROTOCOL_ERROR A GUID-defined section was encountered inthe section
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync stream with its EFI_GUIDED_SECTION_PROCESSING_REQUIRED
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync bit set, but there was no corresponding GUIDed
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Section Extraction Protocol in the handle database.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @retval EFI_NOT_FOUND An error was encountered when parsing the SectionStream,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync which indicates that the SectionStream is not
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync correctly formatted. Or, the requested section does not exist.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @retval EFI_OUT_OF_RESOURCES The system has insufficient resources to process
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the request.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @retval EFI_INVALID_PARAMETER The SectionStreamHandle does not exist.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @retval EFI_WARN_BUFFER_TOO_SMALL The size of the input buffer is insufficient
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync to contain the requested section. The input
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync buffer is filled and section contents are truncated.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Deletes a section stream handle and returns all associated resources to the system.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param This Indicates the EFI_SECTION_EXTRACTION_PROTOCOL instance.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param SectionStreamHandle Indicates the section stream to close.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @retval EFI_SUCCESS The SectionStream was successfully processed and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the section stream handle was returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @retval EFI_INVALID_PARAMETER The SectionStreamHandle does not exist.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync// Protocol definition
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync /// Takes a bounded stream of sections and returns a section stream handle.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync /// Given a section stream handle, retrieves the requested section and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync /// meta-data from the section stream.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync /// Given a section stream handle, closes the section stream.