Commit Graph

673 Commits

Author SHA1 Message Date
Lakkimsetti, Subash 13f05b3e89 [ADL][RPL] Initialize TPM and Measured boot with btg profile 0
TPM is intialized by ACM with profiles 3 & 5.
This patch enables the TPM in bootloader when boot guard
is not enabled. HAVE_MEASURED_BOOT in platform
board config controls the TPM in SBL.

Signed-off-by: Subash Lakkimsetti <subash.lakkimsetti@intel.com>
2022-09-06 09:28:23 -07:00
tsaikevin c3e42632ba
[ADLPS] UPD config update (#1680)
Added UPD Ddr4OneDpc in DLT file and removed hard coded value.

Signed-off-by: Kevin Tsai <kevin.tsai@intel.com>

Signed-off-by: Kevin Tsai <kevin.tsai@intel.com>
2022-09-02 07:36:47 -04:00
Kevin Tsai aef46f64a7 [ADLPS] UPD config update
Aligned FSPM and FSPS UPD settings with BIOS

Signed-off-by: Kevin Tsai <kevin.tsai@intel.com>
2022-09-01 16:10:24 -07:00
Sindhura Grandhi 4293c38c77
[ADLPS] Add GPIO table for PS CRB for reference. (#1678)
Add the hard-coded GPIO table to the header file for reference purposes.
This table is currently part of the configuration.

Signed-off-by: Sindhura Grandhi <sindhura.grandhi@intel.com>

Signed-off-by: Sindhura Grandhi <sindhura.grandhi@intel.com>
2022-09-01 14:24:54 -07:00
Sindhura Grandhi 073e8a9147
[ADL] Memory FSP settings cleanup (#1674)
Signed-off-by: Sindhura Grandhi <sindhura.grandhi@intel.com>

Signed-off-by: Sindhura Grandhi <sindhura.grandhi@intel.com>
2022-08-30 15:52:44 -07:00
Stanley Chang f4aeac41cc [TGL] Init EC CPU fan control
Without initializing CPU fan control, EC will stop CPU fan after default
timeout. This patch initializes CPU fan control and fail safe control.

Some scenarios are related to the case: (1) bootloader shell;
(2) unexpected hang; (3) OS with no ACPI support; and (4) OS fails to
load ACPI driver

Test methods:
1. monitor CPU fan under SBL / UEFI Payload shell: expect non-stop
2. check CPU fan status after Linux starts: expect ACPI controls it

Verified: TGL RVP

Signed-off-by: Stanley Chang <stanley.chang@intel.com>
2022-08-24 09:06:08 -07:00
Sean McGinn f7a524fa1b Add comment regarding TCO timer initialization
Signed-off-by: Sean McGinn <sean.mcginn@intel.com>
2022-08-23 14:50:23 -07:00
Sean McGinn 82274c1567 Add SBL Resiliency Support to ADL-N
Signed-off-by: Sean McGinn <sean.mcginn@intel.com>
2022-08-23 14:50:23 -07:00
Sindhura Grandhi 9361ac2d57
[ADLP] Fix build issue (#1667)
Signed-off-by: Sindhura Grandhi <sindhura.grandhi@intel.com>

Signed-off-by: Sindhura Grandhi <sindhura.grandhi@intel.com>
2022-08-19 15:01:33 -07:00
Ong Kok Tong ba6837ffb6 [ADLPS] CRB PV release update
1. Update BoardID and PlatformID for CRB board
2. Direct return after read board id from smbus to avoid boardid clashing
3. Added ddi config for CRB board
4. Update FSPM UPD due to common value across all sku

Signed-off-by: Ong Kok Tong <kok.tong.ong@intel.com>
2022-08-19 12:01:51 -07:00
Sean McGinn 1e677e5a4d Update full FW update status structure on recovery
This change makes sure that, during each recovery,
the FW update status structure is cleared and
repopulated

Without this change, in the event that there is
a full recovery and then an interrupted recovery,
the interrupted recovery is unable to resume

Signed-off-by: Sean McGinn <sean.mcginn@intel.com>
2022-08-17 11:40:43 -07:00
Sean McGinn eeb05a8a5e Add SBL resiliency common code
This change adds SBL resiliency-related code
to common SG1A, SG1B, SG02, and FWU code

Signed-off-by: Sean McGinn <sean.mcginn@intel.com>
2022-08-17 11:40:43 -07:00
M Karuppasamy 5cea7fbbf3 GPIO shell command for ADL platform
This patch supports GPIO read and write through shell command.

Signed-off-by: M Karuppasamy <karuppasamy.m@intel.com>
Signed-off-by: Sachin Kamat <sachin.kamat@intel.com>
Signed-off-by: Akshatha Thekkade <akshatha.thekkade@intel.com>
2022-08-17 11:37:28 -07:00
koktong-ong 387f4a8aaa
[ADL] Clear RTC EN SCI to avoid interrupt storming (#1661)
Clear the RTC EN SCI flag to avoid interrupt storming
that cause system hang when using rtcwake method to perform
powre management test

Signed-off-by: Ong Kok Tong <kok.tong.ong@intel.com>

Signed-off-by: Ong Kok Tong <kok.tong.ong@intel.com>
2022-08-12 10:21:36 -07:00
Randy Lin a1117575ac [EHL] UPDs for Zephyr support
1. Expose PchPseEcliteEnabled
2. PchPseSpiCs1Enable is unconfigurable, fix it.

Signed-off-by: Randy Lin <randy.lin@intel.com>
2022-08-12 08:46:36 -07:00
Sindhura Grandhi 9537bda97d [ADLS] Update FSP/VBT/UCODE/platform version since MR2 is released
- FSP version - 0C.00.69.74
- Vbt version - 1077
- Microcode version - m_07_90672_00000023
- Minor version updated to '2' for MR2.

Signed-off-by: Sindhura Grandhi <sindhura.grandhi@intel.com>
2022-08-12 08:38:25 -07:00
Sindhura Grandhi bf9ab4299f [ADLS] Tcc related fixes
- Increase PlatformMemorySize to get rid of FSP error caused
during Tcc SRAM init.
- Sort the CPUs in ascending order for Tcc validation purpose.

Signed-off-by: Sindhura Grandhi <sindhura.grandhi@intel.com>
2022-08-08 13:34:22 -07:00
Bejean Mosher 5b451b6fca [RPL-P] RPL-P DDR5 RVP Board/Platform ID support.
Added support for RPL-P DDR5 RVP board ID from EC.

Signed-off-by: Bejean Mosher <bejean.mosher@intel.com>
2022-08-07 17:21:57 -07:00
Guo Dong 49e23bb324 [RPLP] Add RPL-P PR01 board support
Signed-off-by: Guo Dong <guo.dong@intel.com>
2022-08-05 14:01:10 -07:00
Guo Dong 7440dec946 [CFL] Increase payload size
Increase the payload size to fix the build failure.

Signed-off-by: Guo Dong <guo.dong@intel.com>
2022-08-02 07:42:55 -07:00
Guo Dong 77cbf823bf [TESTS] Use GPIO table from config data
Use the GPIO table from SBL config data instead of
the one from .h file. the .h file will keep there
a while just for reference.

Signed-off-by: Guo Dong <guo.dong@intel.com>
2022-08-01 21:39:13 -07:00
Guo Dong 58d265f553 [TESTS] payload switch GPIO
Use a on board switch (Pin B3) as the GPIO to switch
UEFI payload and OsLoader. So update its setting as
GPIO IN for this purpose.

Signed-off-by: Guo Dong <guo.dong@intel.com>
2022-08-01 21:39:13 -07:00
Guo Dong 90e917e62b Enhance GPIO convert tool for GPD group support
For PAD name (e.g., GPD12), current GpioDataConvert.py get the
pad number using pad_name[4:6]. It should be changed to pad_name[3:5].

Signed-off-by: Guo Dong <guo.dong@intel.com>
2022-08-01 21:38:49 -07:00
Ong Kok Tong a5b2581f41 [ADLPS] Remove PlatformNvs parameters
Current PlatformNvs parameters are causing the power management
(S3, S4 and S5) in Windows OS. Removing the Nvs parameters will fixed
the issues.

Signed-off-by: Ong Kok Tong <kok.tong.ong@intel.com>
2022-08-01 21:17:49 -07:00
Guo Dong 0c1092528a [ADL] Remove duplicated S3 code
Restore SMM registers was done in the PostPciEnumeration.
so remove the duplicated code in EndOfStages
and call ClearS3SaveRegion() in normal path to avoid
appending multiple restore records.

Signed-off-by: Guo Dong <guo.dong@intel.com>
2022-08-01 18:11:09 -07:00
Gavin Xue ac08bd1209 [EHL] Fix incorrect PSE DMA2 BAR in ACPI code
Signed-off-by: Gavin Xue <gavin.xue@intel.com>
2022-07-30 16:48:31 -07:00
Bejean Mosher 5fe393da46 [ADL] Fix for THC1 PEP constraints appearing when device is disabled.
FSP-S UPD format for THC port assignment was updated, but PEP logic
was using the old format, and causing the PEP constraint to always be
enabled. This issue didn't seem to be causing a problem, but resulted
in noncompliant low power idle constraints.

Signed-off-by: Bejean Mosher <bejean.mosher@intel.com>
2022-07-29 12:09:08 -07:00
Aakash Panwar 4e16fe4c6b Fix build issues due to increased payload and image size.
This Patch fix the build issues due to the increased payload and image size
in windows and linux environment.
- Fixed PAYLOAD size greater than padding size issue for CML.
- Fixed FWUPDATE size greater than padding size issue for EHL.
- Fixed FV image size issue for CMLV,TGL,EHL and ADLS.

Signed-off-by: Aakash Panwar <aakash.panwar@intel.com>
2022-07-29 11:13:30 -07:00
Sindhura Grandhi 676c1b93a1 [ADLP] Upstream Build/Stitch/Cfgdata
This patch will let ADLP project to build and stitch images from
open source.

TEST = Smoke-test to boot to Windows/Yocto

Signed-off-by: Sindhura Grandhi <sindhura.grandhi@intel.com>
2022-07-28 15:10:54 -07:00
Bejean Mosher 3fe4087e70 [ADL-P] Revert USB4 CM mode to FW CM only.
Previous setting of SW-first CM mode was causing a hang during S3/S4 entry. Likely this setting requires additional ACPI/driver support which is missing.

Signed-off-by: Bejean Mosher <bejean.mosher@intel.com>
2022-07-27 10:56:43 -07:00
Bejean Mosher 15d7abd016 [ADL-N/P/PS] Workaround for S4 resume when S0ix disabled.
Remove OS version check in PEPD _STA method. This is a change to the intelpep.sys ASL device (PEPD) for low power idle support. Previously, _STA would always return present/enabled for Win10 even if S0ix config flag was disabled. Changed version always returns status based on S0ix flag. Without this workaround, S4 resume was failing on ADL-N/P/PS.

Signed-off-by: Bejean Mosher <bejean.mosher@intel.com>
2022-07-27 10:55:05 -07:00
Guo Dong 69fb535cc5 [TESTS] revert the premem gpio change for S17 board
Premem GPIO table for S17 board caused boot hang,
so revert the change back.

Signed-off-by: Guo Dong <guo.dong@intel.com>
2022-07-23 00:34:44 -07:00
Guo Dong 4ce3649eb1 [TEST-S] Update GPIO for test boards
Use the GPIO table for the test boards.
This change would help fix PCIe device detection from PCIe slot.
Late would change post memory gpio table to SBL cfg data.

Signed-off-by: Guo Dong <guo.dong@intel.com>
2022-07-22 16:05:49 -07:00
Guo Dong 8763f1e5fa [TESTS] Fix PCIE device detection issue
The PCIE device could not be detected without this change.

Signed-off-by: Guo Dong <guo.dong@intel.com>
2022-07-22 16:05:49 -07:00
Vincent Chen 1de595d3e0 [EHL] Update StitchIfwi.py and StitchIfwiConfig.py
- skip the component replacemnt if the component is not located in SBL image
- print the skipped replacement components
- indicate failure through exit status for easily diagnosing problems
  when checking stitch config parameters
- add required flash image region 5=EC for new FIT (15.40.26.2632)
- remove 'sata' stitch option since it is no function

Signed-off-by: Vincent Chen <vincent.chen@intel.com>
2022-07-22 10:26:40 -07:00
Sindhura Grandhi 09d45b857c [ADLN] Gpio Cfg data from dlt file
- Process Gpio Cfg data from the dlt file instead of the hard-coded
  GPIO table.
- The table in the PostMem hdr file is only for reference.

Signed-off-by: Sindhura Grandhi <sindhura.grandhi@intel.com>
2022-07-22 10:06:11 -07:00
Stanley Chang 625abcb2bd [Tools] Enhance GpioDataConvert to support GPD
The patch adds support of "GPD" group when parsing a .h header file.
It also
  - adds supports for Pch-N,
  - fixes leading whitespaces in h file.

Test commands:

  # h to dlt
  $ python Platform/CommonBoardPkg/Tools/GpioDataConvert.py \
      -cf Platform/AlderlakeBoardPkg/Script/GpioDataConfig.py \
      -if example_adls.h -of dlt -p s \
      -o out_adls.dlt

  # h to yaml
  $ python Platform/CommonBoardPkg/Tools/GpioDataConvert.py \
      -cf Platform/AlderlakeBoardPkg/Script/GpioDataConfig.py \
      -if example_adls.h -of yaml -p s \
      -o out_adls.yaml

  # yaml to h
  $ python Platform/CommonBoardPkg/Tools/GpioDataConvert.py \
      -cf Platform/AlderlakeBoardPkg/Script/GpioDataConfig.py \
      -if out_adls.yaml -of h -p s \
      -o out_h_from_yaml.h

  # dlt to h
  $ python Platform/CommonBoardPkg/Tools/GpioDataConvert.py \
      -cf Platform/AlderlakeBoardPkg/Script/GpioDataConfig.py \
      -if out_adls.yaml -of h -p s \
      -o out_h_from_dlt.h
  # check: compare example_adls.h and out_h_from_dlt.h

  # yaml to txt
  $ python Platform/CommonBoardPkg/Tools/GpioDataConvert.py \
      -cf Platform/AlderlakeBoardPkg/Script/GpioDataConfig.py \
      -if out_adls.yaml -of txt -p s \
      -o out_txt_from_yaml.txt

  # dlt to txt
  $ python Platform/CommonBoardPkg/Tools/GpioDataConvert.py \
      -cf Platform/AlderlakeBoardPkg/Script/GpioDataConfig.py \
      -if out_adls.dlt -of txt -p s \
      -o out_txt_from_dlt.txt

Signed-off-by: Stanley Chang <stanley.chang@intel.com>
2022-07-20 08:29:07 -07:00
Stanley Chang f61bb6c116 FWU: support OEM key revocation together with BIOS/CSME update
The steps of OEM key revocation are:
  1. Replace OEM KM (signed with key2) by updating CSME
  2. Replace BIOS region (signed with key2)
  3. Reboot with new BIOS region (to make key1 inactive)
  4. Revoke key1

Before this patch, it requires 2 firmware updates and 2 capsules for
step 1~2 and step 4 respectively. The patch combines them into a single
update/capsule.

To implement the feature, the patch:
  1. Double max # of payloads to allow CSME/CSMD/BIOS/CMDI update
     in one capsule image.
  2. Prevent from failing update of a critical component.
     e.g., if step 1(CSME) fails, step 2(BIOS) should be skipped

Verified cases:

 Case 1: Capsule having CSMD/CSMD/BIOS/CMDI.
         Expectation: successful

    $ python BootloaderCorePkg/Tools/GenCapsuleFirmware.py \
      -p CSME FWUpdate.bin \
      -p CSMD CsmeUpdateDriver.efi \
      -p BIOS new_BiosRegion.bin \
      -p CMDI cmdi.txt \
      ...(skip)

 Case 2: Capsule having CSME/BIOS/CMDI but no CSMD.
         Expectation: no update

 Case 3: Inject fault flow (no partition switch after first flash),
         Capsule having CSME/CSMD/BIOS/CMDI.
         Expectation: no CMDI update

Verification: EHL CRB

Signed-off-by: Stanley Chang <stanley.chang@intel.com>
2022-07-19 15:31:23 -07:00
Vincent Chen 3112989fdc [EHL] Update FSP/VBT/UCODE/platform version since MR4 is released
- update FSP version to MR4 FSP (09.04.25.11)
- update VBT version to MR4 FSP (244)
- update microcode version to 16
- update EHL platform version to 1.4

Signed-off-by: Vincent Chen <vincent.chen@intel.com>
2022-07-19 15:02:55 -07:00
Gavin Xue f5e230ca7c [EHL] Fix Kernel DMA driver cannot be registered issue
EHL DMA controllers are hidden at PSF level in reference code,
DMA controllers are reported as ACPI devices if ownership is Host.
So should not check DMA PCI header for DSDT table patching.
Update the change follow EHL reference code.

Signed-off-by: Gavin Xue <gavin.xue@intel.com>
2022-07-15 14:56:35 -07:00
Aiman Rosli bd05d78232 [EHL] Enable WDT for TCC
When some settings from DSO caused system hang,
the WDT would cause the system reboot.
And in the next boot, SBL would use the default
setting by not apply the DSO values.

Verify on EHL CRB.

Signed-off-by: Aiman Rosli <muhammad.aiman.rosli@intel.com>
2022-07-15 14:52:56 -07:00
Randy Lin a5dffd1171 [TGL] Ignore TCC DSO tuning on FW update process
Verify on TGL-UP3 RVP.

Signed-off-by: Randy Lin <randy.lin@intel.com>
2022-07-14 14:40:54 -07:00
Kevin Tsai 7c584d8059 [ADLN] UPD config update
Aligned FSPS UPD settings with BIOS

Signed-off-by: Kevin Tsai <kevin.tsai@intel.com>
2022-07-13 16:42:36 -07:00
Ong Kok Tong c326806ca3 [ADLN] IT8659 Sio DTT porting
1. Ported IT8659 Sio (Super IO) and DTT (Dynamic Tuning Technology)
for ADL platform
2. Added CfgData to disable or enable the SIO feature
3. Fixed warning for Linux gcc bug -Wmissing-braces in SioChip.c

Signed-off-by: Ong Kok Tong <kok.tong.ong@intel.com>
2022-07-11 08:21:32 -07:00
Vincent Chen 350a4436a5 [TGL] Update FSP/VBT/UCODE/platform version since MR6 is released
- update FSP version to IoT FSP 5143_01_MR6 (0A.00.7B.31)
- update VBT version to IoT FSP 5143_01_MR6 (250)
- update TGLU microcode version to A4
- update TGL platform version to 1.6

Signed-off-by: Vincent Chen <vincent.chen@intel.com>
2022-07-06 17:49:02 -07:00
Sindhura Grandhi 453ee0f24e
[ADLS] Disable DAM by default (#1613)
Signed-off-by: Sindhura Grandhi <sindhura.grandhi@intel.com>
2022-07-01 16:25:20 -07:00
Randy Lin ec5b20288b [EHL] Enable Ubuntu boot support
verified on EHL CRB with ubuntu 20.04.

Signed-off-by: Randy Lin <randy.lin@intel.com>
2022-06-30 10:26:00 -07:00
Sindhura Grandhi f1b0dd123f [ADLN] TSN enabling
Signed-off-by: Sindhura Grandhi <sindhura.grandhi@intel.com>
2022-06-28 15:10:39 -07:00
Aiman Rosli 7132f14a1d [Common][EHL] Adding SMBIOS Type3
Updating SMBIOS Type3 on Common package and EHL package.

Signed-off-by: Aiman Rosli <muhammad.aiman.rosli@intel.com>
2022-06-27 10:47:05 -07:00
jinjhuli f63de36c45 [ADLP] Enable GrpIdx overwrite capability
Enable GrpIdx overwrite capability when using
Config Editor tool.

Signed-off-by: jinjhuli <jin.jhu.lim@intel.com>
2022-06-27 10:34:03 -07:00