Home | History | Annotate | Download | only in Armada
      1 #
      2 #  Copyright (C) Marvell International Ltd. and its affiliates
      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.Armada70x0_EFI]
     28 BaseAddress   = 0x00000000|gArmTokenSpaceGuid.PcdFdBaseAddress  # The base address of the Firmware in NOR Flash.
     29 Size          = 0x00400000|gArmTokenSpaceGuid.PcdFdSize         # The size in bytes of the FLASH Device
     30 ErasePolarity = 1
     31 
     32 # This one is tricky, it must be: BlockSize * NumBlocks = Size
     33 BlockSize     = 0x00001000
     34 NumBlocks     = 0x400
     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 
     52 0x00000000|0x000E6000
     53 gArmTokenSpaceGuid.PcdFvBaseAddress|gArmTokenSpaceGuid.PcdFvSize
     54 FV = 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 # DXE phase firmware volume
     69 [FV.FvMain]
     70 BlockSize          = 0x40
     71 NumBlocks          = 0         # This FV gets compressed so make it just big enough
     72 FvAlignment        = 8         # FV alignment and FV attributes setting.
     73 ERASE_POLARITY     = 1
     74 MEMORY_MAPPED      = TRUE
     75 STICKY_WRITE       = TRUE
     76 LOCK_CAP           = TRUE
     77 LOCK_STATUS        = TRUE
     78 WRITE_DISABLED_CAP = TRUE
     79 WRITE_ENABLED_CAP  = TRUE
     80 WRITE_STATUS       = TRUE
     81 WRITE_LOCK_CAP     = TRUE
     82 WRITE_LOCK_STATUS  = TRUE
     83 READ_DISABLED_CAP  = TRUE
     84 READ_ENABLED_CAP   = TRUE
     85 READ_STATUS        = TRUE
     86 READ_LOCK_CAP      = TRUE
     87 READ_LOCK_STATUS   = TRUE
     88 FvNameGuid         = 5eda4200-2c5f-43cb-9da3-0baf74b1b30c
     89 
     90   INF MdeModulePkg/Core/Dxe/DxeMain.inf
     91 
     92   # PI DXE Drivers producing Architectural Protocols (EFI Services)
     93   INF ArmPkg/Drivers/CpuDxe/CpuDxe.inf
     94   INF ArmPkg/Drivers/ArmGic/ArmGicDxe.inf
     95   INF ArmPkg/Drivers/TimerDxe/TimerDxe.inf
     96   INF ArmPkg/Drivers/GenericWatchdogDxe/GenericWatchdogDxe.inf
     97   INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
     98   INF MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
     99   INF MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
    100   INF MdeModulePkg/Universal/Variable/EmuRuntimeDxe/EmuVariableRuntimeDxe.inf
    101   INF EmbeddedPkg/EmbeddedMonotonicCounter/EmbeddedMonotonicCounter.inf
    102   INF EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf
    103   INF EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
    104   INF EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
    105   INF OpenPlatformPkg/Drivers/I2c/MvI2cDxe/MvI2cDxe.inf
    106   INF MdeModulePkg/Bus/I2c/I2cDxe/I2cDxe.inf
    107   INF OpenPlatformPkg/Drivers/I2c/Devices/MvEeprom/MvEeprom.inf
    108   INF OpenPlatformPkg/Drivers/Spi/MvSpiDxe.inf
    109   INF OpenPlatformPkg/Drivers/Spi/Devices/MvSpiFlash.inf
    110 
    111   # Network support
    112   INF MdeModulePkg/Universal/Network/SnpDxe/SnpDxe.inf
    113   INF MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf
    114   INF MdeModulePkg/Universal/Network/MnpDxe/MnpDxe.inf
    115   INF MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigDxe.inf
    116   INF MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf
    117   INF MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf
    118   INF MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Dxe.inf
    119   INF MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Dxe.inf
    120   INF MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf
    121   INF MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dxe.inf
    122   INF OpenPlatformPkg/Drivers/Net/MvMdioDxe/MvMdioDxe.inf
    123   INF OpenPlatformPkg/Drivers/Net/Phy/MvPhyDxe/MvPhyDxe.inf
    124   INF OpenPlatformPkg/Drivers/Net/Pp2Dxe/Pp2Dxe.inf
    125 
    126   # PciEmulation
    127   INF OpenPlatformPkg/Platforms/Marvell/PciEmulation/PciEmulation.inf
    128   INF MdeModulePkg/Bus/Pci/NonDiscoverablePciDeviceDxe/NonDiscoverablePciDeviceDxe.inf
    129 
    130   # SCSI
    131   INF MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBusDxe.inf
    132   INF MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDiskDxe.inf
    133 
    134   # SATA
    135   INF MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AtaAtapiPassThru.inf
    136   INF MdeModulePkg/Bus/Ata/AtaBusDxe/AtaBusDxe.inf
    137   INF OvmfPkg/SataControllerDxe/SataControllerDxe.inf
    138 
    139   # USB
    140   INF MdeModulePkg/Bus/Pci/XhciDxe/XhciDxe.inf
    141   INF MdeModulePkg/Bus/Usb/UsbBusDxe/UsbBusDxe.inf
    142   INF MdeModulePkg/Bus/Usb/UsbMassStorageDxe/UsbMassStorageDxe.inf
    143 
    144   # SD/MMC
    145   INF MdeModulePkg/Bus/Sd/EmmcDxe/EmmcDxe.inf
    146   INF MdeModulePkg/Bus/Sd/SdDxe/SdDxe.inf
    147   INF OpenPlatformPkg/Drivers/SdMmc/XenonDxe/SdMmcPciHcDxe.inf
    148 
    149   # Multiple Console IO support
    150   INF MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatformDxe.inf
    151   INF MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf
    152   INF MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf
    153   INF MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf
    154   INF MdeModulePkg/Universal/SerialDxe/SerialDxe.inf
    155 
    156   # Human interface
    157   INF MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf
    158 
    159   # FAT filesystem + GPT/MBR partitioning
    160   INF OpenPlatformPkg/Drivers/Block/ramdisk/ramdisk.inf
    161   INF MdeModulePkg/Universal/Disk/DiskIoDxe/DiskIoDxe.inf
    162   INF MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf
    163   INF FatBinPkg/EnhancedFatDxe/Fat.inf
    164   INF MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
    165 
    166   # UEFI application (Shell Embedded Boot Loader)
    167   INF EmbeddedPkg/Ebl/Ebl.inf
    168 
    169   # UEFI application (Shell Embedded Boot Loader)
    170   INF ShellPkg/Application/Shell/Shell.inf
    171 
    172   # Bds
    173   INF MdeModulePkg/Universal/DevicePathDxe/DevicePathDxe.inf
    174   INF MdeModulePkg/Universal/DisplayEngineDxe/DisplayEngineDxe.inf
    175   INF MdeModulePkg/Universal/SetupBrowserDxe/SetupBrowserDxe.inf
    176   INF IntelFrameworkModulePkg/Universal/BdsDxe/BdsDxe.inf
    177 
    178 
    179 # PEI phase firmware volume
    180 [FV.FVMAIN_COMPACT]
    181 FvAlignment        = 8
    182 FvForceRebase      = TRUE
    183 ERASE_POLARITY     = 1
    184 MEMORY_MAPPED      = TRUE
    185 STICKY_WRITE       = TRUE
    186 LOCK_CAP           = TRUE
    187 LOCK_STATUS        = TRUE
    188 WRITE_DISABLED_CAP = TRUE
    189 WRITE_ENABLED_CAP  = TRUE
    190 WRITE_STATUS       = TRUE
    191 WRITE_LOCK_CAP     = TRUE
    192 WRITE_LOCK_STATUS  = TRUE
    193 READ_DISABLED_CAP  = TRUE
    194 READ_ENABLED_CAP   = TRUE
    195 READ_STATUS        = TRUE
    196 READ_LOCK_CAP      = TRUE
    197 READ_LOCK_STATUS   = TRUE
    198 
    199   INF ArmPlatformPkg/PrePi/PeiMPCore.inf
    200 
    201   FILE FV_IMAGE = 9E21FD93-9C72-4c15-8C4B-E77F1DB2D792 {
    202     SECTION GUIDED EE4E5898-3914-4259-9D6E-DC7BD79403CF PROCESSING_REQUIRED = TRUE {
    203       SECTION FV_IMAGE = FVMAIN
    204     }
    205   }
    206 
    207 ################################################################################
    208 #
    209 # Rules are use with the [FV] section's module INF type to define
    210 # how an FFS file is created for a given INF file. The following Rule are the default
    211 # rules for the different module type. User can add the customized rules to define the
    212 # content of the FFS file.
    213 #
    214 ################################################################################
    215 
    216 
    217 ############################################################################
    218 # Example of a DXE_DRIVER FFS file with a Checksum encapsulation section   #
    219 ############################################################################
    220 #
    221 #[Rule.Common.DXE_DRIVER]
    222 #  FILE DRIVER = $(NAMED_GUID) {
    223 #    DXE_DEPEX    DXE_DEPEX               Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
    224 #    COMPRESS PI_STD {
    225 #      GUIDED {
    226 #        PE32     PE32                    $(INF_OUTPUT)/$(MODULE_NAME).efi
    227 #        UI       STRING="$(MODULE_NAME)" Optional
    228 #        VERSION  STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
    229 #      }
    230 #    }
    231 #  }
    232 #
    233 ############################################################################
    234 
    235 [Rule.ARM.SEC]
    236   FILE SEC = $(NAMED_GUID) RELOCS_STRIPPED {
    237     TE  TE    Align = 32                $(INF_OUTPUT)/$(MODULE_NAME).efi
    238   }
    239 
    240 # The AArch64 Vector Table requires a 2K alignment that is not supported by the FDF specification.
    241 # It is the reason 4K is used instead of 2K for the module alignment.
    242 [Rule.AARCH64.SEC]
    243   FILE SEC = $(NAMED_GUID) RELOCS_STRIPPED {
    244     TE  TE    Align = 4K                $(INF_OUTPUT)/$(MODULE_NAME).efi
    245   }
    246 
    247 [Rule.Common.PEI_CORE]
    248   FILE PEI_CORE = $(NAMED_GUID) {
    249     TE     TE                           $(INF_OUTPUT)/$(MODULE_NAME).efi
    250     UI     STRING ="$(MODULE_NAME)" Optional
    251   }
    252 
    253 [Rule.Common.PEIM]
    254   FILE PEIM = $(NAMED_GUID) {
    255      PEI_DEPEX PEI_DEPEX Optional       $(INF_OUTPUT)/$(MODULE_NAME).depex
    256      TE       TE                        $(INF_OUTPUT)/$(MODULE_NAME).efi
    257      UI       STRING="$(MODULE_NAME)" Optional
    258   }
    259 
    260 [Rule.Common.PEIM.TIANOCOMPRESSED]
    261   FILE PEIM = $(NAMED_GUID) DEBUG_MYTOOLS_IA32 {
    262     PEI_DEPEX PEI_DEPEX Optional        $(INF_OUTPUT)/$(MODULE_NAME).depex
    263     GUIDED A31280AD-481E-41B6-95E8-127F4C984779 PROCESSING_REQUIRED = TRUE {
    264       PE32      PE32                    $(INF_OUTPUT)/$(MODULE_NAME).efi
    265       UI        STRING="$(MODULE_NAME)" Optional
    266     }
    267   }
    268 
    269 [Rule.Common.DXE_CORE]
    270   FILE DXE_CORE = $(NAMED_GUID) {
    271     PE32     PE32                       $(INF_OUTPUT)/$(MODULE_NAME).efi
    272     UI       STRING="$(MODULE_NAME)" Optional
    273   }
    274 
    275 [Rule.Common.UEFI_DRIVER]
    276   FILE DRIVER = $(NAMED_GUID) {
    277     DXE_DEPEX    DXE_DEPEX              Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
    278     PE32         PE32                   $(INF_OUTPUT)/$(MODULE_NAME).efi
    279     UI           STRING="$(MODULE_NAME)" Optional
    280   }
    281 
    282 [Rule.Common.UEFI_DRIVER.BINARY]
    283   FILE DRIVER = $(NAMED_GUID) {
    284     DXE_DEPEX DXE_DEPEX Optional      |.depex
    285     PE32      PE32                    |.efi
    286     UI        STRING="$(MODULE_NAME)" Optional
    287     VERSION   STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
    288   }
    289 
    290 [Rule.Common.DXE_DRIVER]
    291   FILE DRIVER = $(NAMED_GUID) {
    292     DXE_DEPEX    DXE_DEPEX              Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
    293     PE32         PE32                   $(INF_OUTPUT)/$(MODULE_NAME).efi
    294     UI           STRING="$(MODULE_NAME)" Optional
    295   }
    296 
    297 [Rule.Common.DXE_RUNTIME_DRIVER]
    298   FILE DRIVER = $(NAMED_GUID) {
    299     DXE_DEPEX    DXE_DEPEX              Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
    300     PE32         PE32                   $(INF_OUTPUT)/$(MODULE_NAME).efi
    301     UI           STRING="$(MODULE_NAME)" Optional
    302   }
    303 
    304 [Rule.Common.UEFI_APPLICATION]
    305   FILE APPLICATION = $(NAMED_GUID) {
    306     UI     STRING ="$(MODULE_NAME)" Optional
    307     PE32   PE32                         $(INF_OUTPUT)/$(MODULE_NAME).efi
    308   }
    309