lib: Remove <common.h> inclusion from these files
After some header file cleanups to add missing include files, remove
common.h from all files in the lib directory. This primarily means just
dropping the line but in a few cases we need to add in other header
files now.
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Tom Rini <trini@konsulko.com>
diff --git a/lib/acpi/acpi.c b/lib/acpi/acpi.c
index f21e509..939a638 100644
--- a/lib/acpi/acpi.c
+++ b/lib/acpi/acpi.c
@@ -5,7 +5,6 @@
* Copyright 2023 Google LLC
*/
-#include <common.h>
#include <mapmem.h>
#include <acpi/acpi_table.h>
#include <asm/global_data.h>
diff --git a/lib/acpi/acpi_device.c b/lib/acpi/acpi_device.c
index 1b838fd..ed94194 100644
--- a/lib/acpi/acpi_device.c
+++ b/lib/acpi/acpi_device.c
@@ -6,7 +6,6 @@
* Mostly taken from coreboot file of the same name
*/
-#include <common.h>
#include <dm.h>
#include <irq.h>
#include <log.h>
diff --git a/lib/acpi/acpi_dp.c b/lib/acpi/acpi_dp.c
index 7e3e325..6733809 100644
--- a/lib/acpi/acpi_dp.c
+++ b/lib/acpi/acpi_dp.c
@@ -6,7 +6,6 @@
* Mostly taken from coreboot file acpi_device.c
*/
-#include <common.h>
#include <dm.h>
#include <log.h>
#include <malloc.h>
diff --git a/lib/acpi/acpi_table.c b/lib/acpi/acpi_table.c
index a8d4b47..e74522e 100644
--- a/lib/acpi/acpi_table.c
+++ b/lib/acpi/acpi_table.c
@@ -5,7 +5,6 @@
* Copyright 2019 Google LLC
*/
-#include <common.h>
#include <dm.h>
#include <cpu.h>
#include <log.h>
diff --git a/lib/acpi/acpi_writer.c b/lib/acpi/acpi_writer.c
index 946f90e..a8dc207 100644
--- a/lib/acpi/acpi_writer.c
+++ b/lib/acpi/acpi_writer.c
@@ -7,13 +7,13 @@
#define LOG_CATEGORY LOGC_ACPI
-#include <common.h>
#include <log.h>
#include <malloc.h>
#include <mapmem.h>
#include <acpi/acpi_table.h>
#include <asm/global_data.h>
#include <dm/acpi.h>
+#include <linux/errno.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/lib/acpi/acpigen.c b/lib/acpi/acpigen.c
index e395226..b95cabb 100644
--- a/lib/acpi/acpigen.c
+++ b/lib/acpi/acpigen.c
@@ -8,7 +8,6 @@
#define LOG_CATEGORY LOGC_ACPI
-#include <common.h>
#include <dm.h>
#include <log.h>
#include <uuid.h>
diff --git a/lib/acpi/base.c b/lib/acpi/base.c
index 26bf0cb..07b53e0 100644
--- a/lib/acpi/base.c
+++ b/lib/acpi/base.c
@@ -7,12 +7,13 @@
#define LOG_CATEGORY LOGC_ACPI
-#include <common.h>
#include <acpi/acpi_table.h>
#include <dm/acpi.h>
#include <mapmem.h>
#include <tables_csum.h>
#include <linux/sizes.h>
+#include <linux/errno.h>
+#include <linux/string.h>
void acpi_write_rsdp(struct acpi_rsdp *rsdp, struct acpi_rsdt *rsdt,
struct acpi_xsdt *xsdt)
diff --git a/lib/acpi/csrt.c b/lib/acpi/csrt.c
index 2ba86f2..00927e5 100644
--- a/lib/acpi/csrt.c
+++ b/lib/acpi/csrt.c
@@ -7,11 +7,11 @@
#define LOG_CATEGORY LOGC_ACPI
-#include <common.h>
#include <mapmem.h>
#include <tables_csum.h>
#include <acpi/acpi_table.h>
#include <dm/acpi.h>
+#include <linux/string.h>
__weak int acpi_fill_csrt(struct acpi_ctx *ctx)
{
diff --git a/lib/acpi/dsdt.c b/lib/acpi/dsdt.c
index db98cc2..206e1e2 100644
--- a/lib/acpi/dsdt.c
+++ b/lib/acpi/dsdt.c
@@ -7,10 +7,10 @@
#define LOG_CATEGORY LOGC_ACPI
-#include <common.h>
#include <acpi/acpi_table.h>
#include <dm/acpi.h>
#include <tables_csum.h>
+#include <linux/string.h>
/*
* IASL compiles the dsdt entries and writes the hex values
diff --git a/lib/acpi/facs.c b/lib/acpi/facs.c
index e89f43c..86c2812 100644
--- a/lib/acpi/facs.c
+++ b/lib/acpi/facs.c
@@ -7,9 +7,9 @@
#define LOG_CATEGORY LOGC_ACPI
-#include <common.h>
#include <acpi/acpi_table.h>
#include <dm/acpi.h>
+#include <linux/string.h>
int acpi_write_facs(struct acpi_ctx *ctx, const struct acpi_writer *entry)
{
diff --git a/lib/acpi/mcfg.c b/lib/acpi/mcfg.c
index 7404ae58..8b8a5bf 100644
--- a/lib/acpi/mcfg.c
+++ b/lib/acpi/mcfg.c
@@ -7,11 +7,13 @@
#define LOG_CATEGORY LOGC_ACPI
-#include <common.h>
#include <mapmem.h>
#include <tables_csum.h>
#include <acpi/acpi_table.h>
#include <dm/acpi.h>
+#include <linux/errno.h>
+#include <linux/string.h>
+#include <linux/types.h>
int acpi_create_mcfg_mmconfig(struct acpi_mcfg_mmconfig *mmconfig, u32 base,
u16 seg_nr, u8 start, u8 end)
diff --git a/lib/acpi/ssdt.c b/lib/acpi/ssdt.c
index b140b4b..b0a96f8 100644
--- a/lib/acpi/ssdt.c
+++ b/lib/acpi/ssdt.c
@@ -7,10 +7,11 @@
#define LOG_CATEGORY LOGC_ACPI
-#include <common.h>
#include <acpi/acpi_table.h>
#include <dm/acpi.h>
#include <tables_csum.h>
+#include <linux/errno.h>
+#include <linux/string.h>
int acpi_write_ssdt(struct acpi_ctx *ctx, const struct acpi_writer *entry)
{