blob: 89a4015e595b0308e51f6d41318d6d4ea8cfbd45 [file] [log] [blame]
Michael Casadevall6f5872b2014-09-18 18:11:24 +00001#
Olivier Martin7fbd1eb2015-05-29 13:50:43 +00002# Copyright (c) 2011-2015, ARM Limited. All rights reserved.
Michael Casadevall6f5872b2014-09-18 18:11:24 +00003# Copyright (c) 2014, Linaro Limited. All rights reserved.
Star Zengd68d2ed2015-07-01 03:11:05 +00004# Copyright (c) 2015, Intel Corporation. All rights reserved.
Michael Casadevall6f5872b2014-09-18 18:11:24 +00005#
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################################################################################
16#
17# FD Section
18# The [FD] Section is made up of the definition statements and a
19# description of what goes into the Flash Device Image. Each FD section
20# defines one flash "device" image. A flash device image may be one of
21# the following: Removable media bootable image (like a boot floppy
22# image,) an Option ROM image (that would be "flashed" into an add-in
23# card,) a System "Flash" image (that would be burned into a system's
24# flash) or an Update ("Capsule") image that will be used to update and
25# existing system flash.
26#
27################################################################################
28
29[FD.QEMU_EFI]
30BaseAddress = 0x00000000|gArmTokenSpaceGuid.PcdFdBaseAddress # QEMU assigns 0 - 0x8000000 for a BootROM
31Size = 0x00200000|gArmTokenSpaceGuid.PcdFdSize # The size in bytes of the FLASH Device
32ErasePolarity = 1
33
34# This one is tricky, it must be: BlockSize * NumBlocks = Size
35BlockSize = 0x00001000
36NumBlocks = 0x200
37
38################################################################################
39#
40# Following are lists of FD Region layout which correspond to the locations of different
41# images within the flash device.
42#
43# Regions must be defined in ascending order and may not overlap.
44#
45# A Layout Region start with a eight digit hex offset (leading "0x" required) followed by
46# the pipe "|" character, followed by the size of the region, also in hex with the leading
47# "0x" characters. Like:
48# Offset|Size
49# PcdOffsetCName|PcdSizeCName
50# RegionType <FV, DATA, or FILE>
51#
52################################################################################
53
54#
55# UEFI has trouble dealing with FVs that reside at physical address 0x0.
56# So instead, put a hardcoded 'jump to 0x1000' at offset 0x0, and put the
57# real FV at offset 0x1000
58#
590x00000000|0x00001000
60DATA = {
61!if $(ARCH) == AARCH64
62 0x00, 0x04, 0x00, 0x14 # 'b 0x1000' in AArch64 ASM
63!else
64 0xfe, 0x03, 0x00, 0xea # 'b 0x1000' in AArch32 ASM
65!endif
66}
67
680x00001000|0x001ff000
69gArmTokenSpaceGuid.PcdFvBaseAddress|gArmTokenSpaceGuid.PcdFvSize
70FV = FVMAIN_COMPACT
71
72
73################################################################################
74#
75# FV Section
76#
77# [FV] section is used to define what components or modules are placed within a flash
78# device file. This section also defines order the components and modules are positioned
79# within the image. The [FV] section consists of define statements, set statements and
80# module statements.
81#
82################################################################################
83
84[FV.FvMain]
85BlockSize = 0x40
86NumBlocks = 0 # This FV gets compressed so make it just big enough
87FvAlignment = 16 # FV alignment and FV attributes setting.
88ERASE_POLARITY = 1
89MEMORY_MAPPED = TRUE
90STICKY_WRITE = TRUE
91LOCK_CAP = TRUE
92LOCK_STATUS = TRUE
93WRITE_DISABLED_CAP = TRUE
94WRITE_ENABLED_CAP = TRUE
95WRITE_STATUS = TRUE
96WRITE_LOCK_CAP = TRUE
97WRITE_LOCK_STATUS = TRUE
98READ_DISABLED_CAP = TRUE
99READ_ENABLED_CAP = TRUE
100READ_STATUS = TRUE
101READ_LOCK_CAP = TRUE
102READ_LOCK_STATUS = TRUE
103
104 APRIORI DXE {
105 INF MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
Olivier Martin7fbd1eb2015-05-29 13:50:43 +0000106 INF ArmVirtPkg/VirtFdtDxe/VirtFdtDxe.inf
Michael Casadevall6f5872b2014-09-18 18:11:24 +0000107 }
108 INF MdeModulePkg/Core/Dxe/DxeMain.inf
109 INF MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
Olivier Martin7fbd1eb2015-05-29 13:50:43 +0000110 INF ArmVirtPkg/VirtFdtDxe/VirtFdtDxe.inf
Michael Casadevall6f5872b2014-09-18 18:11:24 +0000111
112 #
113 # PI DXE Drivers producing Architectural Protocols (EFI Services)
114 #
115 INF ArmPkg/Drivers/CpuDxe/CpuDxe.inf
116 INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
117 INF MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
118 INF MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
119 INF MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf
120 INF MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf
Star Zengd68d2ed2015-07-01 03:11:05 +0000121!if $(SECURE_BOOT_ENABLE) == TRUE
122 INF SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDxe.inf
Ard Biesheuvel80f882a2015-05-07 15:22:31 +0000123!endif
Michael Casadevall6f5872b2014-09-18 18:11:24 +0000124 INF MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
125 INF EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
126 INF EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
127 INF EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
128 INF MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf
129
130 #
131 # Multiple Console IO support
132 #
133 INF MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatformDxe.inf
134 INF MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf
135 INF MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf
136 INF MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf
137 INF EmbeddedPkg/SerialDxe/SerialDxe.inf
138
139 INF ArmPkg/Drivers/ArmGic/ArmGicDxe.inf
140 INF ArmPkg/Drivers/TimerDxe/TimerDxe.inf
Ard Biesheuvel80f882a2015-05-07 15:22:31 +0000141!if $(SECURE_BOOT_ENABLE) == TRUE
142 INF ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashAuthenticatedDxe.inf
143!else
Michael Casadevall6f5872b2014-09-18 18:11:24 +0000144 INF ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashDxe.inf
Ard Biesheuvel80f882a2015-05-07 15:22:31 +0000145!endif
Michael Casadevall6f5872b2014-09-18 18:11:24 +0000146 INF MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf
147
148 #
149 # FAT filesystem + GPT/MBR partitioning
150 #
151 INF MdeModulePkg/Universal/Disk/DiskIoDxe/DiskIoDxe.inf
152 INF MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf
153 INF FatBinPkg/EnhancedFatDxe/Fat.inf
154 INF MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
155
156 #
157 # Platform Driver
158 #
159 INF OvmfPkg/VirtioBlkDxe/VirtioBlk.inf
160 INF OvmfPkg/VirtioNetDxe/VirtioNet.inf
161 INF OvmfPkg/VirtioScsiDxe/VirtioScsi.inf
162
163 #
164 # UEFI application (Shell Embedded Boot Loader)
165 #
Laszlo Ersekda1ce6f2015-03-16 19:56:54 +0000166 INF ShellPkg/Application/Shell/Shell.inf
Michael Casadevall6f5872b2014-09-18 18:11:24 +0000167
168 #
169 # Bds
170 #
171 INF MdeModulePkg/Universal/DevicePathDxe/DevicePathDxe.inf
Olivier Martin43ac1002014-10-13 10:55:38 +0000172 INF MdeModulePkg/Universal/DisplayEngineDxe/DisplayEngineDxe.inf
173 INF MdeModulePkg/Universal/SetupBrowserDxe/SetupBrowserDxe.inf
174 INF IntelFrameworkModulePkg/Universal/BdsDxe/BdsDxe.inf
Michael Casadevall6f5872b2014-09-18 18:11:24 +0000175
176 #
177 # Networking stack
178 #
179 INF MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf
180 INF MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf
181 INF MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf
Michael Casadevall6f5872b2014-09-18 18:11:24 +0000182 INF MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Dxe.inf
183 INF MdeModulePkg/Universal/Network/MnpDxe/MnpDxe.inf
184 INF MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigDxe.inf
185 INF MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Dxe.inf
186 INF MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dxe.inf
187 INF MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf
188 INF MdeModulePkg/Universal/Network/UefiPxeBcDxe/UefiPxeBcDxe.inf
189 INF MdeModulePkg/Universal/Network/IScsiDxe/IScsiDxe.inf
190
191 #
192 # SCSI Bus and Disk Driver
193 #
194 INF MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBusDxe.inf
195 INF MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDiskDxe.inf
196
Laszlo Ersek1c5adbe2015-02-02 19:09:07 +0000197 #
Laszlo Ersekceb05742015-07-26 08:03:00 +0000198 # SMBIOS Support
199 #
200 INF MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf
201 INF OvmfPkg/SmbiosPlatformDxe/SmbiosPlatformDxe.inf
202
203 #
Laszlo Ersek1c5adbe2015-02-02 19:09:07 +0000204 # ACPI Support
205 #
206 INF MdeModulePkg/Universal/Acpi/AcpiTableDxe/AcpiTableDxe.inf
207 INF OvmfPkg/AcpiPlatformDxe/QemuFwCfgAcpiPlatformDxe.inf
208
Laszlo Ersek10233c92015-02-23 16:04:11 +0000209 #
210 # PCI support
211 #
Olivier Martin7fbd1eb2015-05-29 13:50:43 +0000212 INF ArmVirtPkg/PciHostBridgeDxe/PciHostBridgeDxe.inf
Laszlo Ersek10233c92015-02-23 16:04:11 +0000213 INF MdeModulePkg/Bus/Pci/PciBusDxe/PciBusDxe.inf
214 INF OvmfPkg/VirtioPciDeviceDxe/VirtioPciDeviceDxe.inf
215
Laszlo Ersekd01c77b2015-02-23 16:04:25 +0000216 #
217 # Video support
218 #
219 INF OvmfPkg/QemuVideoDxe/QemuVideoDxe.inf
220 INF OvmfPkg/PlatformDxe/Platform.inf
221
Laszlo Erseke17b1db2015-02-23 16:04:30 +0000222 #
223 # USB Support
224 #
225 INF MdeModulePkg/Bus/Pci/UhciDxe/UhciDxe.inf
226 INF MdeModulePkg/Bus/Pci/EhciDxe/EhciDxe.inf
Laszlo Ersekeee32602015-03-16 19:57:06 +0000227 INF MdeModulePkg/Bus/Pci/XhciDxe/XhciDxe.inf
Laszlo Erseke17b1db2015-02-23 16:04:30 +0000228 INF MdeModulePkg/Bus/Usb/UsbBusDxe/UsbBusDxe.inf
229 INF MdeModulePkg/Bus/Usb/UsbKbDxe/UsbKbDxe.inf
230
Laszlo Ersek26a36372015-02-25 17:54:15 +0000231 #
232 # TianoCore logo (splash screen)
233 #
234 FILE FREEFORM = PCD(gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdLogoFile) {
235 SECTION RAW = MdeModulePkg/Logo/Logo.bmp
236 }
Laszlo Ersek26a36372015-02-25 17:54:15 +0000237
Ard Biesheuvel90385382015-08-04 18:41:45 +0000238!if $(ARCH) == ARM
239 INF MdeModulePkg/Universal/FvSimpleFileSystemDxe/FvSimpleFileSystemDxe.inf
240 INF ArmPkg/Application/LinuxLoader/LinuxLoader.inf
241!endif
242
Michael Casadevall6f5872b2014-09-18 18:11:24 +0000243[FV.FVMAIN_COMPACT]
244FvAlignment = 16
245ERASE_POLARITY = 1
246MEMORY_MAPPED = TRUE
247STICKY_WRITE = TRUE
248LOCK_CAP = TRUE
249LOCK_STATUS = TRUE
250WRITE_DISABLED_CAP = TRUE
251WRITE_ENABLED_CAP = TRUE
252WRITE_STATUS = TRUE
253WRITE_LOCK_CAP = TRUE
254WRITE_LOCK_STATUS = TRUE
255READ_DISABLED_CAP = TRUE
256READ_ENABLED_CAP = TRUE
257READ_STATUS = TRUE
258READ_LOCK_CAP = TRUE
259READ_LOCK_STATUS = TRUE
260
261 APRIORI PEI {
262 INF MdeModulePkg/Universal/PCD/Pei/Pcd.inf
263 }
264 INF ArmPlatformPkg/PrePeiCore/PrePeiCoreUniCore.inf
265 INF MdeModulePkg/Core/Pei/PeiMain.inf
266 INF ArmPlatformPkg/PlatformPei/PlatformPeim.inf
267 INF ArmPlatformPkg/MemoryInitPei/MemoryInitPeim.inf
268 INF ArmPkg/Drivers/CpuPei/CpuPei.inf
269 INF MdeModulePkg/Universal/PCD/Pei/Pcd.inf
270 INF MdeModulePkg/Universal/Variable/Pei/VariablePei.inf
Michael Casadevall6f5872b2014-09-18 18:11:24 +0000271 INF MdeModulePkg/Core/DxeIplPeim/DxeIpl.inf
272
273 FILE FV_IMAGE = 9E21FD93-9C72-4c15-8C4B-E77F1DB2D792 {
274 SECTION GUIDED EE4E5898-3914-4259-9D6E-DC7BD79403CF PROCESSING_REQUIRED = TRUE {
275 SECTION FV_IMAGE = FVMAIN
276 }
277 }
278
279
280################################################################################
281#
282# Rules are use with the [FV] section's module INF type to define
283# how an FFS file is created for a given INF file. The following Rule are the default
284# rules for the different module type. User can add the customized rules to define the
285# content of the FFS file.
286#
287################################################################################
288
289
290############################################################################
291# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
292############################################################################
293#
294#[Rule.Common.DXE_DRIVER]
295# FILE DRIVER = $(NAMED_GUID) {
296# DXE_DEPEX DXE_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
297# COMPRESS PI_STD {
298# GUIDED {
299# PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
300# UI STRING="$(MODULE_NAME)" Optional
301# VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
302# }
303# }
304# }
305#
306############################################################################
307
308[Rule.Common.SEC]
Ard Biesheuvel7669f732015-07-31 08:24:18 +0000309 FILE SEC = $(NAMED_GUID) RELOCS_STRIPPED FIXED {
310 TE TE Align = Auto $(INF_OUTPUT)/$(MODULE_NAME).efi
Michael Casadevall6f5872b2014-09-18 18:11:24 +0000311 }
312
313[Rule.Common.PEI_CORE]
Ard Biesheuvel7669f732015-07-31 08:24:18 +0000314 FILE PEI_CORE = $(NAMED_GUID) FIXED {
315 TE TE Align = Auto $(INF_OUTPUT)/$(MODULE_NAME).efi
Michael Casadevall6f5872b2014-09-18 18:11:24 +0000316 UI STRING ="$(MODULE_NAME)" Optional
317 }
318
319[Rule.Common.PEIM]
Ard Biesheuvel7669f732015-07-31 08:24:18 +0000320 FILE PEIM = $(NAMED_GUID) FIXED {
Michael Casadevall6f5872b2014-09-18 18:11:24 +0000321 PEI_DEPEX PEI_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
Ard Biesheuvel7669f732015-07-31 08:24:18 +0000322 TE TE Align = Auto $(INF_OUTPUT)/$(MODULE_NAME).efi
Michael Casadevall6f5872b2014-09-18 18:11:24 +0000323 UI STRING="$(MODULE_NAME)" Optional
324 }
325
326[Rule.Common.PEIM.TIANOCOMPRESSED]
327 FILE PEIM = $(NAMED_GUID) DEBUG_MYTOOLS_IA32 {
328 PEI_DEPEX PEI_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
329 GUIDED A31280AD-481E-41B6-95E8-127F4C984779 PROCESSING_REQUIRED = TRUE {
330 PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
331 UI STRING="$(MODULE_NAME)" Optional
332 }
333 }
334
335[Rule.Common.DXE_CORE]
336 FILE DXE_CORE = $(NAMED_GUID) {
337 PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
338 UI STRING="$(MODULE_NAME)" Optional
339 }
340
341[Rule.Common.UEFI_DRIVER]
342 FILE DRIVER = $(NAMED_GUID) {
343 DXE_DEPEX DXE_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
344 PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
345 UI STRING="$(MODULE_NAME)" Optional
346 }
347
348[Rule.Common.DXE_DRIVER]
349 FILE DRIVER = $(NAMED_GUID) {
350 DXE_DEPEX DXE_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
351 PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
352 UI STRING="$(MODULE_NAME)" Optional
353 }
354
355[Rule.Common.DXE_RUNTIME_DRIVER]
356 FILE DRIVER = $(NAMED_GUID) {
357 DXE_DEPEX DXE_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
358 PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
359 UI STRING="$(MODULE_NAME)" Optional
360 }
361
362[Rule.Common.UEFI_APPLICATION]
363 FILE APPLICATION = $(NAMED_GUID) {
364 UI STRING ="$(MODULE_NAME)" Optional
365 PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
366 }
367
368[Rule.Common.UEFI_DRIVER.BINARY]
369 FILE DRIVER = $(NAMED_GUID) {
370 DXE_DEPEX DXE_DEPEX Optional |.depex
371 PE32 PE32 |.efi
372 UI STRING="$(MODULE_NAME)" Optional
373 VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
374 }
375
376[Rule.Common.UEFI_APPLICATION.BINARY]
377 FILE APPLICATION = $(NAMED_GUID) {
378 PE32 PE32 |.efi
379 UI STRING="$(MODULE_NAME)" Optional
380 VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
381 }
382
383[Rule.Common.USER_DEFINED.ACPITABLE]
384 FILE FREEFORM = $(NAMED_GUID) {
385 RAW ACPI |.acpi
386 RAW ASL |.aml
387 UI STRING="$(MODULE_NAME)" Optional
388 }