summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 6aa3d3b)
raw | patch | inline | side by side (parent: 6aa3d3b)
author | Torkel Lundgren <torkel.lundgren@enea.com> | |
Tue, 28 Sep 2010 09:05:36 +0000 (11:05 +0200) | ||
committer | Wolfgang Denk <wd@denx.de> | |
Tue, 28 Sep 2010 12:42:26 +0000 (14:42 +0200) |
Add OSE as operating system for mkimage and bootm.
Signed-off-by: Torkel Lundgren <torkel.lundgren@enea.com>
Signed-off-by: Torkel Lundgren <torkel.lundgren@enea.com>
common/cmd_bootm.c | patch | blob | history | |
common/image.c | patch | blob | history | |
include/config_defaults.h | patch | blob | history | |
include/image.h | patch | blob | history |
diff --git a/common/cmd_bootm.c b/common/cmd_bootm.c
index 46efd7741f7fded7de4dda437bfaac97f3a82867..db59e6f295d6ff97861a576cdcf7d1ce80c115f9 100644 (file)
--- a/common/cmd_bootm.c
+++ b/common/cmd_bootm.c
#ifdef CONFIG_BOOTM_RTEMS
static boot_os_fn do_bootm_rtems;
#endif
+#if defined(CONFIG_BOOTM_OSE)
+static boot_os_fn do_bootm_ose;
+#endif
#if defined(CONFIG_CMD_ELF)
static boot_os_fn do_bootm_vxworks;
static boot_os_fn do_bootm_qnxelf;
#ifdef CONFIG_BOOTM_RTEMS
[IH_OS_RTEMS] = do_bootm_rtems,
#endif
+#if defined(CONFIG_BOOTM_OSE)
+ [IH_OS_OSE] = do_bootm_ose,
+#endif
#if defined(CONFIG_CMD_ELF)
[IH_OS_VXWORKS] = do_bootm_vxworks,
[IH_OS_QNX] = do_bootm_qnxelf,
}
#endif /* CONFIG_BOOTM_RTEMS */
+#if defined(CONFIG_BOOTM_OSE)
+static int do_bootm_ose (int flag, int argc, char * const argv[],
+ bootm_headers_t *images)
+{
+ void (*entry_point)(void);
+
+ if ((flag != 0) && (flag != BOOTM_STATE_OS_GO))
+ return 1;
+
+#if defined(CONFIG_FIT)
+ if (!images->legacy_hdr_valid) {
+ fit_unsupported_reset ("OSE");
+ return 1;
+ }
+#endif
+
+ entry_point = (void (*)(void))images->ep;
+
+ printf ("## Transferring control to OSE (at address %08lx) ...\n",
+ (ulong)entry_point);
+
+ show_boot_progress (15);
+
+ /*
+ * OSE Parameters:
+ * None
+ */
+ (*entry_point)();
+
+ return 1;
+}
+#endif /* CONFIG_BOOTM_OSE */
+
#if defined(CONFIG_CMD_ELF)
static int do_bootm_vxworks (int flag, int argc, char * const argv[],
bootm_headers_t *images)
diff --git a/common/image.c b/common/image.c
index fcb938b08e3839d3809e514b1b0188d34690a8a2..3a2f25e5af4de7f64e9e3e31bc61ef456e9e97c3 100644 (file)
--- a/common/image.c
+++ b/common/image.c
{ IH_OS_LYNXOS, "lynxos", "LynxOS", },
#endif
{ IH_OS_NETBSD, "netbsd", "NetBSD", },
+ { IH_OS_OSE, "ose", "Enea OSE", },
{ IH_OS_RTEMS, "rtems", "RTEMS", },
{ IH_OS_U_BOOT, "u-boot", "U-Boot", },
#if defined(CONFIG_CMD_ELF) || defined(USE_HOSTCC)
index 0337163c2a21529a9d76639c51fe65bf40b4bada..abdf3beb0c139fdcf6b25dcaf6047e7022031b56 100644 (file)
/* Support bootm-ing different OSes */
#define CONFIG_BOOTM_LINUX 1
#define CONFIG_BOOTM_NETBSD 1
+#define CONFIG_BOOTM_OSE 1
#define CONFIG_BOOTM_RTEMS 1
#define CONFIG_GZIP 1
diff --git a/include/image.h b/include/image.h
index bcc08d1a73224bb715d15983adea4767ce0e85fc..18a9f0e964d3c96fc707af01eccfdc18a1501edc 100644 (file)
--- a/include/image.h
+++ b/include/image.h
#define IH_OS_ARTOS 19 /* ARTOS */
#define IH_OS_UNITY 20 /* Unity OS */
#define IH_OS_INTEGRITY 21 /* INTEGRITY */
+#define IH_OS_OSE 22 /* OSE */
/*
* CPU Architecture Codes (supported by Linux)