firmware: dmi_scan: Only honor end-of-table for 64-bit tables
firmware: dmi_scan: Only honor end-of-table for 64-bit tables

A 32-bit entry point to a DMI table says how many structures the table
contains. The SMBIOS specification explicitly says that end-of-table
markers should be ignored if they are not actually at the end of the
DMI table. So only honor the end-of-table marker for tables accessed
through 64-bit entry points, as they do not specify a structure count.

Fixes: fc43026278 ("dmi: add support for SMBIOS 3.0 64-bit entry point")
Signed-off-by: Jean Delvare <efca98801f3398ebd7eeff805a2c18e6c49e84d4@suse.de>
Acked-by: Ard Biesheuvel <66d3c5fdaeea7ff1f996ad04f2c45e08ab38e2f5@linaro.org>
Cc: Leif Lindholm <a613079f0455438b29e28a9c5b9eb3779a81a33a@linaro.org>
Cc: Matt Fleming <b02f0790d66a0f0a6b369873bf6df37420fbe5dd@intel.com>

KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs