1## @file
2#  Open Virtual Machine Firmware: FDF
3#
4#  Copyright (c) 2006 - 2019, Intel Corporation. All rights reserved.<BR>
5#  (C) Copyright 2016 Hewlett Packard Enterprise Development LP<BR>
6#
7#  SPDX-License-Identifier: BSD-2-Clause-Patent
8#
9##
10
11################################################################################
12
13[Defines]
14!include OvmfPkg.fdf.inc
15
16#
17# Build the variable store and the firmware code as one unified flash device
18# image.
19#
20[FD.OVMF]
21BaseAddress   = $(FW_BASE_ADDRESS)
22Size          = $(FW_SIZE)
23ErasePolarity = 1
24BlockSize     = $(BLOCK_SIZE)
25NumBlocks     = $(FW_BLOCKS)
26
27!include VarStore.fdf.inc
28
29$(VARS_SIZE)|$(FVMAIN_SIZE)
30FV = FVMAIN_COMPACT
31
32$(SECFV_OFFSET)|$(SECFV_SIZE)
33FV = SECFV
34
35#
36# Build the variable store and the firmware code as separate flash device
37# images.
38#
39[FD.OVMF_VARS]
40BaseAddress   = $(FW_BASE_ADDRESS)
41Size          = $(VARS_SIZE)
42ErasePolarity = 1
43BlockSize     = $(BLOCK_SIZE)
44NumBlocks     = $(VARS_BLOCKS)
45
46!include VarStore.fdf.inc
47
48[FD.OVMF_CODE]
49BaseAddress   = $(CODE_BASE_ADDRESS)
50Size          = $(CODE_SIZE)
51ErasePolarity = 1
52BlockSize     = $(BLOCK_SIZE)
53NumBlocks     = $(CODE_BLOCKS)
54
550x00000000|$(FVMAIN_SIZE)
56FV = FVMAIN_COMPACT
57
58$(FVMAIN_SIZE)|$(SECFV_SIZE)
59FV = SECFV
60
61################################################################################
62
63[FD.MEMFD]
64BaseAddress   = $(MEMFD_BASE_ADDRESS)
65Size          = 0xC00000
66ErasePolarity = 1
67BlockSize     = 0x10000
68NumBlocks     = 0xC0
69
700x000000|0x006000
71gUefiOvmfPkgTokenSpaceGuid.PcdOvmfSecPageTablesBase|gUefiOvmfPkgTokenSpaceGuid.PcdOvmfSecPageTablesSize
72
730x006000|0x001000
74gUefiOvmfPkgTokenSpaceGuid.PcdOvmfLockBoxStorageBase|gUefiOvmfPkgTokenSpaceGuid.PcdOvmfLockBoxStorageSize
75
760x007000|0x001000
77gEfiMdePkgTokenSpaceGuid.PcdGuidedExtractHandlerTableAddress|gUefiOvmfPkgTokenSpaceGuid.PcdGuidedExtractHandlerTableSize
78
790x010000|0x010000
80gUefiOvmfPkgTokenSpaceGuid.PcdOvmfSecPeiTempRamBase|gUefiOvmfPkgTokenSpaceGuid.PcdOvmfSecPeiTempRamSize
81
820x020000|0x0E0000
83gUefiOvmfPkgTokenSpaceGuid.PcdOvmfPeiMemFvBase|gUefiOvmfPkgTokenSpaceGuid.PcdOvmfPeiMemFvSize
84FV = PEIFV
85
860x100000|0xB00000
87gUefiOvmfPkgTokenSpaceGuid.PcdOvmfDxeMemFvBase|gUefiOvmfPkgTokenSpaceGuid.PcdOvmfDxeMemFvSize
88FV = DXEFV
89
90################################################################################
91
92[FV.SECFV]
93FvNameGuid         = 763BED0D-DE9F-48F5-81F1-3E90E1B1A015
94BlockSize          = 0x1000
95FvAlignment        = 16
96ERASE_POLARITY     = 1
97MEMORY_MAPPED      = TRUE
98STICKY_WRITE       = TRUE
99LOCK_CAP           = TRUE
100LOCK_STATUS        = TRUE
101WRITE_DISABLED_CAP = TRUE
102WRITE_ENABLED_CAP  = TRUE
103WRITE_STATUS       = TRUE
104WRITE_LOCK_CAP     = TRUE
105WRITE_LOCK_STATUS  = TRUE
106READ_DISABLED_CAP  = TRUE
107READ_ENABLED_CAP   = TRUE
108READ_STATUS        = TRUE
109READ_LOCK_CAP      = TRUE
110READ_LOCK_STATUS   = TRUE
111
112#
113# SEC Phase modules
114#
115# The code in this FV handles the initial firmware startup, and
116# decompresses the PEI and DXE FVs which handles the rest of the boot sequence.
117#
118INF  OvmfPkg/Sec/SecMain.inf
119
120INF  RuleOverride=RESET_VECTOR OvmfPkg/ResetVector/ResetVector.inf
121
122################################################################################
123[FV.PEIFV]
124FvNameGuid         = 6938079B-B503-4E3D-9D24-B28337A25806
125BlockSize          = 0x10000
126FvAlignment        = 16
127ERASE_POLARITY     = 1
128MEMORY_MAPPED      = TRUE
129STICKY_WRITE       = TRUE
130LOCK_CAP           = TRUE
131LOCK_STATUS        = TRUE
132WRITE_DISABLED_CAP = TRUE
133WRITE_ENABLED_CAP  = TRUE
134WRITE_STATUS       = TRUE
135WRITE_LOCK_CAP     = TRUE
136WRITE_LOCK_STATUS  = TRUE
137READ_DISABLED_CAP  = TRUE
138READ_ENABLED_CAP   = TRUE
139READ_STATUS        = TRUE
140READ_LOCK_CAP      = TRUE
141READ_LOCK_STATUS   = TRUE
142
143APRIORI PEI {
144  INF  MdeModulePkg/Universal/PCD/Pei/Pcd.inf
145}
146
147#
148#  PEI Phase modules
149#
150INF  MdeModulePkg/Core/Pei/PeiMain.inf
151INF  MdeModulePkg/Universal/PCD/Pei/Pcd.inf
152INF  MdeModulePkg/Universal/ReportStatusCodeRouter/Pei/ReportStatusCodeRouterPei.inf
153INF  MdeModulePkg/Universal/StatusCodeHandler/Pei/StatusCodeHandlerPei.inf
154INF  OvmfPkg/PlatformPei/PlatformPei.inf
155INF  MdeModulePkg/Core/DxeIplPeim/DxeIpl.inf
156INF  UefiCpuPkg/Universal/Acpi/S3Resume2Pei/S3Resume2Pei.inf
157!if $(SMM_REQUIRE) == TRUE
158INF  OvmfPkg/SmmAccess/SmmAccessPei.inf
159!endif
160INF  UefiCpuPkg/CpuMpPei/CpuMpPei.inf
161
162!if $(TPM2_ENABLE) == TRUE
163INF  OvmfPkg/Tcg/Tcg2Config/Tcg2ConfigPei.inf
164INF  SecurityPkg/Tcg/Tcg2Pei/Tcg2Pei.inf
165!endif
166
167################################################################################
168
169[FV.DXEFV]
170FvForceRebase      = FALSE
171FvNameGuid         = 7CB8BDC9-F8EB-4F34-AAEA-3EE4AF6516A1
172BlockSize          = 0x10000
173FvAlignment        = 16
174ERASE_POLARITY     = 1
175MEMORY_MAPPED      = TRUE
176STICKY_WRITE       = TRUE
177LOCK_CAP           = TRUE
178LOCK_STATUS        = TRUE
179WRITE_DISABLED_CAP = TRUE
180WRITE_ENABLED_CAP  = TRUE
181WRITE_STATUS       = TRUE
182WRITE_LOCK_CAP     = TRUE
183WRITE_LOCK_STATUS  = TRUE
184READ_DISABLED_CAP  = TRUE
185READ_ENABLED_CAP   = TRUE
186READ_STATUS        = TRUE
187READ_LOCK_CAP      = TRUE
188READ_LOCK_STATUS   = TRUE
189
190APRIORI DXE {
191  INF  MdeModulePkg/Universal/DevicePathDxe/DevicePathDxe.inf
192  INF  MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
193  INF  OvmfPkg/AmdSevDxe/AmdSevDxe.inf
194!if $(SMM_REQUIRE) == FALSE
195  INF  OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FvbServicesRuntimeDxe.inf
196!endif
197}
198
199#
200# DXE Phase modules
201#
202INF  MdeModulePkg/Core/Dxe/DxeMain.inf
203
204INF  MdeModulePkg/Universal/ReportStatusCodeRouter/RuntimeDxe/ReportStatusCodeRouterRuntimeDxe.inf
205INF  MdeModulePkg/Universal/StatusCodeHandler/RuntimeDxe/StatusCodeHandlerRuntimeDxe.inf
206INF  MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
207
208INF  MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
209INF  MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
210INF  MdeModulePkg/Universal/EbcDxe/EbcDxe.inf
211INF  OvmfPkg/8259InterruptControllerDxe/8259.inf
212INF  UefiCpuPkg/CpuIo2Dxe/CpuIo2Dxe.inf
213INF  UefiCpuPkg/CpuDxe/CpuDxe.inf
214INF  OvmfPkg/8254TimerDxe/8254Timer.inf
215INF  OvmfPkg/IncompatiblePciDeviceSupportDxe/IncompatiblePciDeviceSupport.inf
216INF  OvmfPkg/PciHotPlugInitDxe/PciHotPlugInit.inf
217INF  MdeModulePkg/Bus/Pci/PciHostBridgeDxe/PciHostBridgeDxe.inf
218INF  MdeModulePkg/Bus/Pci/PciBusDxe/PciBusDxe.inf
219INF  MdeModulePkg/Universal/ResetSystemRuntimeDxe/ResetSystemRuntimeDxe.inf
220INF  MdeModulePkg/Universal/Metronome/Metronome.inf
221INF  PcAtChipsetPkg/PcatRealTimeClockRuntimeDxe/PcatRealTimeClockRuntimeDxe.inf
222
223INF  OvmfPkg/VirtioPciDeviceDxe/VirtioPciDeviceDxe.inf
224INF  OvmfPkg/Virtio10Dxe/Virtio10.inf
225INF  OvmfPkg/VirtioBlkDxe/VirtioBlk.inf
226INF  OvmfPkg/VirtioScsiDxe/VirtioScsi.inf
227INF  OvmfPkg/VirtioRngDxe/VirtioRng.inf
228INF  OvmfPkg/XenIoPciDxe/XenIoPciDxe.inf
229INF  OvmfPkg/XenBusDxe/XenBusDxe.inf
230INF  OvmfPkg/XenPvBlkDxe/XenPvBlkDxe.inf
231
232!if $(SECURE_BOOT_ENABLE) == TRUE
233  INF  SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDxe.inf
234!endif
235
236INF  MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf
237INF  MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
238INF  MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
239INF  MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatformDxe.inf
240INF  MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf
241INF  MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf
242INF  MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf
243INF  MdeModulePkg/Universal/DriverHealthManagerDxe/DriverHealthManagerDxe.inf
244INF  MdeModulePkg/Universal/BdsDxe/BdsDxe.inf
245INF  MdeModulePkg/Application/UiApp/UiApp.inf
246INF  MdeModulePkg/Universal/DevicePathDxe/DevicePathDxe.inf
247INF  MdeModulePkg/Universal/PrintDxe/PrintDxe.inf
248INF  MdeModulePkg/Universal/Disk/DiskIoDxe/DiskIoDxe.inf
249INF  MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf
250INF  MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskDxe.inf
251INF  MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
252INF  MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBusDxe.inf
253INF  MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDiskDxe.inf
254INF  OvmfPkg/SataControllerDxe/SataControllerDxe.inf
255INF  MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AtaAtapiPassThru.inf
256INF  MdeModulePkg/Bus/Ata/AtaBusDxe/AtaBusDxe.inf
257INF  MdeModulePkg/Bus/Pci/NvmExpressDxe/NvmExpressDxe.inf
258INF  MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf
259INF  MdeModulePkg/Universal/SetupBrowserDxe/SetupBrowserDxe.inf
260INF  MdeModulePkg/Universal/DisplayEngineDxe/DisplayEngineDxe.inf
261INF  MdeModulePkg/Universal/MemoryTest/NullMemoryTestDxe/NullMemoryTestDxe.inf
262
263!if $(USE_LEGACY_ISA_STACK) == FALSE
264  INF  OvmfPkg/SioBusDxe/SioBusDxe.inf
265!ifndef $(SOURCE_DEBUG_ENABLE)
266  INF  MdeModulePkg/Bus/Pci/PciSioSerialDxe/PciSioSerialDxe.inf
267!endif
268  INF  MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf
269!else
270  INF  PcAtChipsetPkg/IsaAcpiDxe/IsaAcpi.inf
271  INF  IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/IsaBusDxe.inf
272!ifndef $(SOURCE_DEBUG_ENABLE)
273  INF  IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/IsaSerialDxe.inf
274!endif
275  INF  IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2keyboardDxe.inf
276!endif
277
278INF  MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf
279INF  OvmfPkg/SmbiosPlatformDxe/SmbiosPlatformDxe.inf
280
281INF  MdeModulePkg/Universal/Acpi/AcpiTableDxe/AcpiTableDxe.inf
282INF  OvmfPkg/AcpiPlatformDxe/AcpiPlatformDxe.inf
283INF  RuleOverride=ACPITABLE OvmfPkg/AcpiTables/AcpiTables.inf
284INF  MdeModulePkg/Universal/Acpi/S3SaveStateDxe/S3SaveStateDxe.inf
285INF  MdeModulePkg/Universal/Acpi/BootScriptExecutorDxe/BootScriptExecutorDxe.inf
286INF  MdeModulePkg/Universal/Acpi/BootGraphicsResourceTableDxe/BootGraphicsResourceTableDxe.inf
287
288INF  FatPkg/EnhancedFatDxe/Fat.inf
289INF  MdeModulePkg/Universal/Disk/UdfDxe/UdfDxe.inf
290
291!if $(TOOL_CHAIN_TAG) != "XCODE5"
292INF  ShellPkg/DynamicCommand/TftpDynamicCommand/TftpDynamicCommand.inf
293!endif
294INF  ShellPkg/Application/Shell/Shell.inf
295
296INF MdeModulePkg/Logo/LogoDxe.inf
297
298#
299# Network modules
300#
301!if $(E1000_ENABLE)
302  FILE DRIVER = 5D695E11-9B3F-4b83-B25F-4A8D5D69BE07 {
303    SECTION PE32 = Intel3.5/EFIX64/E3522X2.EFI
304  }
305!endif
306!include NetworkPkg/Network.fdf.inc
307  INF  OvmfPkg/VirtioNetDxe/VirtioNet.inf
308
309#
310# Usb Support
311#
312INF  MdeModulePkg/Bus/Pci/UhciDxe/UhciDxe.inf
313INF  MdeModulePkg/Bus/Pci/EhciDxe/EhciDxe.inf
314INF  MdeModulePkg/Bus/Pci/XhciDxe/XhciDxe.inf
315INF  MdeModulePkg/Bus/Usb/UsbBusDxe/UsbBusDxe.inf
316INF  MdeModulePkg/Bus/Usb/UsbKbDxe/UsbKbDxe.inf
317INF  MdeModulePkg/Bus/Usb/UsbMassStorageDxe/UsbMassStorageDxe.inf
318
319!ifdef $(CSM_ENABLE)
320INF  IntelFrameworkModulePkg/Csm/BiosThunk/VideoDxe/VideoDxe.inf
321INF  IntelFrameworkModulePkg/Csm/LegacyBiosDxe/LegacyBiosDxe.inf
322INF  RuleOverride=CSM OvmfPkg/Csm/Csm16/Csm16.inf
323!endif
324
325INF  OvmfPkg/QemuVideoDxe/QemuVideoDxe.inf
326INF  OvmfPkg/QemuRamfbDxe/QemuRamfbDxe.inf
327INF  OvmfPkg/VirtioGpuDxe/VirtioGpu.inf
328INF  OvmfPkg/PlatformDxe/Platform.inf
329INF  OvmfPkg/AmdSevDxe/AmdSevDxe.inf
330INF  OvmfPkg/IoMmuDxe/IoMmuDxe.inf
331
332!if $(SMM_REQUIRE) == TRUE
333INF  OvmfPkg/SmmAccess/SmmAccess2Dxe.inf
334INF  OvmfPkg/SmmControl2Dxe/SmmControl2Dxe.inf
335INF  UefiCpuPkg/CpuS3DataDxe/CpuS3DataDxe.inf
336INF  MdeModulePkg/Core/PiSmmCore/PiSmmIpl.inf
337INF  MdeModulePkg/Core/PiSmmCore/PiSmmCore.inf
338INF  UefiCpuPkg/CpuIo2Smm/CpuIo2Smm.inf
339INF  MdeModulePkg/Universal/LockBox/SmmLockBox/SmmLockBox.inf
340INF  UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.inf
341
342#
343# Variable driver stack (SMM)
344#
345INF  OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FvbServicesSmm.inf
346INF  MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteSmm.inf
347INF  MdeModulePkg/Universal/Variable/RuntimeDxe/VariableSmm.inf
348INF  MdeModulePkg/Universal/Variable/RuntimeDxe/VariableSmmRuntimeDxe.inf
349
350!else
351
352#
353# Variable driver stack (non-SMM)
354#
355INF  OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FvbServicesRuntimeDxe.inf
356INF  OvmfPkg/EmuVariableFvbRuntimeDxe/Fvb.inf
357INF  MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf
358INF  MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf
359!endif
360
361!if $(TPM2_ENABLE) == TRUE
362INF  SecurityPkg/Tcg/Tcg2Dxe/Tcg2Dxe.inf
363!if $(TPM2_CONFIG_ENABLE) == TRUE
364INF  SecurityPkg/Tcg/Tcg2Config/Tcg2ConfigDxe.inf
365!endif
366!endif
367
368################################################################################
369
370[FV.FVMAIN_COMPACT]
371FvNameGuid         = 48DB5E17-707C-472D-91CD-1613E7EF51B0
372FvAlignment        = 16
373ERASE_POLARITY     = 1
374MEMORY_MAPPED      = TRUE
375STICKY_WRITE       = TRUE
376LOCK_CAP           = TRUE
377LOCK_STATUS        = TRUE
378WRITE_DISABLED_CAP = TRUE
379WRITE_ENABLED_CAP  = TRUE
380WRITE_STATUS       = TRUE
381WRITE_LOCK_CAP     = TRUE
382WRITE_LOCK_STATUS  = TRUE
383READ_DISABLED_CAP  = TRUE
384READ_ENABLED_CAP   = TRUE
385READ_STATUS        = TRUE
386READ_LOCK_CAP      = TRUE
387READ_LOCK_STATUS   = TRUE
388
389FILE FV_IMAGE = 9E21FD93-9C72-4c15-8C4B-E77F1DB2D792 {
390   SECTION GUIDED EE4E5898-3914-4259-9D6E-DC7BD79403CF PROCESSING_REQUIRED = TRUE {
391     #
392     # These firmware volumes will have files placed in them uncompressed,
393     # and then both firmware volumes will be compressed in a single
394     # compression operation in order to achieve better overall compression.
395     #
396     SECTION FV_IMAGE = PEIFV
397     SECTION FV_IMAGE = DXEFV
398   }
399 }
400
401!include DecomprScratchEnd.fdf.inc
402
403################################################################################
404
405[Rule.Common.SEC]
406  FILE SEC = $(NAMED_GUID) {
407    PE32     PE32           $(INF_OUTPUT)/$(MODULE_NAME).efi
408    UI       STRING ="$(MODULE_NAME)" Optional
409    VERSION  STRING ="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
410  }
411
412[Rule.Common.PEI_CORE]
413  FILE PEI_CORE = $(NAMED_GUID) {
414    PE32     PE32   Align=Auto    $(INF_OUTPUT)/$(MODULE_NAME).efi
415    UI       STRING ="$(MODULE_NAME)" Optional
416    VERSION  STRING ="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
417  }
418
419[Rule.Common.PEIM]
420  FILE PEIM = $(NAMED_GUID) {
421     PEI_DEPEX PEI_DEPEX Optional        $(INF_OUTPUT)/$(MODULE_NAME).depex
422     PE32      PE32   Align=Auto         $(INF_OUTPUT)/$(MODULE_NAME).efi
423     UI       STRING="$(MODULE_NAME)" Optional
424     VERSION  STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
425  }
426
427[Rule.Common.DXE_CORE]
428  FILE DXE_CORE = $(NAMED_GUID) {
429    PE32     PE32           $(INF_OUTPUT)/$(MODULE_NAME).efi
430    UI       STRING="$(MODULE_NAME)" Optional
431    VERSION  STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
432  }
433
434[Rule.Common.DXE_DRIVER]
435  FILE DRIVER = $(NAMED_GUID) {
436    DXE_DEPEX    DXE_DEPEX Optional      $(INF_OUTPUT)/$(MODULE_NAME).depex
437    PE32     PE32                    $(INF_OUTPUT)/$(MODULE_NAME).efi
438    UI       STRING="$(MODULE_NAME)" Optional
439    VERSION  STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
440    RAW ACPI  Optional               |.acpi
441    RAW ASL   Optional               |.aml
442  }
443
444[Rule.Common.DXE_RUNTIME_DRIVER]
445  FILE DRIVER = $(NAMED_GUID) {
446    DXE_DEPEX    DXE_DEPEX Optional      $(INF_OUTPUT)/$(MODULE_NAME).depex
447    PE32     PE32                    $(INF_OUTPUT)/$(MODULE_NAME).efi
448    UI       STRING="$(MODULE_NAME)" Optional
449    VERSION  STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
450  }
451
452[Rule.Common.UEFI_DRIVER]
453  FILE DRIVER = $(NAMED_GUID) {
454    DXE_DEPEX    DXE_DEPEX Optional      $(INF_OUTPUT)/$(MODULE_NAME).depex
455    PE32     PE32                    $(INF_OUTPUT)/$(MODULE_NAME).efi
456    UI       STRING="$(MODULE_NAME)" Optional
457    VERSION  STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
458  }
459
460[Rule.Common.UEFI_DRIVER.BINARY]
461  FILE DRIVER = $(NAMED_GUID) {
462    DXE_DEPEX DXE_DEPEX Optional      |.depex
463    PE32      PE32                    |.efi
464    UI        STRING="$(MODULE_NAME)" Optional
465    VERSION   STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
466  }
467
468[Rule.Common.UEFI_APPLICATION]
469  FILE APPLICATION = $(NAMED_GUID) {
470    PE32     PE32                    $(INF_OUTPUT)/$(MODULE_NAME).efi
471    UI       STRING="$(MODULE_NAME)" Optional
472    VERSION  STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
473  }
474
475[Rule.Common.UEFI_APPLICATION.BINARY]
476  FILE APPLICATION = $(NAMED_GUID) {
477    PE32      PE32                    |.efi
478    UI        STRING="$(MODULE_NAME)" Optional
479    VERSION   STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
480  }
481
482[Rule.Common.USER_DEFINED.ACPITABLE]
483  FILE FREEFORM = $(NAMED_GUID) {
484    RAW ACPI               |.acpi
485    RAW ASL                |.aml
486  }
487
488[Rule.Common.USER_DEFINED.CSM]
489  FILE FREEFORM = $(NAMED_GUID) {
490    RAW BIN                |.bin
491  }
492
493[Rule.Common.SEC.RESET_VECTOR]
494  FILE RAW = $(NAMED_GUID) {
495    RAW BIN   Align = 16   |.bin
496  }
497
498[Rule.Common.SMM_CORE]
499  FILE SMM_CORE = $(NAMED_GUID) {
500    PE32     PE32           $(INF_OUTPUT)/$(MODULE_NAME).efi
501    UI       STRING="$(MODULE_NAME)" Optional
502    VERSION  STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
503  }
504
505[Rule.Common.DXE_SMM_DRIVER]
506  FILE SMM = $(NAMED_GUID) {
507    SMM_DEPEX    SMM_DEPEX Optional      $(INF_OUTPUT)/$(MODULE_NAME).depex
508    PE32     PE32                    $(INF_OUTPUT)/$(MODULE_NAME).efi
509    UI       STRING="$(MODULE_NAME)" Optional
510    VERSION  STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
511  }
512