aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHaojian Zhuang <haojian.zhuang@outlook.com>2016-08-25 18:32:29 +0800
committerGitHub <noreply@github.com>2016-08-25 18:32:29 +0800
commit8db281ab86a8e1e7087fc7fa44e1156b4036b1a2 (patch)
tree8d898db7f99a610ade8432f1dfe55f89117f5dd7
parentc4dd1326b07c3b5e9e98e5b5e95309025955769d (diff)
parent5c6d7125889bbbf8fe8b331f62ece749829fec9b (diff)
downloadOpenPlatformPkg-8db281ab86a8e1e7087fc7fa44e1156b4036b1a2.tar.gz
Merge pull request #32 from 96boards-hikey/revert-31-hikey-aosp
Revert "HiKeyFastboot.c: add support for sparse image with CHUNK_TYPE_FILL"
-rw-r--r--Platforms/Hisilicon/HiKey/HiKeyFastbootDxe/HiKeyFastboot.c22
1 files changed, 0 insertions, 22 deletions
diff --git a/Platforms/Hisilicon/HiKey/HiKeyFastbootDxe/HiKeyFastboot.c b/Platforms/Hisilicon/HiKey/HiKeyFastbootDxe/HiKeyFastboot.c
index 61292bf..7dafa19 100644
--- a/Platforms/Hisilicon/HiKey/HiKeyFastbootDxe/HiKeyFastboot.c
+++ b/Platforms/Hisilicon/HiKey/HiKeyFastbootDxe/HiKeyFastboot.c
@@ -363,7 +363,6 @@ HiKeyFastbootPlatformFlashPartition (
CHUNK_HEADER *ChunkHeader;
UINTN Offset = 0;
UINT32 Chunk, EntrySize, EntryOffset;
- UINT32 *FillVal, TmpCount, FillBuf[1024];
VOID *Buffer;
@@ -470,27 +469,6 @@ HiKeyFastbootPlatformFlashPartition (
}
Image+=WriteSize;
break;
- case CHUNK_TYPE_FILL:
- //Assume fillVal is 0, and we can skip here
- FillVal = (UINT32 *)Image;
- Image += sizeof(UINT32);
- if (*FillVal != 0){
- mTextOut->OutputString(mTextOut, OutputString);
- for(TmpCount = 0; TmpCount < 1024; TmpCount++){
- FillBuf[TmpCount] = *FillVal;
- }
- for (TmpCount= 0; TmpCount < WriteSize; TmpCount += sizeof(FillBuf)) {
- if ((WriteSize - TmpCount) < sizeof(FillBuf)) {
- Status = DiskIo->WriteDisk (DiskIo, MediaId, Offset + TmpCount, WriteDisk - TmpCount, FillBuf);
- } else {
- Status = DiskIo->WriteDisk (DiskIo, MediaId, Offset + TmpCount, sizeof(FillBuf), FillBuf);
- }
- if (EFI_ERROR (Status)) {
- return Status;
- }
- }
- }
- break;
case CHUNK_TYPE_DONT_CARE:
break;
case CHUNK_TYPE_CRC32: