smbios: Generate type 4 on non-x86 systems

The type 4 table generation code is very x86 centric today. Refactor things
out into the device model cpu class to allow the tables to get generated for
other architectures as well.

Signed-off-by: Alexander Graf <agraf@suse.de>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
This commit is contained in:
Alexander Graf 2016-08-19 01:23:28 +02:00
parent 94eaa79cec
commit 96476206c5
2 changed files with 41 additions and 13 deletions

View file

@ -139,6 +139,9 @@ struct __packed smbios_type3 {
#define SMBIOS_PROCESSOR_STATUS_ENABLED 1
#define SMBIOS_PROCESSOR_UPGRADE_NONE 6
#define SMBIOS_PROCESSOR_FAMILY_OTHER 1
#define SMBIOS_PROCESSOR_FAMILY_UNKNOWN 2
struct __packed smbios_type4 {
u8 type;
u8 length;