ACK: [PATCH 4/4] acpi: rsdp: revision 1 must have length 20 according to ACPI 6.1 errata
Colin Ian King
colin.king at canonical.com
Fri Jun 16 07:52:21 UTC 2017
On 16/06/17 05:41, Alex Hung wrote:
> Spec update (mantis 1664) clearly points out length of revision 1 is 20,
> and no fields are beyond offset 19
>
> Signed-off-by: Alex Hung <alex.hung at canonical.com>
> ---
> src/acpi/rsdp/rsdp.c | 13 +++++++++++++
> 1 file changed, 13 insertions(+)
>
> diff --git a/src/acpi/rsdp/rsdp.c b/src/acpi/rsdp/rsdp.c
> index a084d9c..becdbb2 100644
> --- a/src/acpi/rsdp/rsdp.c
> +++ b/src/acpi/rsdp/rsdp.c
> @@ -102,6 +102,19 @@ static int rsdp_test1(fwts_framework *fw)
> "firmware ACPI complaint.");
> }
>
> + /* ACPI 6.1 errata clarifies revision 1 must have length 20 */
> + if (rsdp->revision == 1) {
> + if (rsdp->length == 20)
> + fwts_passed(fw, "RSDP: the table is the correct length.");
> + else
> + fwts_failed(fw, LOG_LEVEL_MEDIUM,
> + "RSDPBadLength",
> + "RSDP: length of Revision 1 is %d bytes but should be 20.",
> + rsdp->length);
> +
> + return FWTS_OK;
> + }
> +
> if (rsdp->revision <= 2)
> fwts_passed(fw,
> "RSDP: revision is %" PRIu8 ".", rsdp->revision);
>
Good extra level of checking.
Acked-by: Colin Ian King <colin.king at canonical.com>
More information about the fwts-devel
mailing list