On Wed, 2019-07-03 at 10:08 -0700, Jordan Hand wrote: > > +This introduces another problem: nothing guarantees that it is not > > +called before the stub gets to run. Thus, it needs to copy the final > > +events table preboot size to the custom configuration table so that > > +kernel offset it later on. > > This doesn't really explain what the size will be used for. Matthew's > patch description for "tpm: Don't duplicate events from the final event > log in the TCG2 log" outlines this well. You could maybe word it > differently but I think the information is necessary: > > "We can avoid this problem by looking at the size of the Final Event Log > just before we call ExitBootServices() and exporting this to the main > kernel. The kernel can then skip over all events that occured before > ExitBootServices() and only append events that were not also logged to > the main log." Not exactly sure what is missing from my paragraph. The way I see it has more information as it states what is used at as the vessel for exportation (the custom configuration table). Maybe something like: "Thus, it nees to save the final events table size at the time to the custom configuration table so that the TPM driver can later on skip the events generated during the preboot time." /Jarkko