summaryrefslogtreecommitdiff
path: root/cmd
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2020-10-30 21:38:53 -0600
committerTom Rini <trini@konsulko.com>2021-02-02 15:33:42 -0500
commit401d1c4f5d2d29c4bc4beaec95402ca23eb63295 (patch)
tree0122abb2a3f1ea9837eaccc6150d2dae9570388e /cmd
parentfdcb93e1709ab1a2ebb562455621617c29e2099c (diff)
downloadu-boot-401d1c4f5d2d29c4bc4beaec95402ca23eb63295.tar.gz
u-boot-401d1c4f5d2d29c4bc4beaec95402ca23eb63295.tar.bz2
u-boot-401d1c4f5d2d29c4bc4beaec95402ca23eb63295.zip
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 a3419b42b5..157261bffb 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 8d8daa6336..84dab7d2d3 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 684e4a9ea5..bef617b6a4 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 bb2e682ff8..97b5734161 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 81dd8e0284..1583a96be1 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 76d1255ec5..3df70ea9ca 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 e6b0e04413..7732b97f63 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 75a032cd27..0e11894753 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 1558cb17eb..f2ed26bd4b 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 f252c74894..5bbc39baea 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 ca1c51e067..72380c5691 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 1d4f2bab2f..1eb83b7570 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 5220142b9a..ed373a8c4d 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 d0d2eca904..d14ba10cef 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 9a8b38c7f2..5656bae6d3 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 6af9523734..bf58e15347 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 f7eb921f43..0d55818e3c 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 7fc19678ea..fdcde36533 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 28b40dd31e..472703f8fe 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 623b63b0f9..6b43a73868 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 eab0531c96..5099cbdd95 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 8017eda387..82e4415b16 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 9e555c778c..01db93eb3e 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>