FatPkg: Add RecoveryBlockIo2Ppi support
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Feng Tian <feng.tian@intel.com> Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com> (based on FatPkg commit add52adf722d2b0f1db4c8780a30289dacd59e02) [jordan.l.justen@intel.com: Use script to relicense to 2-clause BSD] Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Acked-by: Mark Doran <mark.doran@intel.com> Acked-by: Laszlo Ersek <lersek@redhat.com>
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
General purpose supporting routines for FAT recovery PEIM
|
||||
|
||||
Copyright (c) 2006 - 2013, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2015, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials are licensed and made available
|
||||
under the terms and conditions of the BSD License which accompanies this
|
||||
@@ -87,7 +87,17 @@ FatReadBlock (
|
||||
// Status = BlockDev->ReadFunc
|
||||
// (PrivateData->PeiServices, BlockDev->PhysicalDevNo, Lba, BufferSize, Buffer);
|
||||
//
|
||||
Status = BlockDev->BlockIo->ReadBlocks (
|
||||
if (BlockDev->BlockIo2 != NULL) {
|
||||
Status = BlockDev->BlockIo2->ReadBlocks (
|
||||
(EFI_PEI_SERVICES **) GetPeiServicesTablePointer (),
|
||||
BlockDev->BlockIo2,
|
||||
BlockDev->PhysicalDevNo,
|
||||
Lba,
|
||||
BufferSize,
|
||||
Buffer
|
||||
);
|
||||
} else {
|
||||
Status = BlockDev->BlockIo->ReadBlocks (
|
||||
(EFI_PEI_SERVICES **) GetPeiServicesTablePointer (),
|
||||
BlockDev->BlockIo,
|
||||
BlockDev->PhysicalDevNo,
|
||||
@@ -95,6 +105,7 @@ FatReadBlock (
|
||||
BufferSize,
|
||||
Buffer
|
||||
);
|
||||
}
|
||||
|
||||
} else {
|
||||
Status = FatReadDisk (
|
||||
|
Reference in New Issue
Block a user