1# 2# Copyright (c) 2011, 2012, ARM Limited. All rights reserved. 3# Copyright (c) 2015, Hisilicon Limited. All rights reserved. 4# Copyright (c) 2015, Linaro Limited. All rights reserved. 5# 6# This program and the accompanying materials 7# are licensed and made available under the terms and conditions of the BSD License 8# which accompanies this distribution. The full text of the license may be found at 9# http://opensource.org/licenses/bsd-license.php 10# 11# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, 12# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. 13# 14 15[DEFINES] 16 17################################################################################ 18# 19# FD Section 20# The [FD] Section is made up of the definition statements and a 21# description of what goes into the Flash Device Image. Each FD section 22# defines one flash "device" image. A flash device image may be one of 23# the following: Removable media bootable image (like a boot floppy 24# image,) an Option ROM image (that would be "flashed" into an add-in 25# card,) a System "Flash" image (that would be burned into a system's 26# flash) or an Update ("Capsule") image that will be used to update and 27# existing system flash. 28# 29################################################################################ 30 31[FD.D03] 32BaseAddress = 0xA4800000|gArmTokenSpaceGuid.PcdFdBaseAddress # The base address of the Firmware in NOR Flash. 33 34Size = 0x00300000|gArmTokenSpaceGuid.PcdFdSize # The size in bytes of the FLASH Device 35ErasePolarity = 1 36 37# This one is tricky, it must be: BlockSize * NumBlocks = Size 38BlockSize = 0x00010000 39NumBlocks = 0x30 40 41################################################################################ 42# 43# Following are lists of FD Region layout which correspond to the locations of different 44# images within the flash device. 45# 46# Regions must be defined in ascending order and may not overlap. 47# 48# A Layout Region start with a eight digit hex offset (leading "0x" required) followed by 49# the pipe "|" character, followed by the size of the region, also in hex with the leading 50# "0x" characters. Like: 51# Offset|Size 52# PcdOffsetCName|PcdSizeCName 53# RegionType <FV, DATA, or FILE> 54# 55################################################################################ 56 570x00000000|0x00040000 58gArmTokenSpaceGuid.PcdSecureFvBaseAddress|gArmTokenSpaceGuid.PcdSecureFvSize 59FILE = OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Sec/FVMAIN_SEC.Fv 60 610x00040000|0x00240000 62gArmTokenSpaceGuid.PcdFvBaseAddress|gArmTokenSpaceGuid.PcdFvSize 63FV = FVMAIN_COMPACT 64 650x00280000|0x00020000 66gHisiTokenSpaceGuid.PcdTrustedFirmwareBL1Base 67FILE = OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/bl1.bin 680x002A0000|0x00020000 69FILE = OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/fip.bin 70 710x002D0000|0x0000E000 72gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase|gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize 73DATA = { 74 ## This is the EFI_FIRMWARE_VOLUME_HEADER 75 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 76 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 77 # FileSystemGuid: gEfiSystemNvDataFvGuid = 78 0x8D, 0x2B, 0xF1, 0xFF, 0x96, 0x76, 0x8B, 0x4C, 79 0xA9, 0x85, 0x27, 0x47, 0x07, 0x5B, 0x4F, 0x50, 80 # FvLength: 0x20000 81 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 82 #Signature "_FVH" #Attributes 83 0x5f, 0x46, 0x56, 0x48, 0xff, 0xfe, 0x04, 0x00, 84 #HeaderLength #CheckSum #ExtHeaderOffset #Reserved #Revision 85 0x48, 0x00, 0x36, 0x09, 0x00, 0x00, 0x00, 0x02, 86 #Blockmap[0]: 2 Blocks * 0x10000 Bytes / Block 87 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 88 #Blockmap[1]: End 89 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 90 ## This is the VARIABLE_STORE_HEADER gEfiVariableGuid 91 0x16, 0x36, 0xcf, 0xdd, 0x75, 0x32, 0x64, 0x41, 92 0x98, 0xb6, 0xfe, 0x85, 0x70, 0x7f, 0xfe, 0x7d, 93 #Size: 0xe000 (gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize) - 0x48 (size of EFI_FIRMWARE_VOLUME_HEADER) = 0xdFB8 94 0xB8, 0xdF, 0x00, 0x00, 95 #FORMATTED: 0x5A #HEALTHY: 0xFE #Reserved: UINT16 #Reserved1: UINT32 96 0x5A, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 97} 98 990x002DE000|0x00002000 100gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingBase|gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingSize 101#NV_FTW_WORKING 102DATA = { 103 # EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER->Signature = gEdkiiWorkingBlockSignatureGuid = 104 0x2B, 0x29, 0x58, 0x9E, 0x68, 0x7C, 0x7D, 0x49, 105 0xA0, 0xCE, 0x65, 0x0 , 0xFD, 0x9F, 0x1B, 0x95, 106 # Crc:UINT32 #WorkingBlockValid:1, WorkingBlockInvalid:1, Reserved 107 0xE2, 0x33, 0xF2, 0x03, 0xFE, 0xFF, 0xFF, 0xFF, 108 # WriteQueueSize: UINT64 #Size: 0x2000 - 0x20 (FTW_WORKING_HEADER) = 0x1FE0 109 0xE0, 0x1F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 110} 111 1120x002E0000|0x00010000 113gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareBase|gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize 114 1150x002F0000|0x00010000 116FILE = OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/CustomData.Fv 117 118################################################################################ 119# 120# FV Section 121# 122# [FV] section is used to define what components or modules are placed within a flash 123# device file. This section also defines order the components and modules are positioned 124# within the image. The [FV] section consists of define statements, set statements and 125# module statements. 126# 127################################################################################ 128 129[FV.FvMain] 130BlockSize = 0x40 131NumBlocks = 0 # This FV gets compressed so make it just big enough 132FvAlignment = 16 # FV alignment and FV attributes setting. 133ERASE_POLARITY = 1 134MEMORY_MAPPED = TRUE 135STICKY_WRITE = TRUE 136LOCK_CAP = TRUE 137LOCK_STATUS = TRUE 138WRITE_DISABLED_CAP = TRUE 139WRITE_ENABLED_CAP = TRUE 140WRITE_STATUS = TRUE 141WRITE_LOCK_CAP = TRUE 142WRITE_LOCK_STATUS = TRUE 143READ_DISABLED_CAP = TRUE 144READ_ENABLED_CAP = TRUE 145READ_STATUS = TRUE 146READ_LOCK_CAP = TRUE 147READ_LOCK_STATUS = TRUE 148 149 INF MdeModulePkg/Core/Dxe/DxeMain.inf 150 INF MdeModulePkg/Universal/PCD/Dxe/Pcd.inf 151 152 INF OpenPlatformPkg/Chips/Hisilicon/Hi1610/Drivers/IoInitDxe/IoInitDxe.inf 153 # 154 # PI DXE Drivers producing Architectural Protocols (EFI Services) 155 # 156 INF ArmPkg/Drivers/CpuDxe/CpuDxe.inf 157 INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf 158 159 INF MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf 160 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/SFC/SfcDxeDriver.inf 161 162 INF OpenPlatformPkg/Platforms/Hisilicon/D03/Drivers/OemNicConfig2PHi1610/OemNicConfig2P.inf 163 164 165 INF OpenPlatformPkg/Chips/Hisilicon/Drivers/FlashFvbDxe/FlashFvbDxe.inf 166 INF MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf 167 INF MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf 168 169 INF MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf 170 INF EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf 171 172 INF EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf 173 INF EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf 174 INF EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf 175 176 INF MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf 177 178 # 179 # Multiple Console IO support 180 # 181 INF MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatformDxe.inf 182 INF MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf 183 INF MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf 184 INF MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf 185 INF MdeModulePkg/Universal/SerialDxe/SerialDxe.inf 186 187 # Simple TextIn/TextOut for UEFI Terminal 188 189 INF ArmPkg/Drivers/ArmGic/ArmGicDxe.inf 190 INF ArmPkg/Drivers/TimerDxe/TimerDxe.inf 191 192 INF ArmPlatformPkg/Drivers/SP805WatchdogDxe/SP805WatchdogDxe.inf 193 194 # 195 # FAT filesystem + GPT/MBR partitioning 196 # 197 INF OpenPlatformPkg/Drivers/Block/ramdisk/ramdisk.inf 198 INF MdeModulePkg/Universal/Disk/DiskIoDxe/DiskIoDxe.inf 199 INF MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf 200 INF FatBinPkg/EnhancedFatDxe/Fat.inf 201 INF MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf 202 INF IntelFrameworkModulePkg/Universal/StatusCode/RuntimeDxe/StatusCodeRuntimeDxe.inf 203 204 # 205 # Usb Support 206 # 207 208 INF OpenPlatformPkg/Chips/Hisilicon/Drivers/VirtualEhciPciIo/VirtualEhciPciIo.inf 209 INF MdeModulePkg/Bus/Pci/EhciDxe/EhciDxe.inf 210 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/OhciDxe/OhciDxe.inf 211 INF MdeModulePkg/Bus/Usb/UsbBusDxe/UsbBusDxe.inf 212 INF MdeModulePkg/Bus/Usb/UsbKbDxe/UsbKbDxe.inf 213 INF MdeModulePkg/Bus/Usb/UsbMouseDxe/UsbMouseDxe.inf 214 INF MdeModulePkg/Bus/Usb/UsbMassStorageDxe/UsbMassStorageDxe.inf 215 216 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/Ipmi/ipmiInterfaceDxe/IpmiInterfaceDxe.inf 217 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/GetInfoFromBmc/GetInfoFromBmc.inf 218 INF MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf 219 INF OpenPlatformPkg/Chips/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/SmbiosMiscDxe.inf 220 221 INF OpenPlatformPkg/Chips/Hisilicon/Drivers/Smbios/AddSmbiosType9/AddSmbiosType9.inf 222 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/TransferSmbiosInfo/TransSmbiosInfo.inf 223 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/IpmiMiscOpDxe/IpmiMiscOpDxe.inf 224 225 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/IpmiWatchdogDxe/IpmiWatchdogDxe.inf 226 227 228 INF OpenPlatformPkg/Chips/Hisilicon/Drivers/Smbios/MemorySubClassDxe/MemorySubClassDxe.inf 229 230 INF OpenPlatformPkg/Chips/Hisilicon/Drivers/Smbios/ProcessorSubClassDxe/ProcessorSubClassDxe.inf 231 232 # 233 #ACPI 234 # 235 INF MdeModulePkg/Universal/Acpi/AcpiTableDxe/AcpiTableDxe.inf 236 INF MdeModulePkg/Universal/Acpi/AcpiPlatformDxe/AcpiPlatformDxe.inf 237 238 INF RuleOverride=ACPITABLE OpenPlatformPkg/Chips/Hisilicon/Hi1610/Hi1610AcpiTables/AcpiTablesHi1610.inf 239 INF OpenPlatformPkg/Chips/Hisilicon/Drivers/AcpiPlatformDxe/AcpiPlatformDxe.inf 240 241 # 242 #Network 243 # 244 245 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/Net/SnpPV660DxeMac0/SnpPV600DxeMac0.inf 246 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/Net/SnpPV660DxeMac1/SnpPV600DxeMac1.inf 247 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/Net/SnpPV660DxeMac4/SnpPV600DxeMac4.inf 248 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/Net/SnpPV660DxeMac5/SnpPV600DxeMac5.inf 249 250 INF MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf 251 INF MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf 252 INF MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf 253 INF MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Dxe.inf 254 INF MdeModulePkg/Universal/Network/MnpDxe/MnpDxe.inf 255 INF MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Dxe.inf 256 INF MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dxe.inf 257 INF MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf 258 INF MdeModulePkg/Universal/Network/UefiPxeBcDxe/UefiPxeBcDxe.inf 259 260!ifdef $(FDT_ENABLE) 261 INF OpenPlatformPkg/Chips/Hisilicon/Drivers/UpdateFdtDxe/UpdateFdtDxe.inf 262!endif #$(FDT_ENABLE) 263 264 # 265 # PCI Support 266 # 267 INF OpenPlatformPkg/Chips/Hisilicon/Hi1610/Drivers/PcieInit1610/PcieInitDxe.inf 268 INF OpenPlatformPkg/Platforms/Hisilicon/D03/Drivers/PciPlatform/PciPlatform.inf 269 INF OpenPlatformPkg/Chips/Hisilicon/Drivers/PciHostBridgeDxe/PciHostBridgeDxe.inf 270 INF MdeModulePkg/Bus/Pci/PciBusDxe/PciBusDxe.inf 271 272 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/ReportPciePlugDidVidToBmc/ReportPciePlugDidVidToBmc.inf 273 # VGA Driver 274 # 275 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/Sm750Dxe/UefiSmi.inf 276 277 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/Sas/SasDxeDriver.inf 278 # 279 # UEFI application (Shell Embedded Boot Loader) 280 # 281 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Ebl/Ebl.inf 282 283 # 284 # Build Shell from latest source code instead of prebuilt binary 285 # 286 INF ShellPkg/Application/Shell/Shell.inf 287 288 # 289 # Bds 290 # 291 INF MdeModulePkg/Universal/DevicePathDxe/DevicePathDxe.inf 292 293 INF MdeModulePkg/Universal/MemoryTest/NullMemoryTestDxe/NullMemoryTestDxe.inf 294 INF MdeModulePkg/Universal/DisplayEngineDxe/DisplayEngineDxe.inf 295 INF MdeModulePkg/Universal/SetupBrowserDxe/SetupBrowserDxe.inf 296 INF IntelFrameworkModulePkg/Universal/BdsDxe/BdsDxe.inf 297 298[FV.FVMAIN_COMPACT] 299FvAlignment = 16 300ERASE_POLARITY = 1 301MEMORY_MAPPED = TRUE 302STICKY_WRITE = TRUE 303LOCK_CAP = TRUE 304LOCK_STATUS = TRUE 305WRITE_DISABLED_CAP = TRUE 306WRITE_ENABLED_CAP = TRUE 307WRITE_STATUS = TRUE 308WRITE_LOCK_CAP = TRUE 309WRITE_LOCK_STATUS = TRUE 310READ_DISABLED_CAP = TRUE 311READ_ENABLED_CAP = TRUE 312READ_STATUS = TRUE 313READ_LOCK_CAP = TRUE 314READ_LOCK_STATUS = TRUE 315 316 INF ArmPlatformPkg/PrePeiCore/PrePeiCoreMPCore.inf 317 INF MdeModulePkg/Core/Pei/PeiMain.inf 318 INF ArmPlatformPkg/PlatformPei/PlatformPeim.inf 319 320 INF MdeModulePkg/Universal/FaultTolerantWritePei/FaultTolerantWritePei.inf 321 INF MdeModulePkg/Universal/Variable/Pei/VariablePei.inf 322 323 INF OpenPlatformPkg/Chips/Hisilicon/Drivers/VersionInfoPeim/VersionInfoPeim.inf 324 325 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/Drivers/Ipmi/IpmiInterfacePei/IpmiInterfacePei.inf 326 INF OpenPlatformPkg/Platforms/Hisilicon/Binary/D03/MemoryInitPei/MemoryInitPeim.inf 327 INF ArmPkg/Drivers/CpuPei/CpuPei.inf 328 INF MdeModulePkg/Universal/PCD/Pei/Pcd.inf 329 INF IntelFrameworkModulePkg/Universal/StatusCode/Pei/StatusCodePei.inf 330 INF OpenPlatformPkg/Platforms/Hisilicon/D03/EarlyConfigPeim/EarlyConfigPeimD03.inf 331 332 INF MdeModulePkg/Core/DxeIplPeim/DxeIpl.inf 333 334 FILE FV_IMAGE = 9E21FD93-9C72-4c15-8C4B-E77F1DB2D792 { 335 SECTION GUIDED EE4E5898-3914-4259-9D6E-DC7BD79403CF PROCESSING_REQUIRED = TRUE { 336 SECTION FV_IMAGE = FVMAIN 337 } 338 } 339 340 341!include OpenPlatformPkg/Chips/Hisilicon/Hisilicon.fdf.inc 342 343