Commit Graph

7 Commits

Author SHA1 Message Date
Sergii Dmytruk
96a094d553 MdeModulePkg/Universal/CapsuleRuntimeDxe: Reject capsules unless ME is HAP-disabled
HAP-disabled ME doesn't do anything, including writing to system flash,
which is what we need for a firmware update that relies on a warm reset.
coreboot assumes that HECI/soft-disabled state of ME isn't as good as
HMRFPO and switches to HMRFPO doing a global reset which loses in-RAM
capsules.

Checking variable's value should be enough, if somebody manually set it to
an invalid value, the update there will be a reboot without a capsule
update.  A more reliable solution would be to pass this information from
coreboot.

Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>
2025-03-10 20:16:31 +02:00
Sergii Dmytruk
62e05eec81 DasharoModulePkg: Extract DasharoEnableFUM()
It will be used elsewhere.

Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>
2025-03-10 20:16:30 +02:00
Sergii Dmytruk
0bceb4df2a SecurityPkg: measure Dasharo variables before boot
DasharoModulePkg/DasharoVariablesLib got an API for measuring Dasharo
variables which is invoked by Tcg[2]Dxe.

Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>
2025-03-10 20:16:27 +02:00
Sergii Dmytruk
255e4abe90 DasharoSystemFeaturesUiLib: reduce boilerplate in RouteConfig
The code is highly repetitive, use a macro to shorten it by a lot.

Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>
2025-03-10 20:16:27 +02:00
Sergii Dmytruk
27d5fd6e2b DasharoModulePkg: reset to defaults maintained by DasharoVariablesLib
From now on default values are maintained only in DasharoVariablesLib
and can be queried from it to avoid code duplication and bugs which
arise from it.

Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>
2025-03-10 20:16:27 +02:00
Michał Kopeć
47d4272e69 DasharoModulePkg: UserAuthenticationDxeSmm: Convert to pure DXE driver
Remove SMM dependency as we can't use it with coreboot

Co-authored-by: Filip Gołaś <filip.golas@3mdeb.com>
Signed-off-by: Michał Kopeć <michal.kopec@3mdeb.com>
2025-03-10 19:43:47 +02:00
Michał Kopeć
19653dce76 DasharoModulePkg: setup password: initial code import from edk2-platforms
Signed-off-by: Michał Kopeć <michal.kopec@3mdeb.com>
2025-03-10 19:43:45 +02:00