mirror of https://github.com/acidanthera/audk.git
MdeModulePkg CapsulePei: Fix some typos
Cc: Jiewen Yao <jiewen.yao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
This commit is contained in:
parent
5e32460d80
commit
ed3ff1acb4
|
@ -1,6 +1,6 @@
|
|||
/** @file
|
||||
|
||||
Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
|
@ -119,10 +119,8 @@ typedef union {
|
|||
typedef
|
||||
EFI_STATUS
|
||||
(*COALESCE_ENTRY) (
|
||||
IN EFI_PEI_SERVICES **PeiServices,
|
||||
IN EFI_CAPSULE_BLOCK_DESCRIPTOR *BlockList,
|
||||
IN OUT VOID **MemoryBase,
|
||||
IN OUT UINTN *MemorySize
|
||||
SWITCH_32_TO_64_CONTEXT *EntrypointContext,
|
||||
SWITCH_64_TO_32_CONTEXT *ReturnContext
|
||||
);
|
||||
|
||||
#endif
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
into memory.
|
||||
|
||||
(C) Copyright 2014 Hewlett-Packard Development Company, L.P.<BR>
|
||||
Copyright (c) 2011 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2011 - 2016, 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 distribution. The full text of the license may be found at
|
||||
|
@ -1034,7 +1034,7 @@ CapsuleDataCoalesce (
|
|||
PrivateData.CapsuleNumber = (UINT64) CapsuleNumber;
|
||||
PrivateData.CapsuleOffset[0] = 0;
|
||||
//
|
||||
// NOTE: Only data in sizeof (EFI_CAPSULE_PEIM_PRIVATE_DATA) is valid, CapsuleOffset field is unitialized at this moment.
|
||||
// NOTE: Only data in sizeof (EFI_CAPSULE_PEIM_PRIVATE_DATA) is valid, CapsuleOffset field is uninitialized at this moment.
|
||||
// The code sets partial length here for Descriptor.Length check, but later it will use full length to reserve those PrivateData region.
|
||||
//
|
||||
PrivateDataDesc[0].Union.DataBlock = (EFI_PHYSICAL_ADDRESS) (UINTN) &PrivateData;
|
||||
|
@ -1042,12 +1042,12 @@ CapsuleDataCoalesce (
|
|||
PrivateDataDesc[1].Union.DataBlock = (EFI_PHYSICAL_ADDRESS) (UINTN) BlockList;
|
||||
PrivateDataDesc[1].Length = 0;
|
||||
//
|
||||
// Add PrivateDataDesc[0] in beginning beginning, as it is new descriptor. PrivateDataDesc[1] is NOT needed.
|
||||
// Add PrivateDataDesc[0] in beginning, as it is new descriptor. PrivateDataDesc[1] is NOT needed.
|
||||
// In addition, one NULL terminator is added in the end. See RelocateBlockDescriptors().
|
||||
//
|
||||
NumDescriptors += 2;
|
||||
//
|
||||
// Sandity check
|
||||
// Sanity check
|
||||
//
|
||||
if (CapsuleSize >= (MAX_ADDRESS - (sizeof (EFI_CAPSULE_PEIM_PRIVATE_DATA) + (CapsuleNumber - 1) * sizeof(UINT64) + sizeof(UINT64)))) {
|
||||
DEBUG ((EFI_D_ERROR, "ERROR: CapsuleSize - 0x%x\n", CapsuleSize));
|
||||
|
@ -1059,7 +1059,7 @@ CapsuleDataCoalesce (
|
|||
CapsuleSize += sizeof (EFI_CAPSULE_PEIM_PRIVATE_DATA) + (CapsuleNumber - 1) * sizeof(UINT64) + sizeof(UINT64);
|
||||
BlockList = PrivateDataDesc;
|
||||
//
|
||||
// Sandity check
|
||||
// Sanity check
|
||||
//
|
||||
if (NumDescriptors >= (MAX_ADDRESS / sizeof(EFI_CAPSULE_BLOCK_DESCRIPTOR))) {
|
||||
DEBUG ((EFI_D_ERROR, "ERROR: NumDescriptors - 0x%x\n", NumDescriptors));
|
||||
|
@ -1067,7 +1067,7 @@ CapsuleDataCoalesce (
|
|||
}
|
||||
DescriptorsSize = NumDescriptors * sizeof (EFI_CAPSULE_BLOCK_DESCRIPTOR);
|
||||
//
|
||||
// Sandity check
|
||||
// Sanity check
|
||||
//
|
||||
if (DescriptorsSize >= (MAX_ADDRESS - CapsuleSize)) {
|
||||
DEBUG ((EFI_D_ERROR, "ERROR: DescriptorsSize - 0x%lx, CapsuleSize - 0x%lx\n", (UINT64)DescriptorsSize, (UINT64)CapsuleSize));
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/** @file
|
||||
Capsule update PEIM for UEFI2.0
|
||||
|
||||
Copyright (c) 2006 - 2015, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
|
@ -1006,7 +1006,7 @@ CreateState (
|
|||
CopyMem ((VOID *) (UINTN) NewBuffer, (VOID *) (UINTN) ((UINT8 *)PrivateData + sizeof(EFI_CAPSULE_PEIM_PRIVATE_DATA) + (CapsuleNumber - 1) * sizeof(UINT64)), Size);
|
||||
//
|
||||
// Check for test data pattern. If it is the test pattern, then we'll
|
||||
// test it ans still create the HOB so that it can be used to verify
|
||||
// test it and still create the HOB so that it can be used to verify
|
||||
// that capsules don't get corrupted all the way into BDS. BDS will
|
||||
// still try to turn it into a firmware volume, but will think it's
|
||||
// corrupted so nothing will happen.
|
||||
|
|
Loading…
Reference in New Issue