[PATCH v5 2/7] tpm: remove definition of TPM2_ACTIVE_PCR_BANKS

Jarkko Sakkinen jarkko.sakkinen at linux.intel.com
Fri Nov 30 19:41:49 UTC 2018


On Thu, Nov 29, 2018 at 01:04:40PM +0100, Roberto Sassu wrote:
> > > > +    struct tpm2_digest digests[0];
> > > >       struct tcg_event_field event;
> > > >   } __packed;
> > > > -- 
> > > > 2.17.1
> > > > 
> > > 
> > > NAK for the same reason as last time.
> > 
> > I added this comment to include/linux/tpm_eventlog.h:
> > 
> > /*
> >   * http://www.trustedcomputinggroup.org/tcg-efi-protocol-specification/
> >   *
> >   * Set the size of 'digest_sizes' and 'digests', members of
> > tcg_efi_specid_event
> >   * and tcg_pcr_event2, to zero. Structures with variable-sized arrays
> > placed
> >   * midway are not suitable for type casting.
> >   */
> > 
> 
> If this comment is ok, I will send a new version of the patch set.
> 
> Roberto

Even after looking at the spec the last field does not make sense as the
event after digests and digests are not in union. It is just not right.

The comment does not fix that.

/Jarkko



More information about the Linux-security-module-archive mailing list