]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Include/Protocol/FirmwareVolumeBlock.h
Code Scrub for Protocol and Ppi Definition
[mirror_edk2.git] / MdePkg / Include / Protocol / FirmwareVolumeBlock.h
index 275c16b91ca84ff57fb2562511cbe0a7ad014859..c7e0c2f769fac1bc370ecc66a77115b997152750 100644 (file)
@@ -1,7 +1,7 @@
 /** @file\r
   This file provides control over block-oriented firmware devices.\r
 \r
-  Copyright (c) 2006 - 2007, Intel Corporation                                                         \r
+  Copyright (c) 2006 - 2008, Intel Corporation                                                         \r
   All rights reserved. This program and the accompanying materials                          \r
   are licensed and made available under the terms and conditions of the BSD License         \r
   which accompanies this distribution.  The full text of the license may be found at        \r
@@ -29,8 +29,7 @@ typedef struct _EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL EFI_FIRMWARE_VOLUME_BLOCK_PRO
   The GetAttributes() function retrieves the attributes and\r
   current settings of the block. Status Codes Returned\r
 \r
-  @param This   Indicates the EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL\r
-                instance.\r
+  @param This       Indicates the EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL instance.\r
 \r
   @param Attributes Pointer to EFI_FVB_ATTRIBUTES in which the\r
                     attributes and current settings are\r
@@ -43,7 +42,7 @@ typedef struct _EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL EFI_FIRMWARE_VOLUME_BLOCK_PRO
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI * EFI_FVB_GET_ATTRIBUTES) (\r
+(EFIAPI * EFI_FVB_GET_ATTRIBUTES)(\r
   IN CONST  EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL  *This,\r
   OUT       EFI_FVB_ATTRIBUTES                  *Attributes\r
 );\r
@@ -53,8 +52,7 @@ EFI_STATUS
   The SetAttributes() function sets configurable firmware volume\r
   attributes and returns the new settings of the firmware volume.\r
 \r
-  @param This   Indicates the EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL\r
-                instance.\r
+  @param This         Indicates the EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL instance.\r
 \r
   @param Attributes   On input, Attributes is a pointer to\r
                       EFI_FVB_ATTRIBUTES that contains the\r
@@ -63,10 +61,8 @@ EFI_STATUS
                       settings of the firmware volume. Type\r
                       EFI_FVB_ATTRIBUTES is defined in\r
                       EFI_FIRMWARE_VOLUME_HEADER.\r
-\r
   \r
-  @retval EFI_SUCCESS The firmware volume attributes were\r
-                      returned.\r
+  @retval EFI_SUCCESS           The firmware volume attributes were returned.\r
 \r
   @retval EFI_INVALID_PARAMETER The attributes requested are in\r
                                 conflict with the capabilities\r
@@ -76,7 +72,7 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI * EFI_FVB_SET_ATTRIBUTES) (\r
+(EFIAPI * EFI_FVB_SET_ATTRIBUTES)(\r
   IN CONST  EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL  *This,\r
   IN OUT    EFI_FVB_ATTRIBUTES                  *Attributes\r
 );\r
@@ -87,27 +83,21 @@ EFI_STATUS
   a memory-mapped firmware volume. This function should be called\r
   only for memory-mapped firmware volumes.\r
 \r
-  @param This   Indicates the EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL\r
-                nstance.\r
+  @param This     Indicates the EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL instance.\r
   \r
   @param Address  Pointer to a caller-allocated\r
                   EFI_PHYSICAL_ADDRESS that, on successful\r
                   return from GetPhysicalAddress(), contains the\r
-                  base address of the firmware volume. Type\r
-                  EFI_PHYSICAL_ADDRESS is defined in\r
-                  AllocatePages() in the UEFI 2.0 specification.\r
+                  base address of the firmware volume.\r
   \r
-  @retval EFI_SUCCESS The firmware volume base address is\r
-                      returned.\r
+  @retval EFI_SUCCESS       The firmware volume base address is returned.\r
   \r
-  @retval EFI_NOT_SUPPORTED The firmware volume is not memory\r
-                            mapped.\r
-\r
+  @retval EFI_NOT_SUPPORTED The firmware volume is not memory mapped.\r
 \r
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI * EFI_FVB_GET_PHYSICAL_ADDRESS) (\r
+(EFIAPI * EFI_FVB_GET_PHYSICAL_ADDRESS)(\r
   IN CONST  EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL  *This,\r
   OUT       EFI_PHYSICAL_ADDRESS                *Address\r
 );\r
@@ -119,15 +109,12 @@ EFI_STATUS
   retrieve the block map (see EFI_FIRMWARE_VOLUME_HEADER).\r
 \r
 \r
-  @param This   Indicates the EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL\r
-                instance.\r
+  @param This           Indicates the EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL instance.\r
 \r
-  @param Lba  Indicates the block for which to return the size.\r
-              Type EFI_LBA is defined in the BLOCK_IO Protocol\r
-              (section 11.6) in the UEFI 2.0 specification.\r
+  @param Lba            Indicates the block for which to return the size.\r
 \r
-  @param BlockSize  Pointer to a caller-allocated UINTN in which\r
-                    the size of the block is returned.\r
+  @param BlockSize      Pointer to a caller-allocated UINTN in which\r
+                        the size of the block is returned.\r
 \r
   @param NumberOfBlocks Pointer to a caller-allocated UINTN in\r
                         which the number of consecutive blocks,\r
@@ -136,16 +123,14 @@ EFI_STATUS
                         BlockSize.\r
 \r
   \r
-  @retval EFI_SUCCESS The firmware volume base address is\r
-                      returned.\r
+  @retval EFI_SUCCESS             The firmware volume base address is returned.\r
   \r
-  @retval EFI_INVALID_PARAMETER   The requested LBA is out of\r
-                                  range.\r
+  @retval EFI_INVALID_PARAMETER   The requested LBA is out of range.\r
 \r
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI * EFI_FVB_GET_BLOCK_SIZE) (\r
+(EFIAPI * EFI_FVB_GET_BLOCK_SIZE)(\r
   IN CONST  EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL  *This,\r
   IN        EFI_LBA                             Lba,\r
   OUT       UINTN                               *BlockSize,\r
@@ -167,13 +152,12 @@ EFI_STATUS
   indicate the number of bytes actually read. The caller must be\r
   aware that a read may be partially completed.\r
 \r
-  @param This Indicates the EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL\r
-              instance. Lba The starting logical block index\r
-              from which to read. Type EFI_LBA is defined in the\r
-              BLOCK_IO Protocol (section 11.6) in the UEFI 2.0\r
-              specification.\r
+  @param This     Indicates the EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL instance.\r
+  \r
+  @param Lba      The starting logical block index\r
+                  from which to read.\r
 \r
-  @param Offset Offset into the block at which to begin reading.\r
+  @param Offset   Offset into the block at which to begin reading.\r
 \r
   @param NumBytes Pointer to a UINTN. At entry, *NumBytes\r
                   contains the total size of the buffer. At\r
@@ -183,8 +167,8 @@ EFI_STATUS
   @param Buffer   Pointer to a caller-allocated buffer that will\r
                   be used to hold the data that is read.\r
 \r
-  @retval EFI_SUCCESS The firmware volume was read successfully\r
-                      and contents are in Buffer.\r
+  @retval EFI_SUCCESS         The firmware volume was read successfully\r
+                              and contents are in Buffer.\r
   \r
   @retval EFI_BAD_BUFFER_SIZE Read attempted across an LBA\r
                               boundary. On output, NumBytes\r
@@ -201,7 +185,7 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_FVB_READ) (\r
+(EFIAPI *EFI_FVB_READ)(\r
   IN CONST  EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL  *This,\r
   IN        EFI_LBA                             Lba,\r
   IN        UINTN                               Offset,\r
@@ -209,8 +193,6 @@ EFI_STATUS
   IN OUT    UINT8                               *Buffer\r
 );\r
 \r
-\r
-\r
 /**\r
   The Write() function writes the specified number of bytes from\r
   the provided buffer to the specified block and offset. If the\r
@@ -239,25 +221,21 @@ EFI_STATUS
   fully flushed to the hardware before the Write() service\r
   returns.\r
 \r
-  @param This Indicates the EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL\r
-              instance.\r
+  @param This     Indicates the EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL instance.\r
   \r
-  @param Lba  The starting logical block index to write to. Type\r
-              EFI_LBA is defined in the BLOCK_IO Protocol\r
-              (section 11.6) in the UEFI 2.0 specification.\r
-              Offset Offset into the block at which to begin\r
-              writing.\r
+  @param Lba      The starting logical block index to write to.\r
+  \r
+  @param Offset   Offset into the block at which to begin writing.\r
   \r
   @param NumBytes Pointer to a UINTN. At entry, *NumBytes\r
                   contains the total size of the buffer. At\r
                   exit, *NumBytes contains the total number of\r
                   bytes actually written.\r
   \r
-  @param Buffer Pointer to a caller-allocated buffer that\r
-                contains the source for the write.\r
+  @param Buffer   Pointer to a caller-allocated buffer that\r
+                  contains the source for the write.\r
   \r
-  @retval EFI_SUCCESS The firmware volume was written\r
-                      successfully.\r
+  @retval EFI_SUCCESS         The firmware volume was written successfully.\r
   \r
   @retval EFI_BAD_BUFFER_SIZE The write was attempted across an\r
                               LBA boundary. On output, NumBytes\r
@@ -274,7 +252,7 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI * EFI_FVB_WRITE) (\r
+(EFIAPI * EFI_FVB_WRITE)(\r
   IN CONST  EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL  *This,\r
   IN        EFI_LBA                             Lba,\r
   IN        UINTN                               Offset,\r
@@ -339,7 +317,7 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI * EFI_FVB_ERASE_BLOCKS) (\r
+(EFIAPI * EFI_FVB_ERASE_BLOCKS)(\r
   IN CONST  EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL  *This,\r
   ...\r
 );\r
@@ -347,6 +325,7 @@ EFI_STATUS
 \r
 \r
 /**\r
+  @par Protocol Description:\r
   The Firmware Volume Block Protocol is the low-level interface\r
   to a firmware volume. File-level access to a firmware volume\r
   should not be done using the Firmware Volume Block Protocol.\r
@@ -372,40 +351,28 @@ EFI_STATUS
 \r
   @param GetPhysicalAddress   Retrieves the memory-mapped\r
                               address of the firmware volume.\r
-                              See the GetPhysicalAddress()\r
-                              function description. \r
 \r
   @param GetBlockSize   Retrieves the size for a specific block.\r
                         Also returns the number of consecutive\r
-                        similarly sized blocks. See the\r
-                        GetBlockSize() function description.\r
-\r
-  @param Read   Reads n bytes into a buffer from the firmware\r
-                volume hardware. See the Read() function\r
-                description.\r
-\r
-  @param Write  Writes n bytes from a buffer into the firmware\r
-                volume hardware. See the Write() function\r
-                description.\r
-\r
-  @param EraseBlocks  Erases specified block(s) and sets all\r
-                      values as indicated by the\r
-                      EFI_FVB_ERASE_POLARITY bit. See the\r
-                      EraseBlocks() function description. Type\r
-                      EFI_FVB_ERASE_POLARITY is defined in\r
-                      EFI_FIRMWARE_VOLUME_HEADER. ParentHandle\r
-                      Handle of the parent firmware volume. Type\r
-                      EFI_HANDLE is defined in\r
-                      InstallProtocolInterface() in the UEFI 2.0\r
-                      specification.\r
-  \r
-  @param GetAttributes Retrieves the current volume attributes.\r
-                       See the GetAttributes() function\r
-                       description.\r
+                        similarly sized blocks.\r
+\r
+  @param Read           Reads n bytes into a buffer from the firmware\r
+                        volume hardware.\r
+\r
+  @param Write          Writes n bytes from a buffer into the firmware\r
+                        volume hardware.\r
+\r
+  @param EraseBlocks    Erases specified block(s) and sets all\r
+                        values as indicated by the\r
+                        EFI_FVB_ERASE_POLARITY bit. See the\r
+                        EraseBlocks() function description. Type\r
+                        EFI_FVB_ERASE_POLARITY is defined in\r
+                        EFI_FIRMWARE_VOLUME_HEADER. ParentHandle\r
+                        Handle of the parent firmware volume.\r
   \r
-  @param SetAttributes Sets the current volume attributes. See\r
-                       the SetAttributes() function description.\r
+  @param GetAttributes  Retrieves the current volume attributes.\r
   \r
+  @param SetAttributes  Sets the current volume attributes.\r
 \r
 **/\r
 struct _EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL {\r