1# 2# Copyright (c) 2013-2015, ARM Limited. All rights reserved. 3# 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 8# 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. 11# 12 13################################################################################ 14# 15# FD Section 16# The [FD] Section is made up of the definition statements and a 17# description of what goes into the Flash Device Image. Each FD section 18# defines one flash "device" image. A flash device image may be one of 19# the following: Removable media bootable image (like a boot floppy 20# image,) an Option ROM image (that would be "flashed" into an add-in 21# card,) a System "Flash" image (that would be burned into a system's 22# flash) or an Update ("Capsule") image that will be used to update and 23# existing system flash. 24# 25################################################################################ 26 27[FD.BL33_AP_UEFI] 28BaseAddress = 0xE0000000|gArmTokenSpaceGuid.PcdFdBaseAddress # The base address of the Firmware in NOR Flash. 29Size = 0x000F0000|gArmTokenSpaceGuid.PcdFdSize # The size in bytes of the FLASH Device 30ErasePolarity = 1 31 32# This one is tricky, it must be: BlockSize * NumBlocks = Size 33BlockSize = 0x00001000 34NumBlocks = 0xF0 35 36################################################################################ 37# 38# Following are lists of FD Region layout which correspond to the locations of different 39# images within the flash device. 40# 41# Regions must be defined in ascending order and may not overlap. 42# 43# A Layout Region start with a eight digit hex offset (leading "0x" required) followed by 44# the pipe "|" character, followed by the size of the region, also in hex with the leading 45# "0x" characters. Like: 46# Offset|Size 47# PcdOffsetCName|PcdSizeCName 48# RegionType <FV, DATA, or FILE> 49# 50################################################################################ 51 520x00000000|0x000F0000 53gArmTokenSpaceGuid.PcdFvBaseAddress|gArmTokenSpaceGuid.PcdFvSize 54FV = FVMAIN_COMPACT 55 56 57################################################################################ 58# 59# FV Section 60# 61# [FV] section is used to define what components or modules are placed within a flash 62# device file. This section also defines order the components and modules are positioned 63# within the image. The [FV] section consists of define statements, set statements and 64# module statements. 65# 66################################################################################ 67 68[FV.FvMain] 69BlockSize = 0x40 70NumBlocks = 0 # This FV gets compressed so make it just big enough 71FvAlignment = 8 # FV alignment and FV attributes setting. 72ERASE_POLARITY = 1 73MEMORY_MAPPED = TRUE 74STICKY_WRITE = TRUE 75LOCK_CAP = TRUE 76LOCK_STATUS = TRUE 77WRITE_DISABLED_CAP = TRUE 78WRITE_ENABLED_CAP = TRUE 79WRITE_STATUS = TRUE 80WRITE_LOCK_CAP = TRUE 81WRITE_LOCK_STATUS = TRUE 82READ_DISABLED_CAP = TRUE 83READ_ENABLED_CAP = TRUE 84READ_STATUS = TRUE 85READ_LOCK_CAP = TRUE 86READ_LOCK_STATUS = TRUE 87FvNameGuid = B73FE497-B92E-416e-8326-45AD0D270092 88 89 APRIORI DXE { 90 INF MdeModulePkg/Universal/PCD/Dxe/Pcd.inf 91 } 92 93 INF MdeModulePkg/Core/Dxe/DxeMain.inf 94 INF MdeModulePkg/Universal/PCD/Dxe/Pcd.inf 95 96 # 97 # PI DXE Drivers producing Architectural Protocols (EFI Services) 98 # 99 INF ArmPkg/Drivers/CpuDxe/CpuDxe.inf 100 INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf 101 INF MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf 102 INF MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf 103 INF MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf 104 INF EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf 105 INF EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf 106 INF EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf 107 108 INF MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf 109 INF MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf 110 111 # 112 # ACPI Support 113 # 114 INF MdeModulePkg/Universal/Acpi/AcpiTableDxe/AcpiTableDxe.inf 115 INF RuleOverride=ACPITABLE OpenPlatformPkg/Platforms/ARM/Juno/AcpiTables/AcpiTables.inf 116 117 INF MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf 118 119 # 120 # Multiple Console IO support 121 # 122 INF MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatformDxe.inf 123 INF MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf 124 INF MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf 125 INF MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf 126 INF MdeModulePkg/Universal/SerialDxe/SerialDxe.inf 127 128 INF ArmPkg/Drivers/ArmGic/ArmGicDxe.inf 129 INF ArmPkg/Drivers/TimerDxe/TimerDxe.inf 130 INF ArmPkg/Drivers/GenericWatchdogDxe/GenericWatchdogDxe.inf 131 132 # NOR Flash driver 133 INF ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashDxe.inf 134 135 # Versatile Express FileSystem 136 INF ArmPlatformPkg/FileSystem/BootMonFs/BootMonFs.inf 137 138 # 139 # FAT filesystem + GPT/MBR partitioning 140 # 141 INF MdeModulePkg/Universal/Disk/DiskIoDxe/DiskIoDxe.inf 142 INF MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf 143 INF FatBinPkg/EnhancedFatDxe/Fat.inf 144 INF MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf 145 146 # Required by PCI 147 INF UefiCpuPkg/CpuIo2Dxe/CpuIo2Dxe.inf 148 149 # FV FileSystem 150 INF MdeModulePkg/Universal/FvSimpleFileSystemDxe/FvSimpleFileSystemDxe.inf 151 152 # 153 # Usb Support 154 # 155 INF MdeModulePkg/Bus/Pci/EhciDxe/EhciDxe.inf 156 INF MdeModulePkg/Bus/Usb/UsbBusDxe/UsbBusDxe.inf 157 INF MdeModulePkg/Bus/Usb/UsbKbDxe/UsbKbDxe.inf 158 INF MdeModulePkg/Bus/Usb/UsbMassStorageDxe/UsbMassStorageDxe.inf 159 INF MdeModulePkg/Bus/Usb/UsbMouseDxe/UsbMouseDxe.inf 160 161 # 162 # PCI Support 163 # 164 INF MdeModulePkg/Bus/Pci/PciBusDxe/PciBusDxe.inf 165 INF ArmPlatformPkg/ArmJunoPkg/Drivers/PciHostBridgeDxe/PciHostBridgeDxe.inf 166 167 # 168 # SATA Controller 169 # 170 INF MdeModulePkg/Bus/Ata/AtaBusDxe/AtaBusDxe.inf 171 INF EmbeddedPkg/Drivers/SataSiI3132Dxe/SataSiI3132Dxe.inf 172 173 # 174 # Networking stack 175 # 176 INF MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf 177 INF MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf 178 INF MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf 179 INF MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Dxe.inf 180 INF MdeModulePkg/Universal/Network/MnpDxe/MnpDxe.inf 181 INF MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigDxe.inf 182 INF MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Dxe.inf 183 INF MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dxe.inf 184 INF MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf 185 INF MdeModulePkg/Universal/Network/UefiPxeBcDxe/UefiPxeBcDxe.inf 186 INF MdeModulePkg/Universal/Network/IScsiDxe/IScsiDxe.inf 187 INF EmbeddedPkg/Drivers/Lan9118Dxe/Lan9118Dxe.inf 188 189 # 190 # UEFI applications 191 # 192 INF ShellBinPkg/UefiShell/UefiShell.inf 193 194 # 195 # Juno platform driver 196 # 197 INF ArmPlatformPkg/ArmJunoPkg/Drivers/ArmJunoDxe/ArmJunoDxe.inf 198 199 # 200 # Bds 201 # 202 INF MdeModulePkg/Universal/DevicePathDxe/DevicePathDxe.inf 203 INF MdeModulePkg/Universal/DisplayEngineDxe/DisplayEngineDxe.inf 204 INF MdeModulePkg/Universal/SetupBrowserDxe/SetupBrowserDxe.inf 205 INF IntelFrameworkModulePkg/Universal/BdsDxe/BdsDxe.inf 206 207 # 208 # FDT installation 209 # 210 # The UEFI driver is at the end of the list of the driver to be dispatched 211 # after the device drivers (eg: Ethernet) to ensure we have support for them. 212 INF EmbeddedPkg/Drivers/FdtPlatformDxe/FdtPlatformDxe.inf 213 214[FV.FVMAIN_COMPACT] 215FvAlignment = 8 216ERASE_POLARITY = 1 217MEMORY_MAPPED = TRUE 218STICKY_WRITE = TRUE 219LOCK_CAP = TRUE 220LOCK_STATUS = TRUE 221WRITE_DISABLED_CAP = TRUE 222WRITE_ENABLED_CAP = TRUE 223WRITE_STATUS = TRUE 224WRITE_LOCK_CAP = TRUE 225WRITE_LOCK_STATUS = TRUE 226READ_DISABLED_CAP = TRUE 227READ_ENABLED_CAP = TRUE 228READ_STATUS = TRUE 229READ_LOCK_CAP = TRUE 230READ_LOCK_STATUS = TRUE 231 232 INF ArmPlatformPkg/PrePi/PeiMPCore.inf 233 234 FILE FV_IMAGE = 9E21FD93-9C72-4c15-8C4B-E77F1DB2D792 { 235 SECTION GUIDED EE4E5898-3914-4259-9D6E-DC7BD79403CF PROCESSING_REQUIRED = TRUE { 236 SECTION FV_IMAGE = FVMAIN 237 } 238 } 239 240 241################################################################################ 242# 243# Rules are use with the [FV] section's module INF type to define 244# how an FFS file is created for a given INF file. The following Rule are the default 245# rules for the different module type. User can add the customized rules to define the 246# content of the FFS file. 247# 248################################################################################ 249 250 251############################################################################ 252# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section # 253############################################################################ 254# 255#[Rule.Common.DXE_DRIVER] 256# FILE DRIVER = $(NAMED_GUID) { 257# DXE_DEPEX DXE_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex 258# COMPRESS PI_STD { 259# GUIDED { 260# PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi 261# UI STRING="$(MODULE_NAME)" Optional 262# VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER) 263# } 264# } 265# } 266# 267############################################################################ 268 269# 270# These SEC rules are used for ArmPlatformPkg/PrePi module. 271# ArmPlatformPkg/PrePi is declared as a SEC module to make GenFv patch the 272# UEFI Firmware to jump to ArmPlatformPkg/PrePi entrypoint 273# 274[Rule.ARM.SEC] 275 FILE SEC = $(NAMED_GUID) RELOCS_STRIPPED { 276 TE TE Align = 32 $(INF_OUTPUT)/$(MODULE_NAME).efi 277 } 278 279[Rule.AARCH64.SEC] 280 FILE SEC = $(NAMED_GUID) RELOCS_STRIPPED FIXED { 281 TE TE Align = Auto $(INF_OUTPUT)/$(MODULE_NAME).efi 282 } 283 284# A shim specific rule is required to ensure the alignment is 4K. 285# Otherwise BaseTools pick up the AArch32 alignment (ie: 32) 286[Rule.ARM.SEC.SHIM] 287 FILE SEC = $(NAMED_GUID) RELOCS_STRIPPED { 288 TE TE Align = 4K $(INF_OUTPUT)/$(MODULE_NAME).efi 289 } 290 291[Rule.Common.PEI_CORE] 292 FILE PEI_CORE = $(NAMED_GUID) FIXED { 293 TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi 294 UI STRING ="$(MODULE_NAME)" Optional 295 } 296 297[Rule.Common.PEIM] 298 FILE PEIM = $(NAMED_GUID) FIXED { 299 PEI_DEPEX PEI_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex 300 TE TE $(INF_OUTPUT)/$(MODULE_NAME).efi 301 UI STRING="$(MODULE_NAME)" Optional 302 } 303 304[Rule.Common.PEIM.TIANOCOMPRESSED] 305 FILE PEIM = $(NAMED_GUID) DEBUG_MYTOOLS_IA32 { 306 PEI_DEPEX PEI_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex 307 GUIDED A31280AD-481E-41B6-95E8-127F4C984779 PROCESSING_REQUIRED = TRUE { 308 PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi 309 UI STRING="$(MODULE_NAME)" Optional 310 } 311 } 312 313[Rule.Common.DXE_CORE] 314 FILE DXE_CORE = $(NAMED_GUID) { 315 PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi 316 UI STRING="$(MODULE_NAME)" Optional 317 } 318 319[Rule.Common.UEFI_DRIVER] 320 FILE DRIVER = $(NAMED_GUID) { 321 DXE_DEPEX DXE_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex 322 PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi 323 UI STRING="$(MODULE_NAME)" Optional 324 } 325 326[Rule.Common.DXE_DRIVER] 327 FILE DRIVER = $(NAMED_GUID) { 328 DXE_DEPEX DXE_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex 329 PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi 330 UI STRING="$(MODULE_NAME)" Optional 331 } 332 333[Rule.Common.DXE_RUNTIME_DRIVER] 334 FILE DRIVER = $(NAMED_GUID) { 335 DXE_DEPEX DXE_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex 336 PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi 337 UI STRING="$(MODULE_NAME)" Optional 338 } 339 340[Rule.Common.UEFI_APPLICATION] 341 FILE APPLICATION = $(NAMED_GUID) { 342 UI STRING ="$(MODULE_NAME)" Optional 343 PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi 344 } 345 346[Rule.Common.UEFI_DRIVER.BINARY] 347 FILE DRIVER = $(NAMED_GUID) { 348 DXE_DEPEX DXE_DEPEX Optional |.depex 349 PE32 PE32 |.efi 350 UI STRING="$(MODULE_NAME)" Optional 351 VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER) 352 } 353 354[Rule.Common.UEFI_APPLICATION.BINARY] 355 FILE APPLICATION = $(NAMED_GUID) { 356 PE32 PE32 |.efi 357 UI STRING="$(MODULE_NAME)" Optional 358 VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER) 359 } 360 361[Rule.Common.USER_DEFINED.ACPITABLE] 362 FILE FREEFORM = $(NAMED_GUID) { 363 RAW ACPI |.acpi 364 RAW ASL |.aml 365 } 366