summaryrefslogtreecommitdiff
path: root/packages
diff options
context:
space:
mode:
authorJohn Bowler <jbowler@nslu2-linux.org>2005-10-05 18:11:49 +0000
committerOpenEmbedded Project <openembedded-devel@lists.openembedded.org>2005-10-05 18:11:49 +0000
commit2260652d80d4481e2a4950677bf1ffee2e9ab02b (patch)
tree4fa7d98c144247c0649a830180c012f97988c484 /packages
parent962eb38eb1b819c02545cbc7e7ea15af7856c6b3 (diff)
nslu2-kernel: postprocess the kernel image to set mach-type, support le
The mach-type is now set by instructions appended to the kernel image, in 2.6.14 kernels the mach-type patch has been removed. le support is added by adding the appropriate switch-to-le instructions too (LE support is incomplete because the flash read patch is not in.)
Diffstat (limited to 'packages')
-rw-r--r--packages/linux/nslu2-kernel.inc44
-rw-r--r--packages/linux/nslu2-kernel/2.6.14/50-nslu2-arch.patch11
-rw-r--r--packages/linux/nslu2-kernel_2.6.14-rc2.bb4
-rw-r--r--packages/linux/nslu2-kernel_2.6.14-rc3.bb5
-rw-r--r--packages/linux/openslug-kernel-2.6.14-rc3/defconfig8
5 files changed, 53 insertions, 19 deletions
diff --git a/packages/linux/nslu2-kernel.inc b/packages/linux/nslu2-kernel.inc
index 695268eb18..d55d05f294 100644
--- a/packages/linux/nslu2-kernel.inc
+++ b/packages/linux/nslu2-kernel.inc
@@ -54,6 +54,8 @@ DESCRIPTION = "Linux kernel for the Linksys NSLU2 device"
LICENSE = "GPL"
MAINTAINER = "John Bowler <jbowler@acm.org>"
+DEPENDS += "devio-native"
+
# Linux kernel source has the general form linux-X.Y.Z-patchP,
# X.Y is the major version number, Z (which may have multiple
# parts) is a sub-version and 'patch' is something like 'mm' or
@@ -240,15 +242,55 @@ addtask unpacklocal before do_patch after do_unpack
do_configure_prepend() {
install -m 0644 ${WORKDIR}/defconfig ${S}/.config
+ if test '${NSLU2_ARCH_TYPE}' = l
+ then
+ sed -i '/CONFIG_CPU_BIG_ENDIAN/d' '${S}/.config'
+ else
+ echo 'CONFIG_CPU_BIG_ENDIAN=y' >>'${S}/.config'
+ fi
echo "CONFIG_CMDLINE=\"${CMDLINE}\"" >> ${S}/.config
rm -rf ${S}/include/asm-arm/arch ${S}/include/asm-arm/proc \
${S}/include/asm-arm/.proc ${S}/include/asm-arm/.arch
}
+# This function adds the required prefix to the image to deal with two
+# problems:
+#
+# 1) The machine type set by RedBoot is wrong - the type for an ixdp425, not an NSLU2
+# e3a01c02 e3811055
+# 2) For LE kernels it is necessary to prefix change-to-le code to the kernel image:
+# ee110f10 e3c00080 ee010f10
+#
+# The argument to the function is the destination directory
+redboot_fixup_armeb() {
+ rm -f "$1".new
+ devio '<<arch/${ARCH}/boot/${KERNEL_IMAGETYPE}' >"$1".new \
+ 'wb 0xe3a01c02,4' \
+ 'wb 0xe3811055,4' \
+ 'cp$'
+ mv "$1".new "$1"
+}
+
+redboot_fixup_arm() {
+ rm -f "$1".new
+ devio '<<arch/${ARCH}/boot/${KERNEL_IMAGETYPE}' >"$1".new \
+ 'wl 0xe3a01c02,4' \
+ 'wl 0xe3811055,4' \
+ 'wl 0xee110f10,4' \
+ 'wl 0xe3c00080,4' \
+ 'wl 0xee010f10,4' \
+ 'cp$'
+ mv "$1".new "$1"
+}
+
+do_install_append() {
+ redboot_fixup '${STAGING_KERNEL_DIR}/${KERNEL_IMAGETYPE}'
+}
+
do_deploy[dirs] = "${S}"
do_deploy() {
install -d ${DEPLOY_DIR}/images
- install -m 0644 arch/${ARCH}/boot/${KERNEL_IMAGETYPE} ${DEPLOY_DIR}/images/${KERNEL_IMAGETYPE}-${N2K_SUFFIX}
+ redboot_fixup '${DEPLOY_DIR}/images/${KERNEL_IMAGETYPE}-${N2K_SUFFIX}'
}
addtask deploy before do_build after do_compile
diff --git a/packages/linux/nslu2-kernel/2.6.14/50-nslu2-arch.patch b/packages/linux/nslu2-kernel/2.6.14/50-nslu2-arch.patch
index de9499f1fc..33d91aa35e 100644
--- a/packages/linux/nslu2-kernel/2.6.14/50-nslu2-arch.patch
+++ b/packages/linux/nslu2-kernel/2.6.14/50-nslu2-arch.patch
@@ -8,17 +8,6 @@
defined(CONFIG_ARCH_IXP2000) || \
defined(CONFIG_ARCH_LH7A40X) || \
defined(CONFIG_ARCH_OMAP)
---- linux-2.6.11/.pc/2.6.patch/arch/arm/boot/compressed/head-xscale.S 2005-03-01 23:37:52.000000000 -0800
-+++ linux-2.6.11/arch/arm/boot/compressed/head-xscale.S 2005-06-17 17:51:32.546985425 -0700
-@@ -47,3 +47,8 @@
- orr r7, r7, #(MACH_TYPE_GTWX5715 & 0xff00)
- #endif
-
-+#ifdef CONFIG_MACH_NSLU2
-+ mov r7, #(MACH_TYPE_NSLU2 & 0xff)
-+ orr r7, r7, #(MACH_TYPE_NSLU2 & 0xff00)
-+#endif
-+
--- linux-2.6.11/.pc/2.6.patch/arch/arm/mach-ixp4xx/Kconfig 2005-06-17 17:51:27.365770810 -0700
+++ linux-2.6.11/arch/arm/mach-ixp4xx/Kconfig 2005-06-17 17:51:32.560983303 -0700
@@ -43,6 +43,12 @@
diff --git a/packages/linux/nslu2-kernel_2.6.14-rc2.bb b/packages/linux/nslu2-kernel_2.6.14-rc2.bb
index 0e70b1ed0e..e843fcfa29 100644
--- a/packages/linux/nslu2-kernel_2.6.14-rc2.bb
+++ b/packages/linux/nslu2-kernel_2.6.14-rc2.bb
@@ -8,7 +8,7 @@ PR_CONFIG = "0"
# Increment the number below (i.e. the digits after PR) when
# making changes within this file or for changes to the patches
# applied to the kernel.
-PR = "r5.${PR_CONFIG}"
+PR = "r6.${PR_CONFIG}"
include nslu2-kernel.inc
@@ -43,4 +43,4 @@ N2K_PATCHES = "\
# specific to the bootstrap of *this* kernel in here - DISTRO specfic
# config must be in CMDLINE_ROOT (see the full definition of CMDLINE
# in nslu2-kernel.inc)
-CMDLINE_KERNEL_OPTIONS = ""
+CMDLINE_KERNEL_OPTIONS = "x1205.hctosys=1"
diff --git a/packages/linux/nslu2-kernel_2.6.14-rc3.bb b/packages/linux/nslu2-kernel_2.6.14-rc3.bb
index e6ec4987ec..70962dee71 100644
--- a/packages/linux/nslu2-kernel_2.6.14-rc3.bb
+++ b/packages/linux/nslu2-kernel_2.6.14-rc3.bb
@@ -8,7 +8,7 @@ PR_CONFIG = "0"
# Increment the number below (i.e. the digits after PR) when
# making changes within this file or for changes to the patches
# applied to the kernel.
-PR = "r0.${PR_CONFIG}"
+PR = "r1.${PR_CONFIG}"
include nslu2-kernel.inc
@@ -33,7 +33,6 @@ N2K_PATCHES = "\
file://50-nslu2-arch.patch;patch=1 \
file://50-nslu2-beeper.patch;patch=1 \
file://50-nslu2-general.patch;patch=1 \
- file://90-arm-le.patch;patch=1 \
file://90-ixp4xx-pci-le.patch;patch=1 \
file://anonymiser.patch;patch=1 \
"
@@ -42,4 +41,4 @@ N2K_PATCHES = "\
# specific to the bootstrap of *this* kernel in here - DISTRO specfic
# config must be in CMDLINE_ROOT (see the full definition of CMDLINE
# in nslu2-kernel.inc)
-CMDLINE_KERNEL_OPTIONS = ""
+CMDLINE_KERNEL_OPTIONS = "x1205.hctosys=1"
diff --git a/packages/linux/openslug-kernel-2.6.14-rc3/defconfig b/packages/linux/openslug-kernel-2.6.14-rc3/defconfig
index 422534267c..405a2f4400 100644
--- a/packages/linux/openslug-kernel-2.6.14-rc3/defconfig
+++ b/packages/linux/openslug-kernel-2.6.14-rc3/defconfig
@@ -1,7 +1,7 @@
#
# Automatically generated make config: don't edit
-# Linux kernel version: 2.6.14-rc2
-# Sat Sep 24 16:19:17 2005
+# Linux kernel version: 2.6.14-rc3
+# Tue Oct 4 23:19:43 2005
#
CONFIG_ARM=y
CONFIG_MMU=y
@@ -278,6 +278,7 @@ CONFIG_IP_NF_FILTER=m
CONFIG_IP_NF_TARGET_LOG=m
CONFIG_IP_NF_TARGET_ULOG=m
CONFIG_IP_NF_TARGET_TCPMSS=m
+# CONFIG_IP_NF_TARGET_NFQUEUE is not set
CONFIG_IP_NF_NAT=m
CONFIG_IP_NF_NAT_NEEDED=y
CONFIG_IP_NF_TARGET_MASQUERADE=m
@@ -304,6 +305,7 @@ CONFIG_IP_NF_TARGET_CLASSIFY=m
#
# CONFIG_IP6_NF_QUEUE is not set
# CONFIG_IP6_NF_IPTABLES is not set
+# CONFIG_IP6_NF_TARGET_NFQUEUE is not set
#
# Bridge: Netfilter Configuration
@@ -602,6 +604,7 @@ CONFIG_BLK_DEV_DM=m
# CONFIG_FUSION is not set
# CONFIG_FUSION_SPI is not set
# CONFIG_FUSION_FC is not set
+# CONFIG_FUSION_SAS is not set
#
# IEEE 1394 (FireWire) support
@@ -639,6 +642,7 @@ CONFIG_NET_ETHERNET=y
CONFIG_MII=y
# CONFIG_HAPPYMEAL is not set
# CONFIG_SUNGEM is not set
+# CONFIG_CASSINI is not set
# CONFIG_NET_VENDOR_3COM is not set
# CONFIG_SMC91X is not set
# CONFIG_DM9000 is not set