aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Glass2019-12-28 10:45:03 -0700
committerTom Rini2020-01-17 14:02:35 -0500
commit8e8ccfe1aa1a3ea0cb88b4438c7a687fcf8632a1 (patch)
tree676aead549f3a82f2cf0260474eb48f43aeb1c61
parentbb872dd930ccc0fb7a91c1b8e34b39ce2e9fed06 (diff)
common: Move the image globals into image.h
These three globals relate to image handling. Move them to the image header file. Signed-off-by: Simon Glass <sjg@chromium.org>
-rw-r--r--cmd/bmp.c1
-rw-r--r--cmd/bootz.c1
-rw-r--r--cmd/cramfs.c1
-rw-r--r--cmd/disk.c1
-rw-r--r--cmd/elf.c1
-rw-r--r--cmd/jffs2.c1
-rw-r--r--cmd/load.c1
-rw-r--r--cmd/mvebu/bubt.c1
-rw-r--r--cmd/nand.c1
-rw-r--r--cmd/net.c1
-rw-r--r--cmd/pxe_utils.c1
-rw-r--r--common/board_r.c1
-rw-r--r--common/update.c1
-rw-r--r--drivers/ddr/marvell/a38x/ddr3_training_ip_engine.c1
-rw-r--r--include/common.h4
-rw-r--r--include/image.h4
-rw-r--r--lib/optee/optee.c1
-rw-r--r--net/net.c1
-rw-r--r--net/nfs.c1
-rw-r--r--net/tftp.c1
20 files changed, 22 insertions, 4 deletions
diff --git a/cmd/bmp.c b/cmd/bmp.c
index 1e4c9720fea..edf4f564266 100644
--- a/cmd/bmp.c
+++ b/cmd/bmp.c
@@ -13,6 +13,7 @@
#include <command.h>
#include <dm.h>
#include <gzip.h>
+#include <image.h>
#include <lcd.h>
#include <malloc.h>
#include <mapmem.h>
diff --git a/cmd/bootz.c b/cmd/bootz.c
index 7bfc491221a..f14a5fefbfc 100644
--- a/cmd/bootz.c
+++ b/cmd/bootz.c
@@ -7,6 +7,7 @@
#include <common.h>
#include <bootm.h>
#include <command.h>
+#include <image.h>
#include <irq_func.h>
#include <lmb.h>
#include <linux/compiler.h>
diff --git a/cmd/cramfs.c b/cmd/cramfs.c
index 1bc987528f0..ad232deae00 100644
--- a/cmd/cramfs.c
+++ b/cmd/cramfs.c
@@ -13,6 +13,7 @@
#include <common.h>
#include <command.h>
#include <env.h>
+#include <image.h>
#include <malloc.h>
#include <mapmem.h>
#include <linux/list.h>
diff --git a/cmd/disk.c b/cmd/disk.c
index c57561b3cb7..15973b7d132 100644
--- a/cmd/disk.c
+++ b/cmd/disk.c
@@ -6,6 +6,7 @@
#include <common.h>
#include <command.h>
#include <cpu_func.h>
+#include <image.h>
#include <part.h>
int common_diskboot(cmd_tbl_t *cmdtp, const char *intf, int argc,
diff --git a/cmd/elf.c b/cmd/elf.c
index 57736f997bf..ba06df06cf3 100644
--- a/cmd/elf.c
+++ b/cmd/elf.c
@@ -18,6 +18,7 @@
#include <cpu_func.h>
#include <elf.h>
#include <env.h>
+#include <image.h>
#include <net.h>
#include <vxworks.h>
#ifdef CONFIG_X86
diff --git a/cmd/jffs2.c b/cmd/jffs2.c
index 672ed43b3f3..da2580d85d7 100644
--- a/cmd/jffs2.c
+++ b/cmd/jffs2.c
@@ -73,6 +73,7 @@
#include <common.h>
#include <command.h>
#include <env.h>
+#include <image.h>
#include <malloc.h>
#include <jffs2/jffs2.h>
#include <linux/list.h>
diff --git a/cmd/load.c b/cmd/load.c
index bed973ede91..fab30fe8943 100644
--- a/cmd/load.c
+++ b/cmd/load.c
@@ -13,6 +13,7 @@
#include <cpu_func.h>
#include <env.h>
#include <flash.h>
+#include <image.h>
#include <s_record.h>
#include <net.h>
#include <exports.h>
diff --git a/cmd/mvebu/bubt.c b/cmd/mvebu/bubt.c
index 6c68620d147..2041a7a29aa 100644
--- a/cmd/mvebu/bubt.c
+++ b/cmd/mvebu/bubt.c
@@ -8,6 +8,7 @@
#include <common.h>
#include <command.h>
#include <env.h>
+#include <image.h>
#include <vsprintf.h>
#include <errno.h>
#include <dm.h>
diff --git a/cmd/nand.c b/cmd/nand.c
index 92089a73c17..4de6892a01b 100644
--- a/cmd/nand.c
+++ b/cmd/nand.c
@@ -20,6 +20,7 @@
*/
#include <common.h>
+#include <image.h>
#include <linux/mtd/mtd.h>
#include <command.h>
#include <console.h>
diff --git a/cmd/net.c b/cmd/net.c
index 6bce214e45a..1b724cc5709 100644
--- a/cmd/net.c
+++ b/cmd/net.c
@@ -10,6 +10,7 @@
#include <common.h>
#include <command.h>
#include <env.h>
+#include <image.h>
#include <net.h>
static int netboot_common(enum proto_t, cmd_tbl_t *, int, char * const []);
diff --git a/cmd/pxe_utils.c b/cmd/pxe_utils.c
index ff8b0dcd7b8..8b830212ce1 100644
--- a/cmd/pxe_utils.c
+++ b/cmd/pxe_utils.c
@@ -6,6 +6,7 @@
#include <common.h>
#include <env.h>
+#include <image.h>
#include <malloc.h>
#include <mapmem.h>
#include <lcd.h>
diff --git a/common/board_r.c b/common/board_r.c
index cf3a5f7b739..668496abedc 100644
--- a/common/board_r.c
+++ b/common/board_r.c
@@ -13,6 +13,7 @@
#include <api.h>
#include <cpu_func.h>
#include <exports.h>
+#include <image.h>
#include <irq_func.h>
#include <net.h>
#include <u-boot/crc.h>
diff --git a/common/update.c b/common/update.c
index bfb760e52a2..c8dd346a095 100644
--- a/common/update.c
+++ b/common/update.c
@@ -8,6 +8,7 @@
#include <common.h>
#include <cpu_func.h>
+#include <image.h>
#if !(defined(CONFIG_FIT) && defined(CONFIG_OF_LIBFDT))
#error "CONFIG_FIT and CONFIG_OF_LIBFDT are required for auto-update feature"
diff --git a/drivers/ddr/marvell/a38x/ddr3_training_ip_engine.c b/drivers/ddr/marvell/a38x/ddr3_training_ip_engine.c
index 27610d48cff..9293d54e5a0 100644
--- a/drivers/ddr/marvell/a38x/ddr3_training_ip_engine.c
+++ b/drivers/ddr/marvell/a38x/ddr3_training_ip_engine.c
@@ -6,6 +6,7 @@
#include "ddr3_init.h"
#include "mv_ddr_regs.h"
#include "ddr_training_ip_db.h"
+#include <image.h>
#define PATTERN_1 0x55555555
#define PATTERN_2 0xaaaaaaaa
diff --git a/include/common.h b/include/common.h
index 09b5f62ae31..5e38c5fc582 100644
--- a/include/common.h
+++ b/include/common.h
@@ -62,10 +62,6 @@ void hang (void) __attribute__ ((noreturn));
/* common/cmd_source.c */
int source (ulong addr, const char *fit_uname);
-extern ulong image_load_addr; /* Default Load Address */
-extern ulong image_save_addr; /* Default Save Address */
-extern ulong image_save_size; /* Default Save Size */
-
/* common/memsize.c */
long get_ram_size (long *, long);
phys_size_t get_effective_memsize(void);
diff --git a/include/image.h b/include/image.h
index 86ebaae4fe3..3649644cf1d 100644
--- a/include/image.h
+++ b/include/image.h
@@ -112,6 +112,10 @@ struct fdt_region;
# define IMAGE_OF_SYSTEM_SETUP 0
#endif
+extern ulong image_load_addr; /* Default Load Address */
+extern ulong image_save_addr; /* Default Save Address */
+extern ulong image_save_size; /* Default Save Size */
+
enum ih_category {
IH_ARCH,
IH_COMP,
diff --git a/lib/optee/optee.c b/lib/optee/optee.c
index c883c498e1d..9b49eb8ee76 100644
--- a/lib/optee/optee.c
+++ b/lib/optee/optee.c
@@ -5,6 +5,7 @@
*/
#include <common.h>
+#include <image.h>
#include <malloc.h>
#include <linux/libfdt.h>
#include <tee/optee.h>
diff --git a/net/net.c b/net/net.c
index b9bf0d1a8b5..d8a60b61191 100644
--- a/net/net.c
+++ b/net/net.c
@@ -93,6 +93,7 @@
#include <env.h>
#include <env_internal.h>
#include <errno.h>
+#include <image.h>
#include <net.h>
#include <net/fastboot.h>
#include <net/tftp.h>
diff --git a/net/nfs.c b/net/nfs.c
index 5226e2c163e..72e1018a3bd 100644
--- a/net/nfs.c
+++ b/net/nfs.c
@@ -29,6 +29,7 @@
#include <common.h>
#include <command.h>
#include <flash.h>
+#include <image.h>
#include <net.h>
#include <malloc.h>
#include <mapmem.h>
diff --git a/net/tftp.c b/net/tftp.c
index 899d3b89d3e..02401898c55 100644
--- a/net/tftp.c
+++ b/net/tftp.c
@@ -10,6 +10,7 @@
#include <command.h>
#include <efi_loader.h>
#include <env.h>
+#include <image.h>
#include <mapmem.h>
#include <net.h>
#include <net/tftp.h>