aboutsummaryrefslogtreecommitdiff
path: root/cmd
diff options
context:
space:
mode:
authorSimon Glass2020-10-30 21:38:53 -0600
committerTom Rini2021-02-02 15:33:42 -0500
commit401d1c4f5d2d29c4bc4beaec95402ca23eb63295 (patch)
tree0122abb2a3f1ea9837eaccc6150d2dae9570388e /cmd
parentfdcb93e1709ab1a2ebb562455621617c29e2099c (diff)
common: Drop asm/global_data.h from common header
Move this out of the common header and include it only where needed. In a number of cases this requires adding "struct udevice;" to avoid adding another large header or in other cases replacing / adding missing header files that had been pulled in, very indirectly. Finally, we have a few cases where we did not need to include <asm/global_data.h> at all, so remove that include. Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'cmd')
-rw-r--r--cmd/acpi.c1
-rw-r--r--cmd/bdinfo.c1
-rw-r--r--cmd/bedbug.c1
-rw-r--r--cmd/bloblist.c1
-rw-r--r--cmd/bootefi.c1
-rw-r--r--cmd/booti.c1
-rw-r--r--cmd/bootm.c1
-rw-r--r--cmd/date.c1
-rw-r--r--cmd/efi.c1
-rw-r--r--cmd/load.c1
-rw-r--r--cmd/log.c1
-rw-r--r--cmd/mem.c1
-rw-r--r--cmd/mtdparts.c1
-rw-r--r--cmd/nvedit.c1
-rw-r--r--cmd/pstore.c1
-rw-r--r--cmd/pxe_utils.h2
-rw-r--r--cmd/sb.c1
-rw-r--r--cmd/sound.c1
-rw-r--r--cmd/spl.c1
-rw-r--r--cmd/ti/ddr3.c1
-rw-r--r--cmd/tlv_eeprom.c1
-rw-r--r--cmd/x86/fsp.c1
-rw-r--r--cmd/x86/hob.c1
23 files changed, 24 insertions, 0 deletions
diff --git a/cmd/acpi.c b/cmd/acpi.c
index a3419b42b55..157261bffbe 100644
--- a/cmd/acpi.c
+++ b/cmd/acpi.c
@@ -8,6 +8,7 @@
#include <mapmem.h>
#include <acpi/acpi_table.h>
#include <asm/acpi_table.h>
+#include <asm/global_data.h>
#include <dm/acpi.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/cmd/bdinfo.c b/cmd/bdinfo.c
index 8d8daa6336a..84dab7d2d33 100644
--- a/cmd/bdinfo.c
+++ b/cmd/bdinfo.c
@@ -15,6 +15,7 @@
#include <video.h>
#include <vsprintf.h>
#include <asm/cache.h>
+#include <asm/global_data.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/cmd/bedbug.c b/cmd/bedbug.c
index 684e4a9ea5c..bef617b6a4f 100644
--- a/cmd/bedbug.c
+++ b/cmd/bedbug.c
@@ -6,6 +6,7 @@
#include <cli.h>
#include <command.h>
#include <console.h>
+#include <asm/global_data.h>
#include <asm/ptrace.h>
#include <linux/ctype.h>
#include <net.h>
diff --git a/cmd/bloblist.c b/cmd/bloblist.c
index bb2e682ff84..97b57341617 100644
--- a/cmd/bloblist.c
+++ b/cmd/bloblist.c
@@ -9,6 +9,7 @@
#include <common.h>
#include <bloblist.h>
#include <command.h>
+#include <asm/global_data.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/cmd/bootefi.c b/cmd/bootefi.c
index 81dd8e0284f..1583a96be14 100644
--- a/cmd/bootefi.c
+++ b/cmd/bootefi.c
@@ -19,6 +19,7 @@
#include <image.h>
#include <log.h>
#include <malloc.h>
+#include <asm/global_data.h>
#include <linux/libfdt.h>
#include <linux/libfdt_env.h>
#include <mapmem.h>
diff --git a/cmd/booti.c b/cmd/booti.c
index 76d1255ec58..3df70ea9caa 100644
--- a/cmd/booti.c
+++ b/cmd/booti.c
@@ -12,6 +12,7 @@
#include <lmb.h>
#include <log.h>
#include <mapmem.h>
+#include <asm/global_data.h>
#include <linux/kernel.h>
#include <linux/sizes.h>
diff --git a/cmd/bootm.c b/cmd/bootm.c
index e6b0e04413c..7732b97f635 100644
--- a/cmd/bootm.c
+++ b/cmd/bootm.c
@@ -16,6 +16,7 @@
#include <malloc.h>
#include <nand.h>
#include <asm/byteorder.h>
+#include <asm/global_data.h>
#include <linux/ctype.h>
#include <linux/err.h>
#include <u-boot/zlib.h>
diff --git a/cmd/date.c b/cmd/date.c
index 75a032cd277..0e118947531 100644
--- a/cmd/date.c
+++ b/cmd/date.c
@@ -12,6 +12,7 @@
#include <dm.h>
#include <rtc.h>
#include <i2c.h>
+#include <asm/global_data.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/cmd/efi.c b/cmd/efi.c
index 1558cb17eb0..f2ed26bd4b2 100644
--- a/cmd/efi.c
+++ b/cmd/efi.c
@@ -11,6 +11,7 @@
#include <log.h>
#include <malloc.h>
#include <sort.h>
+#include <asm/global_data.h>
static const char *const type_name[] = {
"reserved",
diff --git a/cmd/load.c b/cmd/load.c
index f252c748948..5bbc39baead 100644
--- a/cmd/load.c
+++ b/cmd/load.c
@@ -20,6 +20,7 @@
#include <serial.h>
#include <xyzModem.h>
#include <asm/cache.h>
+#include <asm/global_data.h>
#include <linux/delay.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/cmd/log.c b/cmd/log.c
index ca1c51e0672..72380c5691c 100644
--- a/cmd/log.c
+++ b/cmd/log.c
@@ -10,6 +10,7 @@
#include <getopt.h>
#include <log.h>
#include <malloc.h>
+#include <asm/global_data.h>
static char log_fmt_chars[LOGF_COUNT] = "clFLfm";
diff --git a/cmd/mem.c b/cmd/mem.c
index 1d4f2bab2f9..1eb83b75703 100644
--- a/cmd/mem.c
+++ b/cmd/mem.c
@@ -22,6 +22,7 @@
#include <mapmem.h>
#include <rand.h>
#include <watchdog.h>
+#include <asm/global_data.h>
#include <asm/io.h>
#include <linux/bitops.h>
#include <linux/compiler.h>
diff --git a/cmd/mtdparts.c b/cmd/mtdparts.c
index 5220142b9ab..ed373a8c4da 100644
--- a/cmd/mtdparts.c
+++ b/cmd/mtdparts.c
@@ -75,6 +75,7 @@
#include <env.h>
#include <log.h>
#include <malloc.h>
+#include <asm/global_data.h>
#include <jffs2/load_kernel.h>
#include <linux/list.h>
#include <linux/ctype.h>
diff --git a/cmd/nvedit.c b/cmd/nvedit.c
index d0d2eca9047..d14ba10cefa 100644
--- a/cmd/nvedit.c
+++ b/cmd/nvedit.c
@@ -35,6 +35,7 @@
#include <errno.h>
#include <malloc.h>
#include <mapmem.h>
+#include <asm/global_data.h>
#include <linux/bitops.h>
#include <u-boot/crc.h>
#include <watchdog.h>
diff --git a/cmd/pstore.c b/cmd/pstore.c
index 9a8b38c7f26..5656bae6d3e 100644
--- a/cmd/pstore.c
+++ b/cmd/pstore.c
@@ -5,6 +5,7 @@
#include <config.h>
#include <command.h>
+#include <fdtdec.h>
#include <fs.h>
#include <log.h>
#include <mapmem.h>
diff --git a/cmd/pxe_utils.h b/cmd/pxe_utils.h
index 6af95237343..bf58e15347c 100644
--- a/cmd/pxe_utils.h
+++ b/cmd/pxe_utils.h
@@ -3,6 +3,8 @@
#ifndef __PXE_UTILS_H
#define __PXE_UTILS_H
+#include <linux/list.h>
+
/*
* A note on the pxe file parser.
*
diff --git a/cmd/sb.c b/cmd/sb.c
index f7eb921f43e..0d55818e3c6 100644
--- a/cmd/sb.c
+++ b/cmd/sb.c
@@ -8,6 +8,7 @@
#include <command.h>
#include <dm.h>
#include <spl.h>
+#include <asm/global_data.h>
#include <asm/state.h>
static int do_sb_handoff(struct cmd_tbl *cmdtp, int flag, int argc,
diff --git a/cmd/sound.c b/cmd/sound.c
index 7fc19678ea8..fdcde365339 100644
--- a/cmd/sound.c
+++ b/cmd/sound.c
@@ -9,6 +9,7 @@
#include <dm.h>
#include <fdtdec.h>
#include <sound.h>
+#include <asm/global_data.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/cmd/spl.c b/cmd/spl.c
index 28b40dd31e1..472703f8fe1 100644
--- a/cmd/spl.c
+++ b/cmd/spl.c
@@ -10,6 +10,7 @@
#include <env.h>
#include <image.h>
#include <log.h>
+#include <asm/global_data.h>
#include <linux/libfdt.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/cmd/ti/ddr3.c b/cmd/ti/ddr3.c
index 623b63b0f94..6b43a738683 100644
--- a/cmd/ti/ddr3.c
+++ b/cmd/ti/ddr3.c
@@ -14,6 +14,7 @@
#include <asm/emif.h>
#include <common.h>
#include <command.h>
+#include <asm/global_data.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/cmd/tlv_eeprom.c b/cmd/tlv_eeprom.c
index eab0531c96b..5099cbdd95e 100644
--- a/cmd/tlv_eeprom.c
+++ b/cmd/tlv_eeprom.c
@@ -17,6 +17,7 @@
#include <env.h>
#include <init.h>
#include <net.h>
+#include <asm/global_data.h>
#include <linux/ctype.h>
#include <u-boot/crc.h>
diff --git a/cmd/x86/fsp.c b/cmd/x86/fsp.c
index 8017eda387c..82e4415b16e 100644
--- a/cmd/x86/fsp.c
+++ b/cmd/x86/fsp.c
@@ -6,6 +6,7 @@
#include <common.h>
#include <command.h>
#include <asm/fsp/fsp_support.h>
+#include <asm/global_data.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/cmd/x86/hob.c b/cmd/x86/hob.c
index 9e555c778c2..01db93eb3e1 100644
--- a/cmd/x86/hob.c
+++ b/cmd/x86/hob.c
@@ -7,6 +7,7 @@
#include <command.h>
#include <efi.h>
#include <uuid.h>
+#include <asm/global_data.h>
#include <asm/hob.h>
#include <asm/fsp/fsp_hob.h>