Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x86 fsp backport #443

Merged
merged 96 commits into from May 9, 2024
Merged

x86 fsp backport #443

merged 96 commits into from May 9, 2024

Conversation

rizlik
Copy link
Contributor

@rizlik rizlik commented Apr 24, 2024

  • port of improvements and bugfix of x86 FSP code
  • cleaning of qemu x86 fsp scripts and documentation
    notes:
  • last "pure" backport commit is: 09a2c21

(non-complete) list of commits that may have side-effects out of x86 fsp context:

rizlik and others added 23 commits April 23, 2024 10:41
If CPU enter a triple fault, it goes in shutdown mode and the reset vector is
invoked again, without a proper PLTRST#. MemoryInit API fails in this
case. Check if CPU is in shutdown mode and reset the platform if so.
Copy link
Member

@danielinux danielinux left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please remove the tools/x86_fsp, tools/tgl, tools/qemu directories and move them under tools/scripts as we discussed. Adjust paths in the doc accordingly.

the function relies a non-general delay() function, so move the function in a
more target-specific file.
@rizlik rizlik requested a review from danielinux April 30, 2024 08:17
Copy link
Member

@danielinux danielinux left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well done, the port seems very clean. Could possibly use more documentation e.g. on the ATA state machine and other internals. Added config options should be covered in docs/

src/x86/ahci.c Show resolved Hide resolved
src/x86/ahci.c Show resolved Hide resolved
tools/tpm/policy_sign.c Show resolved Hide resolved
@rizlik rizlik requested a review from danielinux May 2, 2024 14:26
Copy link
Member

@danielinux danielinux left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for adding the docs. A few minor typos/rewording.


## Disabling the password

If you need to disable the password, a master password should be already set on the device. Then you can use the following option to compile wolfBoot so that it will disable the password from the drive and panic:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

s/option/options

If the ATA disk has no password set, the disk will be locked with the password provided at the first boot.

## Unlocking the Disk with a TPM-Sealed Secret
wolfBoot allows to seal secret safely in the TPM in a way that it can be unsealed only under specific conditions. Please refer to files TPM.md and measured_boot.md for more information. If the option `WOLFBOOT_TPM_SEAL` is enabled and `DISK_LOCK` is enabled, wolfBoot will use a TPM sealed secret as the password to unlock the disk. The following options controls the sealing and unsealing of the secret:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the options WOLFBOOT_TPM_SEAL and DISK_LOCK are enabled, wolfboot uses

@rizlik rizlik requested a review from danielinux May 8, 2024 07:40
@@ -0,0 +1,132 @@
/* stage2_params.h
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

stage2_params.c

src/x86/gpt.c Show resolved Hide resolved

#ifdef PLATFORM_x86_fsp_qemu

#include<printf.h>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add space. #include <printf.h>

@dgarske dgarske self-requested a review May 9, 2024 14:43
Copy link
Member

@danielinux danielinux left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good now.

@dgarske dgarske merged commit 027c684 into master May 9, 2024
87 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants