Julius Werner has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/30826 )
Change subject: security/tpm/tss/tcg-2.0: Add TPM2 function tlcl_getcapability() ......................................................................
Patch Set 17:
(3 comments)
Thanks, looks mostly good now.
https://review.coreboot.org/#/c/30826/17/src/security/tpm/tss/tcg-2.0/tss.c File src/security/tpm/tss/tcg-2.0/tss.c:
https://review.coreboot.org/#/c/30826/17/src/security/tpm/tss/tcg-2.0/tss.c@... PS17, Line 379: "supported yet\n", __func__); Shouldn't this assert() or error out?
https://review.coreboot.org/#/c/30826/17/src/security/tpm/tss/tcg-2.0/tss_ma... File src/security/tpm/tss/tcg-2.0/tss_marshaling.c:
https://review.coreboot.org/#/c/30826/17/src/security/tpm/tss/tcg-2.0/tss_ma... PS17, Line 438: gcr->cd.data.assignedPCR.pcrSelections + i; nit: cleaner to write &gcr->cd.data.assignedPCR.pcrSelections[i]
https://review.coreboot.org/#/c/30826/17/src/security/tpm/tss/tcg-2.0/tss_st... File src/security/tpm/tss/tcg-2.0/tss_structures.h:
https://review.coreboot.org/#/c/30826/17/src/security/tpm/tss/tcg-2.0/tss_st... PS17, Line 234: #define PCR_SELECT_MIN ALIGN_UP(PLATFORM_PCR, 8)/8
Macros with complex values should be enclosed in parentheses
Just use DIV_ROUND_UP() for these