On 12/02/2014 05:31 PM, Jarkko Sakkinen wrote:

> +struct acpi_tpm2 {
> +     struct acpi_table_header hdr;
> +     u16 platform_class;
> +     u16 reserved;
> +     u64 control_area_pa;
> +     u32 start_method;
> +} __packed;
[...]
> +     }
> +
> +     if (buf->hdr.length != sizeof(struct acpi_tpm2)) {

This should be

if (buf->hdr.length < sizeof(struct acpi_tpm2)) {

since the ACPI TPM2 table may have a variable number of 'Platform 
Specific Parameters' beyond the 'Start Method Field'. What we don't want 
to have is less, but more is fine.

    Stefan


------------------------------------------------------------------------------
Dive into the World of Parallel Programming! The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net
_______________________________________________
TrouSerS-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/trousers-tech

Reply via email to