Skip to contentSkip to conversation

zaurus.inc: adapt jffs2 and sum.jffs2 to changes in oe-core

PATCH Applied Andrea Adami 3 participants 4 messages Dec 8, 2011 – Dec 11, 2011

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 zaurus.inc: adapt jffs2 and sum.jffs2 to changes in oe-core

* in oe-core jffs2 summary has been added to image_types.bbclass and
* IMAGE_CMD_jffs2 now includes '-n' to skip cleanmarkers node creation
* so we need to customize only padding, endianness and compression mode
* While there remove compression settings which are handled in kernel.
* This allows us to use the same string for mkfs.jffs2 and for sumtool.

---
 conf/machine/include/zaurus.inc |   13 +++----------
 1 files changed, 3 insertions(+), 10 deletions(-)
conf/machine/include/zaurus.inc +3 -10
index b488f37..0a9b1c5 100644
@@ -9,18 +9,11 @@ ERASEBLOCKSIZE_akita = "0x20000"
 # C3100 and C3200 have same 128MiB NAND device as akita
 ERASEBLOCKSIZE_spitz = "0x20000"
 
-IMAGE_FSTYPES += "jffs2 tar.gz"
+IMAGE_FSTYPES += "tar.gz jffs2 sum.jffs2"
 
 # kernel now supports favourlzo
-IMAGE_CMD_jffs2 = "mkfs.jffs2 --root=${IMAGE_ROOTFS} --faketime -m favourlzo \
-                   --output=${T}/${IMAGE_NAME}.rootfs.jffs2 --pad --little-endian --eraseblock=${ERASEBLOCKSIZE} -n \
-                   && sumtool -i ${T}/${IMAGE_NAME}.rootfs.jffs2 \
-                   -o ${T}/${IMAGE_NAME}.rootfs.jffs2.summary \
-                   --eraseblock=${ERASEBLOCKSIZE} -l -p; \
-                   cat ${T}/${IMAGE_NAME}.rootfs.jffs2 > ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.jffs2; \
-                   rm ${T}/${IMAGE_NAME}.rootfs.jffs2; \
-                   cat ${T}/${IMAGE_NAME}.rootfs.jffs2.summary > ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.summary.jffs2; \
-                   rm ${T}/${IMAGE_NAME}.rootfs.jffs2.summary;"
+EXTRA_IMAGECMD_jffs2 = "-p -l --eraseblock=${ERASEBLOCKSIZE}"
+EXTRA_IMAGECMD_sum.jffs2 = "${EXTRA_IMAGECMD_jffs2}"
 
 EXTRA_IMAGEDEPENDS += "zaurus-installer"
 
Signature · 1 line
1.7.3.4
#1 lore raw
Quoted 35 lines · On Thursday 08 December 2011 17:06:30 Andrea Adami wrote:

* in oe-core jffs2 summary has been added to image_types.bbclass and
* IMAGE_CMD_jffs2 now includes '-n' to skip cleanmarkers node creation
* so we need to customize only padding, endianness and compression mode
* While there remove compression settings which are handled in kernel.
* This allows us to use the same string for mkfs.jffs2 and for sumtool.

---
 conf/machine/include/zaurus.inc |   13 +++----------
 1 files changed, 3 insertions(+), 10 deletions(-)
(quoted diff) +0 -0

b/conf/machine/include/zaurus.inc index b488f37..0a9b1c5 100644

conf/machine/include/zaurus.inc +1 -2
@@ -9,18 +9,11 @@ ERASEBLOCKSIZE_akita = "0x20000"
 # C3100 and C3200 have same 128MiB NAND device as akita
 ERASEBLOCKSIZE_spitz = "0x20000"
 
-IMAGE_FSTYPES += "jffs2 tar.gz"
+IMAGE_FSTYPES += "tar.gz jffs2 sum.jffs2"
 
 # kernel now supports favourlzo
-IMAGE_CMD_jffs2 = "mkfs.jffs2 --root=${IMAGE_ROOTFS} --faketime -m

favourlzo \ - --output=${T}/${IMAGE_NAME}.rootfs.jffs2
--pad --little-endian --eraseblock=${ERASEBLOCKSIZE} -n \ -
&& sumtool -i ${T}/${IMAGE_NAME}.rootfs.jffs2 \ - -o
${T}/${IMAGE_NAME}.rootfs.jffs2.summary \

conf/machine/include/zaurus.inc +0 -2
-                   --eraseblock=${ERASEBLOCKSIZE} -l -p; \
-                   cat ${T}/${IMAGE_NAME}.rootfs.jffs2 >

${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.jffs2; \ - rm
${T}/${IMAGE_NAME}.rootfs.jffs2; \
- cat ${T}/${IMAGE_NAME}.rootfs.jffs2.summary >
${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.summary.jffs2; \ -
rm ${T}/${IMAGE_NAME}.rootfs.jffs2.summary;"

conf/machine/include/zaurus.inc ERASEBLOCKSIZE_akita = "0x20000" · line 18

Quoted 4 lines
conf/machine/include/zaurus.inc +2 -0
+EXTRA_IMAGECMD_jffs2 = "-p -l --eraseblock=${ERASEBLOCKSIZE}"
+EXTRA_IMAGECMD_sum.jffs2 = "${EXTRA_IMAGECMD_jffs2}"
 
 EXTRA_IMAGEDEPENDS += "zaurus-installer"

Merged to meta-handheld, thanks.

Cheers,
Paul

Signature · 2 lines
Paul Eggleton
Intel Open Source Technology Centre
#2 lore raw
In reply to Andrea Adami
Quoted 16 lines · Andrea Adami

* in oe-core jffs2 summary has been added to image_types.bbclass and
* IMAGE_CMD_jffs2 now includes '-n' to skip cleanmarkers node creation
* so we need to customize only padding, endianness and compression mode
* While there remove compression settings which are handled in kernel.
* This allows us to use the same string for mkfs.jffs2 and for sumtool.

---
 conf/machine/include/zaurus.inc |   13 +++----------
 1 files changed, 3 insertions(+), 10 deletions(-)
conf/machine/include/zaurus.inc +0 -0
index b488f37..0a9b1c5 100644

conf/machine/include/zaurus.inc ERASEBLOCKSIZE_akita = "0x20000" · line 12

Quoted 5 lines
conf/machine/include/zaurus.inc +1 -1
@@ -9,18 +9,11 @@ ERASEBLOCKSIZE_akita = "0x20000"
 # C3100 and C3200 have same 128MiB NAND device as akita
 ERASEBLOCKSIZE_spitz = "0x20000"
 
-IMAGE_FSTYPES += "jffs2 tar.gz"
+IMAGE_FSTYPES += "tar.gz jffs2 sum.jffs2"

Do you really need jffs2 if there is sum.jffs2? IMAGE_CMD_sum.jffs2 produces both now, doesn't it?

IIRC there was discussion about using += IMAGE_FSTYPES, I don't remember the result, but can we use ?= here? Just to make easier for someone to limit images in local.conf ie just
IMAGE_FSTYPES = "tar.gz"

Quoted 23 lines
conf/machine/include/zaurus.inc +2 -9
 # kernel now supports favourlzo
-IMAGE_CMD_jffs2 = "mkfs.jffs2 --root=${IMAGE_ROOTFS} --faketime -m favourlzo \
-                   --output=${T}/${IMAGE_NAME}.rootfs.jffs2 --pad --little-endian --eraseblock=${ERASEBLOCKSIZE} -n \
-                   && sumtool -i ${T}/${IMAGE_NAME}.rootfs.jffs2 \
-                   -o ${T}/${IMAGE_NAME}.rootfs.jffs2.summary \
-                   --eraseblock=${ERASEBLOCKSIZE} -l -p; \
-                   cat ${T}/${IMAGE_NAME}.rootfs.jffs2 > ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.jffs2; \
-                   rm ${T}/${IMAGE_NAME}.rootfs.jffs2; \
-                   cat ${T}/${IMAGE_NAME}.rootfs.jffs2.summary > ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.summary.jffs2; \
-                   rm ${T}/${IMAGE_NAME}.rootfs.jffs2.summary;"
+EXTRA_IMAGECMD_jffs2 = "-p -l --eraseblock=${ERASEBLOCKSIZE}"
+EXTRA_IMAGECMD_sum.jffs2 = "${EXTRA_IMAGECMD_jffs2}"
 
 EXTRA_IMAGEDEPENDS += "zaurus-installer"
 
Signature · 7 lines
1.7.3.4


_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel
Signature · 1 line
Martin 'JaMa' Jansa     jabber: [email protected]
#3 lore raw
Quoted 20 lines · Martin Jansa
Quoted 19 lines · Andrea Adami

* in oe-core jffs2 summary has been added to image_types.bbclass and
* IMAGE_CMD_jffs2 now includes '-n' to skip cleanmarkers node creation
* so we need to customize only padding, endianness and compression mode
* While there remove compression settings which are handled in kernel.
* This allows us to use the same string for mkfs.jffs2 and for sumtool.

---
 conf/machine/include/zaurus.inc |   13 +++----------

 1 files changed, 3 insertions(+), 10 deletions(-)
conf/machine/include/zaurus.inc +0 -0
index b488f37..0a9b1c5 100644
@@ -9,18 +9,11 @@ ERASEBLOCKSIZE_akita = "0x20000"
  # C3100 and C3200 have same 128MiB NAND device as akita

 ERASEBLOCKSIZE_spitz = "0x20000"

Quoted 6 lines

conf/machine/include/zaurus.inc ERASEBLOCKSIZE_akita = "0x20000" · line 12

Quoted 2 lines
conf/machine/include/zaurus.inc +1 -1
-IMAGE_FSTYPES += "jffs2 tar.gz"
+IMAGE_FSTYPES += "tar.gz jffs2 sum.jffs2"

Do you really need jffs2 if there is sum.jffs2? IMAGE_CMD_sum.jffs2 produces both now, doesn't it?

Yes, the jffs2 is rebuilt as well.
Actually I though about calling the output differently and remove it after the sumtool step but did not find special reasons to do it...in fact you almost always want the plain jffs2 too.
Not a strong opinion, though...

Quoted 5 lines

IIRC there was discussion about using += IMAGE_FSTYPES, I don't remember the result, but can we use ?= here? Just to make easier for someone to limit images in local.conf ie just
IMAGE_FSTYPES = "tar.gz"

Nothing against, this is a remnant of oe-classic.

Quoted 28 lines
Quoted 16 lines
 # kernel now supports favourlzo
conf/machine/include/zaurus.inc +2 -9
-IMAGE_CMD_jffs2 = "mkfs.jffs2 --root=${IMAGE_ROOTFS} --faketime -m favourlzo \
-                   --output=${T}/${IMAGE_NAME}.rootfs.jffs2 --pad --little-endian --eraseblock=${ERASEBLOCKSIZE} -n \
-                   && sumtool -i ${T}/${IMAGE_NAME}.rootfs.jffs2 \
-                   -o ${T}/${IMAGE_NAME}.rootfs.jffs2.summary \
-                   --eraseblock=${ERASEBLOCKSIZE} -l -p; \
-                   cat ${T}/${IMAGE_NAME}.rootfs.jffs2 > ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.jffs2; \
-                   rm ${T}/${IMAGE_NAME}.rootfs.jffs2; \
-                   cat ${T}/${IMAGE_NAME}.rootfs.jffs2.summary > ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.summary.jffs2; \
-                   rm ${T}/${IMAGE_NAME}.rootfs.jffs2.summary;"
+EXTRA_IMAGECMD_jffs2 = "-p -l --eraseblock=${ERASEBLOCKSIZE}"
+EXTRA_IMAGECMD_sum.jffs2 = "${EXTRA_IMAGECMD_jffs2}"

 EXTRA_IMAGEDEPENDS += "zaurus-installer"

Quoted 8 lines

--
1.7.3.4

_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel

--
Martin 'JaMa' Jansa     jabber: [email protected]

Quoted 5 lines

_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel

BTW we'll support soon ubi filesystems in kexecboot so long mount times will disappear.
Thanks for testing

Cheers

Andrea