aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/smbios.h6
-rw-r--r--lib/efi_loader/efi_smbios.c3
-rw-r--r--lib/smbios-parser.c3
3 files changed, 7 insertions, 5 deletions
diff --git a/include/smbios.h b/include/smbios.h
index 49de32fec2..b507b9d9d7 100644
--- a/include/smbios.h
+++ b/include/smbios.h
@@ -8,7 +8,7 @@
#ifndef _SMBIOS_H_
#define _SMBIOS_H_
-#include <dm/ofnode.h>
+#include <linux/types.h>
/* SMBIOS spec version implemented */
#define SMBIOS_MAJOR_VER 3
@@ -80,10 +80,6 @@ struct __packed smbios3_entry {
u64 struct_table_address;
};
-/* These two structures should use the same amount of 16-byte-aligned space */
-static_assert(ALIGN(16, sizeof(struct smbios_entry)) ==
- ALIGN(16, sizeof(struct smbios3_entry)));
-
/* BIOS characteristics */
#define BIOS_CHARACTERISTICS_PCI_SUPPORTED (1 << 7)
#define BIOS_CHARACTERISTICS_UPGRADEABLE (1 << 11)
diff --git a/lib/efi_loader/efi_smbios.c b/lib/efi_loader/efi_smbios.c
index eb6d2ba43c..b2ec1f7919 100644
--- a/lib/efi_loader/efi_smbios.c
+++ b/lib/efi_loader/efi_smbios.c
@@ -13,6 +13,9 @@
#include <mapmem.h>
#include <smbios.h>
#include <linux/sizes.h>
+#include <asm/global_data.h>
+
+DECLARE_GLOBAL_DATA_PTR;
const efi_guid_t smbios3_guid = SMBIOS3_TABLE_GUID;
diff --git a/lib/smbios-parser.c b/lib/smbios-parser.c
index 4a3732bcf2..e1180efae1 100644
--- a/lib/smbios-parser.c
+++ b/lib/smbios-parser.c
@@ -5,8 +5,11 @@
#define LOG_CATEGORY LOGC_BOOT
+#include <errno.h>
#include <smbios.h>
+#include <string.h>
#include <tables_csum.h>
+#include <linux/kernel.h>
const struct smbios_entry *smbios_entry(u64 address, u32 size)
{