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

MdeModulePkg/Core/Dxe/FwVolBlock/FwVolBlock.h

Go to the documentation of this file.
00001 
00016 #ifndef _FWVOL_BLOCK_H_
00017 #define _FWVOL_BLOCK_H_
00018 
00019 
00020 #define FVB_DEVICE_SIGNATURE       SIGNATURE_32('_','F','V','B')
00021 
00022 
00023 typedef struct {
00024   UINTN                       Base;
00025   UINTN                       Length;
00026 } LBA_CACHE;
00027 
00028 typedef struct {
00029   MEMMAP_DEVICE_PATH          MemMapDevPath;
00030   EFI_DEVICE_PATH_PROTOCOL    EndDevPath;
00031 } FV_MEMMAP_DEVICE_PATH;
00032 
00033 //
00034 // UEFI Specification define FV device path format if FV provide name guid in extension header
00035 //
00036 typedef struct {
00037   MEDIA_FW_VOL_DEVICE_PATH    FvDevPath;
00038   EFI_DEVICE_PATH_PROTOCOL    EndDevPath;
00039 } FV_PIWG_DEVICE_PATH;
00040 
00041 typedef struct {
00042   UINTN                                 Signature;
00043   EFI_HANDLE                            Handle;
00044   EFI_DEVICE_PATH_PROTOCOL              *DevicePath;
00045   EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL    FwVolBlockInstance;
00046   UINTN                                 NumBlocks;
00047   LBA_CACHE                             *LbaCache;
00048   UINT32                                FvbAttributes;
00049   EFI_PHYSICAL_ADDRESS                  BaseAddress;
00050 } EFI_FW_VOL_BLOCK_DEVICE;
00051 
00052 
00053 #define FVB_DEVICE_FROM_THIS(a) \
00054   CR(a, EFI_FW_VOL_BLOCK_DEVICE, FwVolBlockInstance, FVB_DEVICE_SIGNATURE)
00055 
00056 
00066 EFI_STATUS
00067 EFIAPI
00068 FwVolBlockGetAttributes (
00069   IN CONST  EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL  *This,
00070   OUT       EFI_FVB_ATTRIBUTES_2                *Attributes
00071   );
00072 
00073 
00074 
00088 EFI_STATUS
00089 EFIAPI
00090 FwVolBlockSetAttributes (
00091   IN CONST  EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL  *This,
00092   IN CONST  EFI_FVB_ATTRIBUTES_2                *Attributes
00093   );
00094 
00095 
00096 
00120 EFI_STATUS
00121 EFIAPI
00122 FwVolBlockEraseBlock (
00123   IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL    *This,
00124   ...
00125   );
00126 
00127 
00128 
00149 EFI_STATUS
00150 EFIAPI
00151 FwVolBlockReadBlock (
00152   IN CONST  EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL   *This,
00153   IN CONST  EFI_LBA                              Lba,
00154   IN CONST  UINTN                                Offset,
00155   IN OUT    UINTN                                *NumBytes,
00156   IN OUT    UINT8                                *Buffer
00157   );
00158 
00159 
00160 
00185 EFI_STATUS
00186 EFIAPI
00187 FwVolBlockWriteBlock (
00188   IN     EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL   *This,
00189   IN     EFI_LBA                              Lba,
00190   IN     UINTN                                Offset,
00191   IN OUT UINTN                                *NumBytes,
00192   IN     UINT8                                *Buffer
00193   );
00194 
00195 
00196 
00207 EFI_STATUS
00208 EFIAPI
00209 FwVolBlockGetPhysicalAddress (
00210   IN CONST  EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL  *This,
00211   OUT       EFI_PHYSICAL_ADDRESS                *Address
00212   );
00213 
00214 
00215 
00233 EFI_STATUS
00234 EFIAPI
00235 FwVolBlockGetBlockSize (
00236   IN CONST  EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL  *This,
00237   IN CONST  EFI_LBA                             Lba,
00238   IN OUT    UINTN                               *BlockSize,
00239   IN OUT    UINTN                               *NumberOfBlocks
00240   );
00241 
00242 
00243 #endif
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Defines