ACK: [PATCH 08/10] dmicheck: update tests in type 17

ivanhu ivan.hu at canonical.com
Thu May 28 06:31:52 UTC 2020



On 5/21/20 10:38 AM, Alex Hung wrote:
> 1. update form factor - die
> 2. add firmware version string check
> 3. add reserved bits for extended speed and extended configured memory
> speed
> 
> Signed-off-by: Alex Hung <alex.hung at canonical.com>
> ---
>  src/dmi/dmicheck/dmicheck.c | 9 +++++++--
>  1 file changed, 7 insertions(+), 2 deletions(-)
> 
> diff --git a/src/dmi/dmicheck/dmicheck.c b/src/dmi/dmicheck/dmicheck.c
> index f23c353b..f24290f1 100644
> --- a/src/dmi/dmicheck/dmicheck.c
> +++ b/src/dmi/dmicheck/dmicheck.c
> @@ -1606,7 +1606,7 @@ static void dmicheck_entry(fwts_framework *fw,
>  				break;
>  			if (hdr->length < 0x15)
>  				break;
> -			dmi_min_max_uint8_check(fw, table, addr, "Form Factor", hdr, 0xe, 0x1, 0xf);
> +			dmi_min_max_uint8_check(fw, table, addr, "Form Factor", hdr, 0xe, 0x1, 0x10);
>  			dmi_str_check(fw, table, addr, "Locator", hdr, 0x10);
>  			dmi_str_check(fw, table, addr, "Bank Locator", hdr, 0x11);
>  			dmi_min_max_uint8_check(fw, table, addr, "Memory Type", hdr, 0x12, 0x1, 0x21);
> @@ -1622,10 +1622,15 @@ static void dmicheck_entry(fwts_framework *fw,
>  			if (hdr->length < 0x20)
>  				break;
>  			dmi_reserved_bits_check(fw, table, addr, "Extended Size", hdr, sizeof(uint32_t), 0x1c, 31, 31);
> -			if (hdr->length < 0x3c)
> +			if (hdr->length < 0x4c)
>  				break;
>  			dmi_min_max_uint8_check(fw, table, addr, "Memory Technology", hdr, 0x28, 0x1, 0x7);
>  			dmi_reserved_bits_check(fw, table, addr, "Memory Operating Mode Cap", hdr, sizeof(uint16_t), 0x29, 6, 15);
> +			dmi_str_check(fw, table, addr, "Firmware Version", hdr, 0x2b);
> +			if (hdr->length < 0x54)
> +				break;
> +			dmi_reserved_bits_check(fw, table, addr, "Extended Speed", hdr, sizeof(uint32_t), 0x54, 31, 31);
> +			dmi_reserved_bits_check(fw, table, addr, "Extended Configured Memory Speed", hdr, sizeof(uint32_t), 0x58, 31, 31);
>  
>  			break;
>  
> 

Acked-by: Ivan Hu <ivan.hu at canonical.com>



More information about the fwts-devel mailing list