Kabylake Intel(R) Firmware Support Package (FSP) Integration Guide
|
DoxygenFspIntegrationGuide.h
Go to the documentation of this file.
26 The purpose of this document is to describe the steps required to integrate the Intel® Firmware
27 Support Package (FSP) into a boot loader solution. It supports Kabylake platforms with Kabylake/Skylake
32 in their boot loader solutions. This includes, but is not limited to: system BIOS developers, boot
36 - *Platform Initialization (PI) Specification v1.4* located at http://www.uefi.org/specifications
38 - *Intel® Firmware Support Package: External Architecture Specification (EAS) v2.0* located at
39 http://www.intel.com/content/dam/www/public/us/en/documents/technical-specifications/fsp-architecture-spec-v2.pdf
40 - *Boot Setting File Specification (BSF) v1.0* https://firmware.intel.com/sites/default/files/BSF_1_0.pdf
41 - *Binary Configuration Tool for Intel® Firmware Support Package* available at http://www.intel.com/fsp
71 The *Intel® Firmware Support Package (FSP)* provides chipset and processor initialization in a
77 FSP is not a stand-alone boot loader; therefore it needs to be integrated into a host boot loader
81 The FSP binary can be integrated easily into many different boot loaders, such as Coreboot, EDKII etc.
87 The static FSP configuration parameters are part of the FSP binary and can be customized by external
91 The FSP is not Position Independent Code (PIC) and the whole FSP has to be rebased if it is placed
95 Once the FSP binary is ready for integration, the boot loader build process needs to be modified to
99 The boot loader needs to add code to setup the operating environment for the FSP, call the FSP with
100 correct parameters and parse the FSP output to retrieve the necessary information returned by the FSP.
129 The FSP for the Kabylake platform is built with a preferred base address of 0xFFF40000 and so the
130 reference code provided in the document assumes that the FSP is placed at this base address during
138 Please refer Chapter 7 in the FSP External Architecture Specification version 2.0 for Boot flow chart.
143 is documented in the FSP External Architecture Specification version 2.0 with a HeaderRevision of 3.
147 identification and revision information of the FSP binary. It is important to verify these fields
149 All the FSP FV segments(FSP-T, FSP-M and FSP-S) must have same FSP Image ID and revision number,
154 The current FSP ImageId string in the FSP information header is <strong>$KBLFSP$</strong> and the
158 FSP uses some amount of TempRam area to store FSP global data which contains some critical data like
159 pointers to FSP information headers and UPD configuration regions, FSP/Bootloader stack pointers
160 required for stack switching etc. HPET Timer register(2) 0xFED00148 is reserved to store address
162 If TempRAM initialization is done by boot loader, then HPET has to be initialized to the base so
175 Please refer Chapter 8.5 in the FSP External Architecture Specification version 2.0 for complete
179 returns ECX pointing to beginning of temporary memory and EDX pointing to end of temporary memory + 1.
181 0xFEF0_0000(ECX) to 0xFEF3_FF00(EDX) is usable area for both bootloader and FSP binary, remaining
182 0x100 bytes of space reserved by FSP for TempRamInit if temporary RAM initialization is done by FSP.
184 **TempRamInit** also sets up the code caching of the region passed CodeCacheBase and CodeCacheLength,
185 which are input parameters to TempRamInitApi. if 0 is passed in for CodeCacheBase, the base used will
187 @note: when programming MTRR CodeCacheLength will be reduced, if SKU LLC size is smaller than the requested.
189 It is a requirement for Firmware to have Firmware Interface Table (FIT), which contains pointers to
194 **FSPT_UPD.MicrocodeRegionBase** and **FSPT_UPD.MicrocodeRegionLength** are input parameters to TempRamInit API.
195 If these values are 0, FSP will not attempt to update microcode. If a region is passed, then if a newer
209 The **FspmUpdPtr** is pointer to **FSPM_UPD** structure which is described in header file FspmUpd.h.
211 Boot Loader must pass valid CAR region for FSP stack use through **FSPM_UPD.FspmArchUpd.StackBase**
214 The minimum FSP stack size required for this revision of FSP is 160KB, stack base is 0xFEF17F00 by default.
216 The base address of HECI device (Bus 0, Device 22, Function 0) is required to be initialized prior
219 Calculate memory map determining memory regions TSEG, IED, GTT, BDSM, ME stolen, Uncore PMRR, IOT,
226 If Boot Loader initializes the Temporary RAM (CAR) and skip calling **TempRamInit API**, it is expected that
227 bootloader must skip calling this API and bootloader will tear down the temporary memory area setup in the
233 At the end of *TempRamExit* the original code and data caching are disabled. FSP will reconfigure all MTRRs
243 If the boot loader wish to reconfigure the MTRRs differently, it can be overridden immediately after this API call.
249 The *FspsUpdPtr* is pointer to **FSPS_UPD** structure which is described in header file FspsUpd.h.
251 It is expected that boot loader will program MTRRs for SBSP as needed after **TempRamExit** but before
256 is important to bootloader, then bootloader needs to preserve it before calling FspSilicionInit.
258 It is a requirement for bootloader to have Firmware Interface Table (FIT), which contains pointers
277 but this HOB will not be published during S3 resume as FSP will not launch the PEI Graphics PEIM
284 On normal boot CPU S3 Resume Data HOB is produced in this phase. This CPU S3 Resume Data HOB is described
285 in section 4.4. Unless UPD SkipMpInit is enabled, on S3 resume, this data (not the entire HOB) must be passed through
286 UPD CpuS3ResumeData, and optionally final S3 boot MTRRs is passed through UPD CpuS3ResumeMtrrData. During S3
287 resume unless SkipMpInit is enabled, GDT base and length and IDT base and length on APs are programmed
300 This phase *EnumInitPhaseReadyToBoot* is to be called before giving control to boot. It includes some
301 final initialization steps recommended by the BWG, including power management settings, Send ME Message
305 This phase *EnumInitEndOfFirmware* is to be called before the firmware/preboot environment transfers
306 management of all system resources to the OS or next level execution environment. It includes final locking
317 FSP 2.0 introduced EndOfFirmware Notify phase callback which is a recommended place for locking PAM registers
318 so FSP by default implemented this way. If it is still too early to lock PAM registers then the PAM locking code
319 inside FSP can be disabled by UPD -> FSP_S_TEST_CONFIG -> SkipPamLock or SA policy -> _SI_PREMEM_POLICY_STRUCT
320 -> SA_MISC_PEI_CONFIG -> SkipPamLock, and platform or wrapper code should do the PAM locking right before booting
323 This PAM locking step has to been applied in all boot paths including S3 resume.To lock PAM regsiter:
330 Since SMRAM locking is recommended to be locked before any 3rd party OpROM execution and highly depending on platform code implementation, the FSP code by default will not lock it.
331 The platform or FSP Wrapper code should lock SMRAM by below programming step before any 3rd partiy OpRom execution (and should be locked in S3 resume right before OS waking vector).
333 PciOr8 (B0: D0: F0: Register 0x88, BIT4); Note: it must be programmed by CF8/CFC Standard PCI access mechanism. (MMIO access will not work)
337 Global SMI bit is recommended to be locked before any 3rd party OpROM execution and highly depending on platform code implementation after SMM configuration. FSP by default will not lock it.
354 - It is recommended that you do not change these settings as it may require significant changes to the System Agent reference code.\n
355 - Those memory regions should be reserved from any memory service functions in platform code so it will not cause any conflict when other modules or drivers allocating memory resource.
356 - Boot Loader can use different value for PCIEXBAR_BASE_ADDRESS either by modifying the UPD (under FSP-T) or by overriding the PCIEXBAR (B0:D0:F0:R60h) before calling FspMemoryInit Api.
357 - Boot Loader should avoid using conflicting address when reprogramming PCIEXBAR_BASE_ADDRESS than the recommended one.
360 As per FSP External Architecture Specification version 2.0, Any reset required in the FSP flow will
361 be reported as return status FSP_STATUS_RESET_REQUIREDx by the API.It is the bootloader responsibility to reset the system according to the reset type requested.
369 0x40000003 | Global Reset - Puts the system to Global reset through Heci or Full Reset through PCH
381 Elements specification for PI Architectural HOBs.Please refer Chapter 9 in the FSP External Architecture
397 by the bootloader to produce the SMBIOS tables. These structures are included as part of MemInfoHob.h , SmbiosCacheInfoHob.h & SmbiosProcessorInfoHob.h.
408 UINT8 ModulePartNum[20]; ///< Module part number for DDR3 is 18 bytes however for DRR4 20 bytes as per JEDEC Spec, so reserving 20 bytes
410 UINT8 SpdDramDeviceType; ///< Save SPD DramDeviceType information needed for SMBIOS structure creation.
412 UINT8 SpdModuleMemoryBusWidth; ///< Save SPD ModuleMemoryBusWidth information needed for SMBIOS structure creation.
413 UINT8 SpdSave[MAX_SPD_SAVE_DATA]; ///< Save SPD Manufacturing information needed for SMBIOS structure creation.
537 The FSP will report the ChipsetInit CRC through a HOB with below GUID. This information can be consumed
538 by the bootloader to check if ChipsetInit CRC is matched between BIOS and ME. These structures are included
546 /// The ChipsetInit Info structure provides the information of ME ChipsetInit CRC and BIOS ChipsetInit CRC.
558 The FSP will report the CPU S3 Resume Data through a GUIDED HOB with below GUID. This data (not the entire HOB) must be passed during S3 resume passed
569 The FSP outputs 16 bit postcode to indicate which API and in which module the execution is happening.
Generated on Thu Jun 28 2018 21:44:49 for Kabylake Intel(R) Firmware Support Package (FSP) Integration Guide by 1.8.10