Changeset 77662 in vbox for trunk/src/VBox/Devices/EFI/FirmwareNew/OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FvbInfo.c
- Timestamp:
- Mar 12, 2019 12:40:12 PM (6 years ago)
- Location:
- trunk/src/VBox/Devices/EFI/FirmwareNew
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/EFI/FirmwareNew
-
Property svn:mergeinfo
changed from (toggle deleted branches)
to (toggle deleted branches)/vendor/edk2/current 103735-103757,103769-103776 /vendor/edk2/current 103735-103757,103769-103776,129194-129237
-
Property svn:mergeinfo
changed from (toggle deleted branches)
-
trunk/src/VBox/Devices/EFI/FirmwareNew/OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FvbInfo.c
r58466 r77662 1 1 /**@file 2 2 3 Copyright (c) 2006, Intel Corporation. All rights reserved.<BR> 4 This program and the accompanying materials 5 are licensed and made available under the terms and conditions of the BSD License 6 which accompanies this distribution. The full text of the license may be found at 7 http://opensource.org/licenses/bsd-license.php 3 Copyright (c) 2006, Intel Corporation. All rights reserved.<BR> 8 4 9 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, 10 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. 5 This program and the accompanying materials are licensed and made available 6 under the terms and conditions of the BSD License which accompanies this 7 distribution. The full text of the license may be found at 8 http://opensource.org/licenses/bsd-license.php 11 9 12 Module Name: 10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, 11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. 13 12 14 FvbInfo.c13 Module Name: 15 14 16 Abstract: 15 FvbInfo.c 17 16 18 Defines data structure that is the volume header found.These data is intent 19 to decouple FVB driver with FV header. 17 Abstract: 18 19 Defines data structure that is the volume header found.These data is intent 20 to decouple FVB driver with FV header. 20 21 21 22 **/ … … 24 25 // The package level header files this module uses 25 26 // 26 #include <PiDxe.h> 27 #include <Pi/PiFirmwareVolume.h> 28 27 29 // 28 30 // The protocols, PPI and GUID defintions for this module 29 31 // 30 #include <Guid/EventGroup.h>31 #include <Guid/FirmwareFileSystem2.h>32 32 #include <Guid/SystemNvDataGuid.h> 33 #include <Protocol/FirmwareVolumeBlock.h>34 #include <Protocol/DevicePath.h>35 33 // 36 34 // The Library classes this module consumes 37 35 // 38 #include <Library/UefiLib.h>39 #include <Library/UefiDriverEntryPoint.h>40 36 #include <Library/BaseLib.h> 41 #include <Library/DxeServicesTableLib.h>42 #include <Library/UefiRuntimeLib.h>43 #include <Library/DebugLib.h>44 #include <Library/HobLib.h>45 #include <Library/BaseMemoryLib.h>46 #include <Library/MemoryAllocationLib.h>47 #include <Library/UefiBootServicesTableLib.h>48 37 #include <Library/PcdLib.h> 49 38 … … 95 84 FixedPcdGet32 (PcdFlashNvStorageFtwWorkingSize) + 96 85 FixedPcdGet32 (PcdFlashNvStorageFtwSpareSize) + 97 FixedPcdGet32 (PcdOvmfFlashNvStorageEventLogSize)) / FixedPcdGet32 (PcdOvmfFirmwareBlockSize), 86 FixedPcdGet32 (PcdOvmfFlashNvStorageEventLogSize)) / 87 FixedPcdGet32 (PcdOvmfFirmwareBlockSize), 98 88 FixedPcdGet32 (PcdOvmfFirmwareBlockSize), 99 89 } … … 119 109 120 110 if (!Checksummed) { 121 for (Index = 0; Index < sizeof (mPlatformFvbMediaInfo) / sizeof (EFI_FVB_MEDIA_INFO); Index += 1) { 111 for (Index = 0; 112 Index < sizeof (mPlatformFvbMediaInfo) / sizeof (EFI_FVB_MEDIA_INFO); 113 Index += 1) { 122 114 UINT16 Checksum; 123 115 mPlatformFvbMediaInfo[Index].FvbInfo.Checksum = 0; … … 131 123 } 132 124 133 for (Index = 0; Index < sizeof (mPlatformFvbMediaInfo) / sizeof (EFI_FVB_MEDIA_INFO); Index += 1) { 125 for (Index = 0; 126 Index < sizeof (mPlatformFvbMediaInfo) / sizeof (EFI_FVB_MEDIA_INFO); 127 Index += 1) { 134 128 if (mPlatformFvbMediaInfo[Index].FvLength == FvLength) { 135 129 *FvbInfo = &mPlatformFvbMediaInfo[Index].FvbInfo;
Note:
See TracChangeset
for help on using the changeset viewer.