summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--packages/arm-kernel-shim/.mtn2git_empty0
-rw-r--r--packages/arm-kernel-shim/arm-kernel-shim_1.4.11.bb34
-rw-r--r--packages/arm-kernel-shim/files/.mtn2git_empty0
-rw-r--r--packages/arm-kernel-shim/files/config-nas100d.h30
-rw-r--r--packages/arm-kernel-shim/files/config-nslu2.h30
-rw-r--r--packages/arm-kernel-shim/files/disable-commandline.patch28
6 files changed, 122 insertions, 0 deletions
diff --git a/packages/arm-kernel-shim/.mtn2git_empty b/packages/arm-kernel-shim/.mtn2git_empty
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/packages/arm-kernel-shim/.mtn2git_empty
diff --git a/packages/arm-kernel-shim/arm-kernel-shim_1.4.11.bb b/packages/arm-kernel-shim/arm-kernel-shim_1.4.11.bb
new file mode 100644
index 0000000000..3f5da24991
--- /dev/null
+++ b/packages/arm-kernel-shim/arm-kernel-shim_1.4.11.bb
@@ -0,0 +1,34 @@
+DESCRIPTION = "ARM Kernel Shim"
+SECTION = ""
+PRIORITY = "optional"
+HOMEPAGE = "http://wiki.buici.com/twiki/bin/view/Main/ApexBootloader"
+LICENSE = "GPL"
+PR = "r1"
+
+SRC_URI = "ftp://ftp.buici.com/pub/apex/apex-${PV}.tar.gz \
+ file://disable-commandline.patch;patch=1 \
+ file://config-nslu2.h \
+ file://config-nas100d.h"
+S = ${WORKDIR}/apex-${PV}/arm-kernel-shim
+
+EXTRA_OEMAKE_append = " CROSS_COMPILE=${CROSS_DIR}/bin/${HOST_PREFIX}"
+
+oe_runmake() {
+ # NSLU2
+ cp ${WORKDIR}/config-nslu2.h ${S}/config.h
+ rm -f ${S}/main.o
+ oenote make ${PARALLEL_MAKE} TOOLS=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nslu2
+ make ${PARALLEL_MAKE} TOOLS=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nslu2 || die "oe_runmake failed"
+ # NAS100d
+ cp ${WORKDIR}/config-nas100d.h ${S}/config.h
+ rm -f ${S}/main.o
+ oenote make ${PARALLEL_MAKE} TOOLS=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nas100d
+ make ${PARALLEL_MAKE} TOOLS=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nas100d || die "oe_runmake failed"
+}
+
+do_populate_staging() {
+ install -d ${STAGING_LOADER_DIR}
+ . ${CONFIG_SITE}
+ cp ${S}/arm-kernel-shim-nslu2.bin ${STAGING_LOADER_DIR}/
+ cp ${S}/arm-kernel-shim-nas100d.bin ${STAGING_LOADER_DIR}/
+}
diff --git a/packages/arm-kernel-shim/files/.mtn2git_empty b/packages/arm-kernel-shim/files/.mtn2git_empty
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/packages/arm-kernel-shim/files/.mtn2git_empty
diff --git a/packages/arm-kernel-shim/files/config-nas100d.h b/packages/arm-kernel-shim/files/config-nas100d.h
new file mode 100644
index 0000000000..7547061165
--- /dev/null
+++ b/packages/arm-kernel-shim/files/config-nas100d.h
@@ -0,0 +1,30 @@
+/* config.h
+
+ written by Marc Singer
+ 23 Jun 2006
+
+ Copyright (C) 2006 Marc Singer
+
+ -----------
+ DESCRIPTION
+ -----------
+
+*/
+
+#if !defined (__CONFIG_H__)
+# define __CONFIG_H__
+
+#define PHYS_PARAMS 0xc0000100 /* Address for the parameter list */
+
+#define RAM_BANK0_START 0x00000000
+#define RAM_BANK0_LENGTH 0x02000000
+
+//#define RAM_BANK1_START 0xd0000000
+//#define RAM_BANK1_LENGTH 0x10000000
+
+//#define COMMANDLINE\
+// "console=ttyAMA0 root=/dev/memblk0 rootfstype=jffs"
+
+#define MACH_TYPE 597
+
+#endif /* __CONFIG_H__ */
diff --git a/packages/arm-kernel-shim/files/config-nslu2.h b/packages/arm-kernel-shim/files/config-nslu2.h
new file mode 100644
index 0000000000..e1229edd59
--- /dev/null
+++ b/packages/arm-kernel-shim/files/config-nslu2.h
@@ -0,0 +1,30 @@
+/* config.h
+
+ written by Marc Singer
+ 23 Jun 2006
+
+ Copyright (C) 2006 Marc Singer
+
+ -----------
+ DESCRIPTION
+ -----------
+
+*/
+
+#if !defined (__CONFIG_H__)
+# define __CONFIG_H__
+
+#define PHYS_PARAMS 0xc0000100 /* Address for the parameter list */
+
+#define RAM_BANK0_START 0x00000000
+#define RAM_BANK0_LENGTH 0x02000000
+
+//#define RAM_BANK1_START 0xd0000000
+//#define RAM_BANK1_LENGTH 0x10000000
+
+//#define COMMANDLINE\
+// "console=ttyAMA0 root=/dev/memblk0 rootfstype=jffs"
+
+#define MACH_TYPE 865
+
+#endif /* __CONFIG_H__ */
diff --git a/packages/arm-kernel-shim/files/disable-commandline.patch b/packages/arm-kernel-shim/files/disable-commandline.patch
new file mode 100644
index 0000000000..d8c59f1a6b
--- /dev/null
+++ b/packages/arm-kernel-shim/files/disable-commandline.patch
@@ -0,0 +1,28 @@
+--- arm-kernel-shim/main.c~ 2006-07-21 11:12:07.000000000 +0930
++++ arm-kernel-shim/main.c 2007-01-28 11:56:35.000000000 +1030
+@@ -47,7 +47,9 @@
+
+ #define NAKED __attribute__((naked))
+
++#if defined (COMMANDLINE)
+ const char __attribute__((section(".rodata"))) cmdline[] = COMMANDLINE;
++#endif
+
+ void NAKED __attribute__((section(".boot"))) boot (u32 r0, u32 r1, u32 r2)
+ {
+@@ -82,6 +84,7 @@
+ pv += H_SIZE(pv)*4;
+ #endif
+
++#if defined (COMMANDLINE)
+ /* Command line */
+ H_SIZE(pv) = tag_size(tag_cmdline) + (sizeof (cmdline)+1+3)/4;
+ H_TAG(pv) = ATAG_CMDLINE;
+@@ -91,6 +94,7 @@
+ P_CMDLINE(pv)->cmdline[i] = cmdline[i];
+ }
+ pv += H_SIZE(pv)*4;
++#endif
+
+ /* End */
+ H_SIZE(pv) = 0;