summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-imx/include/mach
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2016-03-30 12:22:29 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2016-04-01 14:06:35 +0200
commitbf1e795d14d7963d387eccd5ccabe98bbfb9684d (patch)
treee90b82e8bbbd6ef5edd7682a6e930e6e88f17b59 /arch/arm/mach-imx/include/mach
parent25ab9fcaf862459650ae052e20527331d3ceefb9 (diff)
downloadbarebox-bf1e795d14d7963d387eccd5ccabe98bbfb9684d.tar.gz
barebox-bf1e795d14d7963d387eccd5ccabe98bbfb9684d.tar.xz
ARM: i.MX: remove unused imx-flash-header.h
All i.MX images are nowadays built with the imx-image tool, so we do not need the header files and Kconfig options anymore. Remove them. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/arm/mach-imx/include/mach')
-rw-r--r--arch/arm/mach-imx/include/mach/barebox.lds.h32
-rw-r--r--arch/arm/mach-imx/include/mach/imx-flash-header.h182
2 files changed, 0 insertions, 214 deletions
diff --git a/arch/arm/mach-imx/include/mach/barebox.lds.h b/arch/arm/mach-imx/include/mach/barebox.lds.h
deleted file mode 100644
index 2e60282c6d..0000000000
--- a/arch/arm/mach-imx/include/mach/barebox.lds.h
+++ /dev/null
@@ -1,32 +0,0 @@
-
-#ifdef CONFIG_ARCH_IMX_INTERNAL_BOOT
-
-#ifdef CONFIG_ARCH_IMX_INTERNAL_BOOT_SERIAL
-#define PRE_IMAGE \
- .pre_image : { \
- KEEP(*(.flash_header_0x0*)) \
- KEEP(*(.dcd_entry_0x0*)) \
- KEEP(*(.image_len_0x0*)) \
- . = 0x400; \
- }
-#else
-
-#define PRE_IMAGE \
- .pre_image : { \
- KEEP(*(.flash_header_start*)) \
- . = 0x100; \
- KEEP(*(.flash_header_0x0100*)) \
- KEEP(*(.dcd_entry_0x0100*)) \
- KEEP(*(.image_len_0x0100*)) \
- . = 0x400; \
- KEEP(*(.flash_header_0x0400*)) \
- KEEP(*(.dcd_entry_0x0400*)) \
- KEEP(*(.image_len_0x0400*)) \
- . = 0x1000; \
- KEEP(*(.flash_header_0x1000*)) \
- KEEP(*(.dcd_entry_0x1000*)) \
- KEEP(*(.image_len_0x1000*)) \
- . = 0x2000; \
- }
-#endif
-#endif
diff --git a/arch/arm/mach-imx/include/mach/imx-flash-header.h b/arch/arm/mach-imx/include/mach/imx-flash-header.h
deleted file mode 100644
index 7a8d5cc306..0000000000
--- a/arch/arm/mach-imx/include/mach/imx-flash-header.h
+++ /dev/null
@@ -1,182 +0,0 @@
-#ifndef __MACH_FLASH_HEADER_H
-#define __MACH_FLASH_HEADER_H
-
-#include <asm/sections.h>
-
-#define __flash_header_start __section(.flash_header_start)
-
-#if defined(CONFIG_ARCH_IMX_INTERNAL_BOOT_NOR)
- #define __flash_header_section __section(.flash_header_0x1000)
- #define __dcd_entry_section __section(.dcd_entry_0x1000)
- #define __image_len_section __section(.image_len_0x1000)
- #define FLASH_HEADER_OFFSET 0x1000
-#elif defined(CONFIG_ARCH_IMX_INTERNAL_BOOT_ONENAND)
- #define __flash_header_section __section(.flash_header_0x0100)
- #define __dcd_entry_section __section(.dcd_entry_0x0100)
- #define __image_len_section __section(.image_len_0x0100)
- #define FLASH_HEADER_OFFSET 0x0100
-#elif defined(CONFIG_ARCH_IMX_INTERNAL_BOOT_SERIAL)
- #define __flash_header_section __section(.flash_header_0x0)
- #define __dcd_entry_section __section(.dcd_entry_0x0)
- #define __image_len_section __section(.image_len_0x0)
- #define FLASH_HEADER_OFFSET 0x0
-#else
- #define __flash_header_section __section(.flash_header_0x0400)
- #define __dcd_entry_section __section(.dcd_entry_0x0400)
- #define __image_len_section __section(.image_len_0x0400)
- #define FLASH_HEADER_OFFSET 0x0400
-#endif
-
-#define __flash_header_0x1000 __section(.flash_header_0x1000)
-#define __dcd_entry_0x1000 __section(.dcd_entry_0x1000)
-#define __image_len_0x1000 __section(.image_len_0x1000)
-
-#define __flash_header_0x0100 __section(.flash_header_0x0100)
-#define __dcd_entry_0x0100 __section(.dcd_entry_0x0100)
-#define __image_len_0x0100 __section(.image_len_0x0100)
-
-#define __flash_header_0x0400 __section(.flash_header_0x0400)
-#define __dcd_entry_0x0400 __section(.dcd_entry_0x0400)
-#define __image_len_0x0400 __section(.image_len_0x0400)
-
-#define __flash_header_0x0 __section(.flash_header_0x0)
-#define __dcd_entry_0x0 __section(.dcd_entry_0x0)
-#define __image_len_0x0 __section(.image_len_0x0)
-
-/*
- * NOR is not automatically copied anywhere by the boot ROM
- */
-#if defined (CONFIG_ARCH_IMX_INTERNAL_BOOT_NOR)
- #define DEST_BASE IMX_CS0_BASE
-#else
- #define DEST_BASE TEXT_BASE
-#endif
-
-#define FLASH_HEADER_BASE (DEST_BASE + FLASH_HEADER_OFFSET)
-
-struct imx_dcd_entry {
- unsigned long ptr_type;
- unsigned long addr;
- unsigned long val;
-};
-
-struct imx_dcd_v2_entry {
- __be32 addr;
- __be32 val;
-};
-
-#define DCD_BARKER 0xb17219e9
-
-struct imx_rsa_public_key {
- unsigned char rsa_exponent[4];
- unsigned char *rsa_modululs;
- unsigned short *exponent_size;
- unsigned short modulus_size;
- unsigned char init_flag;
-};
-
-#define APP_CODE_BARKER 0x000000b1
-
-struct imx_flash_header {
- unsigned long app_code_jump_vector;
- unsigned long app_code_barker;
- unsigned long app_code_csf;
- unsigned long dcd_ptr_ptr;
- unsigned long super_root_key;
- unsigned long dcd;
- unsigned long app_dest;
- unsigned long dcd_barker;
- unsigned long dcd_block_len;
-};
-
-#define IVT_HEADER_TAG 0xd1
-#define IVT_VERSION 0x40
-
-#define DCD_HEADER_TAG 0xd2
-#define DCD_VERSION 0x40
-
-#define DCD_COMMAND_WRITE_TAG 0xcc
-#define DCD_COMMAND_WRITE_PARAM 0x04
-
-/*
- * At least on i.MX5 the ROM copies only full blocks. Unfortunately
- * it does not round up to the next full block, we have to do it
- * ourselves. Use 4095 which should be enough for the largest NAND
- * pages.
- */
-#define DCD_BAREBOX_SIZE (barebox_image_size + 4095)
-
-struct imx_ivt_header {
- uint8_t tag;
- __be16 length;
- uint8_t version;
-} __attribute__((packed));
-
-struct imx_dcd_command {
- uint8_t tag;
- __be16 length;
- uint8_t param;
-} __attribute__((packed));
-
-struct imx_dcd {
- struct imx_ivt_header header;
-#ifndef IMX_INTERNAL_NAND_BBU
- struct imx_dcd_command command;
-#endif
-};
-
-struct imx_boot_data {
- uint32_t start;
- uint32_t size;
- uint32_t plugin;
-};
-
-struct imx_flash_header_v2 {
- struct imx_ivt_header header;
-
- uint32_t entry;
- uint32_t reserved1;
- uint32_t dcd_ptr;
- uint32_t boot_data_ptr;
- uint32_t self;
- uint32_t csf;
- uint32_t reserved2;
-
- struct imx_boot_data boot_data;
- struct imx_dcd dcd;
-};
-
-/*
- * A variant of the standard barebox header in the i.MX FCB
- * format. Needed for i.MX53 NAND boot
- */
-static inline void barebox_arm_imx_fcb_head(void)
-{
- __asm__ __volatile__ (
- ".arm\n"
- " b 1f\n"
- ".word 0x20424346\n" /* FCB */
- ".word 0x1\n"
-#ifdef CONFIG_THUMB2_BAREBOX
- "1: adr r9, 1f + 1\n"
- " bx r9\n"
- ".thumb\n"
- "1:\n"
- "bl barebox_arm_reset_vector\n"
-#else
- "1: b barebox_arm_reset_vector\n"
- ".word 0x0\n"
- ".word 0x0\n"
-#endif
- ".word 0x0\n"
- ".word 0x0\n"
-
- ".asciz \"barebox\"\n"
- ".word _text\n" /* text base. If copied there,
- * barebox can skip relocation
- */
- ".word _barebox_image_size\n" /* image size to copy */
- );
-}
-
-#endif /* __MACH_FLASH_HEADER_H */