summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarian Balakowicz <m8@semihalf.com>2008-01-08 18:11:44 +0100
committerWolfgang Denk <wd@denx.de>2008-02-07 01:12:55 +0100
commit559316faf7eae0614c91d77f509b57d6c4c091ba (patch)
treecd5cf29efb9aa07b64ca470c0bf6671656c070a3
parent321359f20823e0b8c5ad38b64d007a6c48cda16e (diff)
downloadu-boot-imx-559316faf7eae0614c91d77f509b57d6c4c091ba.zip
u-boot-imx-559316faf7eae0614c91d77f509b57d6c4c091ba.tar.gz
u-boot-imx-559316faf7eae0614c91d77f509b57d6c4c091ba.tar.bz2
[new uImage] Move CHUNKSZ definition to image.h
CHUNKSZ defined for PPC and M68K is set to the same value of 64K, move this definition to a common header. Signed-off-by: Marian Balakowicz <m8@semihalf.com>
-rw-r--r--common/cmd_bootm.c7
-rw-r--r--include/image.h7
-rw-r--r--lib_m68k/m68k_linux.c2
-rw-r--r--lib_ppc/ppc_linux.c2
4 files changed, 7 insertions, 11 deletions
diff --git a/common/cmd_bootm.c b/common/cmd_bootm.c
index 67f555e..fbe81d3 100644
--- a/common/cmd_bootm.c
+++ b/common/cmd_bootm.c
@@ -61,13 +61,6 @@ extern int do_reset (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
#include <dataflash.h>
#endif
-/*
- * Some systems (for example LWMON) have very short watchdog periods;
- * we must make sure to split long operations like memmove() or
- * crc32() into reasonable chunks.
- */
-#define CHUNKSZ (64 * 1024)
-
int gunzip (void *, int, unsigned char *, unsigned long *);
#ifdef CONFIG_BZIP2
diff --git a/include/image.h b/include/image.h
index c9f4298..aab3f44 100644
--- a/include/image.h
+++ b/include/image.h
@@ -164,6 +164,13 @@ typedef struct image_header {
uint8_t ih_name[IH_NMLEN]; /* Image Name */
} image_header_t;
+/*
+ * Some systems (for example LWMON) have very short watchdog periods;
+ * we must make sure to split long operations like memmove() or
+ * crc32() into reasonable chunks.
+ */
+#define CHUNKSZ (64 * 1024)
+
#define image_to_cpu(x) ntohl(x)
#define cpu_to_image(x) htonl(x)
diff --git a/lib_m68k/m68k_linux.c b/lib_m68k/m68k_linux.c
index 3759fd2..f865c0c 100644
--- a/lib_m68k/m68k_linux.c
+++ b/lib_m68k/m68k_linux.c
@@ -37,8 +37,6 @@ DECLARE_GLOBAL_DATA_PTR;
#define LINUX_MAX_ENVS 256
#define LINUX_MAX_ARGS 256
-#define CHUNKSZ (64 * 1024)
-
#ifdef CONFIG_SHOW_BOOT_PROGRESS
# include <status_led.h>
# define SHOW_BOOT_PROGRESS(arg) show_boot_progress(arg)
diff --git a/lib_ppc/ppc_linux.c b/lib_ppc/ppc_linux.c
index 94872a6..4e7734c 100644
--- a/lib_ppc/ppc_linux.c
+++ b/lib_ppc/ppc_linux.c
@@ -49,8 +49,6 @@
#include <asm/cache.h>
#endif
-#define CHUNKSZ (64 * 1024)
-
DECLARE_GLOBAL_DATA_PTR;
extern image_header_t header;