Drtm payload 25.12#926
Conversation
8abdcd7 to
a2678b4
Compare
SergiiDmytruk
left a comment
There was a problem hiding this comment.
Reviewed the changes in more detail.
a2678b4 to
2c798c1
Compare
|
I think one problem I'm really having is mapping secure-launch terminology to coreboot parts. This is outside my normal area of 'doing coreboot' stuff, I'd much rather and be more in my comfort zone porting new platforms but I'll take what I can get. If you could explain, for example, what part of this stack maps to DLME, for example, I'd probably have an easier time of it moving forward. |
Just saw this comment and I think you figured it out by now, but anyway:
|
Signed-off-by: Krystian Hebel <krystian.hebel@3mdeb.com>
Signed-off-by: Krystian Hebel <krystian.hebel@3mdeb.com>
Signed-off-by: Krystian Hebel <krystian.hebel@3mdeb.com>
Signed-off-by: Krystian Hebel <krystian.hebel@3mdeb.com>
Signed-off-by: Krystian Hebel <krystian.hebel@3mdeb.com>
Signed-off-by: Krystian Hebel <krystian.hebel@3mdeb.com>
Signed-off-by: Marty E. Plummer <hanetzer@startmail.com>
Signed-off-by: Marty E. Plummer <hanetzer@startmail.com>
Signed-off-by: Marty E. Plummer <hanetzer@startmail.com>
Signed-off-by: Marty E. Plummer <hanetzer@startmail.com>
Signed-off-by: Marty E. Plummer <hanetzer@startmail.com>
Signed-off-by: Marty E. Plummer <hanetzer@startmail.com>
Signed-off-by: Marty E. Plummer <hanetzer@startmail.com>
2c798c1 to
7ff8f3f
Compare
Thank you. I'm honestly crap with terminology at times so having a definitive 'this is that' list helps. I guess if edk2 loads grub, grub also goes onto the dlme listing? and also later the kernel? |
Yes, although it makes sense to start Linux directly by the firmware in this scenario to execute less code in the early boot environment (Secure Boot could validate GRUB and it has lockdown mode, but there is still a lot of code in there). |
| log_info->hdr.tag = SLR_ENTRY_LOG_INFO; | ||
| log_info->hdr.size = sizeof(*log_info); | ||
| slrt->size += log_info->hdr.size; | ||
| ce = cbmem_entry_find(CBMEM_ID_TPM2_TCG_LOG); |
There was a problem hiding this comment.
This event log is for SRTM. DRTM's measurements form an independent chain that can also be reset if DRTM is re-started, so the log needs to be separate (cbmem_add()).
There was a problem hiding this comment.
hmm. Would I need to define a new CBMEM_ID then? CBMEM_ID_SRTM_LOG or so?
There was a problem hiding this comment.
hmm. Would I need to define a new CBMEM_ID then?
Yes, I think cbmem_add() requires it. Updating https://github.com/Dasharo/coreboot/blob/dasharo/src/commonlib/bsd/include/commonlib/bsd/cbmem_id.h is two places should be enough.
CBMEM_ID_SRTM_LOG or so?
"DRTM", maybe CBMEM_ID_TPM_DRTM_LOG to be less ambiguous.
| if (ce) { | ||
| log_info->addr = (uintptr_t)cbmem_entry_start(ce); | ||
| log_info->size = cbmem_entry_size(ce); | ||
| log_info->format = SLR_DRTM_TPM20_LOG; // TODO: Support 1.2? |
There was a problem hiding this comment.
// TODO: Support 1.2?
coreboot, SKL and EDK support TPM1.2 and the cost for it here is a bit of initialization (see it in GRUB; despite the name that function is used on AMD as well), so may as well do it. TPM2.0 log just needs to be zeroed, its size in GRUB is 32 KiB regardless of TPM family.
Replacement of #916, can't change my branch, just the target. Hoping to avoid losing the comments there. Sorry for the noise.