summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRod Whitby <rod@whitby.id.au>2006-01-11 10:23:01 +0000
committerOpenEmbedded Project <openembedded-devel@lists.openembedded.org>2006-01-11 10:23:01 +0000
commit8724f16eaa787e6b9ef103640c374286bbd4db7a (patch)
tree6bcf59e2175532342e1f826e58cb86bc03825b73
parent8654061bea23f92c20eab7925e702d1b7562f130 (diff)
slugos: Enabled JFFS2 endianness to be controlled.
-rw-r--r--conf/distro/debianslug.conf1
-rw-r--r--conf/distro/ludeos.conf2
-rw-r--r--conf/distro/openslug.conf1
-rw-r--r--conf/distro/slugos.conf3
-rw-r--r--conf/distro/ucslugc.conf1
-rw-r--r--packages/linux/nas100d-kernel.inc14
-rw-r--r--packages/linux/nslu2-kernel.inc14
-rw-r--r--packages/meta/slugos-image.bb3
8 files changed, 35 insertions, 4 deletions
diff --git a/conf/distro/debianslug.conf b/conf/distro/debianslug.conf
index 163e4cd1b6..9d448ea826 100644
--- a/conf/distro/debianslug.conf
+++ b/conf/distro/debianslug.conf
@@ -10,6 +10,7 @@ DISTRO_VERSION = "3.1-beta"
DISTRO_FEED = "unstable"
DISTRO_TYPE = "beta"
SLUGOS_IMAGENAME = "debianslug"
+SLUGOS_IMAGESEX = "little-endian"
# debianslug builds a complete image (not just the parts)
SLUGOS_FLASH_IMAGE = "yes"
diff --git a/conf/distro/ludeos.conf b/conf/distro/ludeos.conf
index 21e8e553c7..87fee2bd53 100644
--- a/conf/distro/ludeos.conf
+++ b/conf/distro/ludeos.conf
@@ -6,6 +6,8 @@ DISTRO_NAME = "LudeOS"
DISTRO_VERSION = "0.1-alpha"
DISTRO_FEED = "unstable"
DISTRO_TYPE = "beta"
+SLUGOS_IMAGENAME = "ludeos"
+SLUGOS_IMAGESEX = "big-endian"
ARCH_BYTE_SEX = "le"
ARM_INSTRUCTION_SET = "arm"
diff --git a/conf/distro/openslug.conf b/conf/distro/openslug.conf
index 85f17b18ac..e21859b082 100644
--- a/conf/distro/openslug.conf
+++ b/conf/distro/openslug.conf
@@ -10,6 +10,7 @@ DISTRO_VERSION = "3.1-beta"
DISTRO_FEED = "unstable"
DISTRO_TYPE = "beta"
SLUGOS_IMAGENAME = "openslug"
+SLUGOS_IMAGESEX = "big-endian"
# openslug builds a complete image (not just the parts)
SLUGOS_FLASH_IMAGE = "yes"
diff --git a/conf/distro/slugos.conf b/conf/distro/slugos.conf
index 4146e4a9a0..15a2788958 100644
--- a/conf/distro/slugos.conf
+++ b/conf/distro/slugos.conf
@@ -70,6 +70,9 @@ DISTRO_BASE = ":slugos"
# change the generated image).
SLUGOS_IMAGENAME ?= "${DISTRO_NAME}"
+# default to native-endian JFFS2 partitions
+SLUGOS_IMAGESEX ?= "${@['big-endian', 'little-endian'][bb.data.getVar('ARCH_BYTE_SEX', d, 1) == 'le']}"
+
# pull in the frozen list of bbfiles - this sets BBFILES and this will override any
# setting in local.conf Since this depends on ${DISTRO} it doesn't actually do
# anything by default unless conf/distro/${DISTRO}-packages.conf exists.
diff --git a/conf/distro/ucslugc.conf b/conf/distro/ucslugc.conf
index ea6b14f310..c9c70ca544 100644
--- a/conf/distro/ucslugc.conf
+++ b/conf/distro/ucslugc.conf
@@ -8,6 +8,7 @@ DISTRO_VERSION = "3-beta"
DISTRO_FEED = "unstable"
DISTRO_TYPE = "beta"
SLUGOS_IMAGENAME = "ucslugc"
+SLUGOS_IMAGESEX = "big-endian"
# NOTE: to build new packages set UCSLUGC_EXTRA_BBFILES to the full path name to
# the .bb files for the packages to build - see ucslugc-packages.conf in this
diff --git a/packages/linux/nas100d-kernel.inc b/packages/linux/nas100d-kernel.inc
index 6dd8a46001..69e9f4d285 100644
--- a/packages/linux/nas100d-kernel.inc
+++ b/packages/linux/nas100d-kernel.inc
@@ -210,7 +210,19 @@ do_configure_prepend() {
then
echo 'CONFIG_CPU_BIG_ENDIAN=y' >>'${S}/.config'
fi
- sed -e '/CONFIG_CPU_BIG_ENDIAN/d' -e '/CONFIG_CMDLINE=/d' '${WORKDIR}/defconfig' >>'${S}/.config'
+ if test '${SLUGOS_IMAGESEX}' = big-endian
+ then
+ echo 'CONFIG_JFFS2_BIG_ENDIAN=y' >>'${S}/.config'
+ fi
+ if test '${SLUGOS_IMAGESEX}' = little-endian
+ then
+ echo 'CONFIG_JFFS2_LITTLE_ENDIAN=y' >>'${S}/.config'
+ fi
+ sed -e '/CONFIG_CPU_BIG_ENDIAN/d' -e '/CONFIG_CMDLINE=/d' \
+ -e '/CONFIG_JFFS2_NATIVE_ENDIAN=/d' \
+ -e '/CONFIG_JFFS2_BIG_ENDIAN=/d' \
+ -e '/CONFIG_JFFS2_LITTLE_ENDIAN=/d' \
+ '${WORKDIR}/defconfig' >>'${S}/.config'
rm -rf ${S}/include/asm-arm/arch ${S}/include/asm-arm/proc \
${S}/include/asm-arm/.proc ${S}/include/asm-arm/.arch
}
diff --git a/packages/linux/nslu2-kernel.inc b/packages/linux/nslu2-kernel.inc
index f41b61c033..ee0d233ac2 100644
--- a/packages/linux/nslu2-kernel.inc
+++ b/packages/linux/nslu2-kernel.inc
@@ -200,7 +200,19 @@ do_configure_prepend() {
then
echo 'CONFIG_CPU_BIG_ENDIAN=y' >>'${S}/.config'
fi
- sed -e '/CONFIG_CPU_BIG_ENDIAN/d' -e '/CONFIG_CMDLINE=/d' '${WORKDIR}/defconfig' >>'${S}/.config'
+ if test '${SLUGOS_IMAGESEX}' = big-endian
+ then
+ echo 'CONFIG_JFFS2_BIG_ENDIAN=y' >>'${S}/.config'
+ fi
+ if test '${SLUGOS_IMAGESEX}' = little-endian
+ then
+ echo 'CONFIG_JFFS2_LITTLE_ENDIAN=y' >>'${S}/.config'
+ fi
+ sed -e '/CONFIG_CPU_BIG_ENDIAN/d' -e '/CONFIG_CMDLINE=/d' \
+ -e '/CONFIG_JFFS2_NATIVE_ENDIAN=/d' \
+ -e '/CONFIG_JFFS2_BIG_ENDIAN=/d' \
+ -e '/CONFIG_JFFS2_LITTLE_ENDIAN=/d' \
+ '${WORKDIR}/defconfig' >>'${S}/.config'
rm -rf ${S}/include/asm-arm/arch ${S}/include/asm-arm/proc \
${S}/include/asm-arm/.proc ${S}/include/asm-arm/.arch
}
diff --git a/packages/meta/slugos-image.bb b/packages/meta/slugos-image.bb
index 6a4db265d8..b80b6f7b3a 100644
--- a/packages/meta/slugos-image.bb
+++ b/packages/meta/slugos-image.bb
@@ -22,9 +22,8 @@ N2K_SUFFIX ?= "nslu2${ARCH_BYTE_SEX}"
# Why have anything in the config file to control the image build - why not
# just select a different image .bb file (e.g. slugos-ramdisk-image.bb) to
# build with different options.
-# IMAGE_SEX = "${@['big-endian', 'little-endian'][bb.data.getVar('ARCH_BYTE_SEX', d, 1) == 'le']}"
SLUGOS_DEVICE_TABLE = "${@bb.which(bb.data.getVar('BBPATH', d, 1), 'files/device_table-slugos.txt')}"
-EXTRA_IMAGECMD_jffs2 = "--pad --big-endian --eraseblock=0x20000 -D ${SLUGOS_DEVICE_TABLE}"
+EXTRA_IMAGECMD_jffs2 = "--pad --${SLUGOS_IMAGESEX} --eraseblock=0x20000 -D ${SLUGOS_DEVICE_TABLE}"
# IMAGE_PREPROCESS_COMMAND is run before making the image. In SlugOS the
# kernel image is removed from the root file system to recover the space used -