128 MiB NAND flash in Qemu (OM-2007.2)

Robert Schuster r.schuster at tarent.de
Wed Aug 8 00:36:26 CEST 2007


Hi,
I want to add some packages to the root JFFS2 image of OM-2007.2 and try
them in the emulator. With my packages addes the image has a size of
around 51 MiB. This is too large for the default flash memory.

I decided to modify qemu and let it use a 128 MiB model (change 0x76 to
0x79 as third argument to nand_init() in neo1973.c). After that a small
change was neccessary to the qemu/openmoko/Makefile to let it create a
bigger image. Instead of

# Neo NAND is 128k sectors big
cat .16ksec .16ksec .16ksec .16ksec .16ksec .16ksec .16ksec .16ksec > $@

Do:
# Neo NAND is 128k sectors big
cat .16ksec .16ksec .16ksec .16ksec .16ksec .16ksec .16ksec .16ksec >
.128ksec
cat .128ksec .128ksec > $@

When flashing the big image everything look fine first. But when the
rootfs is going to be flashed qemu detects that something is wrong and
jumps (= no crash) out like this:

qemu: fatal: Bad mode 0

R00=00000000 R01=00000000 R02=00000000 R03=00000000
R04=00000000 R05=00000000 R06=00000000 R07=00000000
R08=00000000 R09=00000000 R10=00000000 R11=00000000
R12=00000000 R13=00000000 R14=00000000 R15=33f80040
PSR=000001d3 ---- A svc32
s00=00000000(       0) s01=00000000(       0) d00=0000000000000000(       0)
s02=00000000(       0) s03=00000000(       0) d01=0000000000000000(       0)
s04=00000000(       0) s05=00000000(       0) d02=0000000000000000(       0)
s06=00000000(       0) s07=00000000(       0) d03=0000000000000000(       0)
s08=00000000(       0) s09=00000000(       0) d04=0000000000000000(       0)
s10=00000000(       0) s11=00000000(       0) d05=0000000000000000(       0)
s12=00000000(       0) s13=00000000(       0) d06=0000000000000000(       0)
s14=00000000(       0) s15=00000000(       0) d07=0000000000000000(       0)
s16=00000000(       0) s17=00000000(       0) d08=0000000000000000(       0)
s18=00000000(       0) s19=00000000(       0) d09=0000000000000000(       0)
s20=00000000(       0) s21=00000000(       0) d10=0000000000000000(       0)
s22=00000000(       0) s23=00000000(       0) d11=0000000000000000(       0)
s24=00000000(       0) s25=00000000(       0) d12=0000000000000000(       0)
s26=00000000(       0) s27=00000000(       0) d13=0000000000000000(       0)
s28=00000000(       0) s29=00000000(       0) d14=0000000000000000(       0)
s30=00000000(       0) s31=00000000(       0) d15=0000000000000000(       0)
FPSCR: 00000000

The interesting thing is that I get the same error when configuring the
emulated neo with a 64MiB flash and try to flash a too large rootfs.

Do I need to modify something else? Is something wrong with the changes
I made? Or is uboot's nand write command simply broken?

Regards
Robert

-- 
tarent Gesellschaft für Softwareentwicklung und IT-Beratung mbH

Heilsbachstr. 24, 53123 Bonn    | Poststr. 4-5, 10178 Berlin
fon: +49(228) / 52675-0         | fon: +49(30) / 27594853
fax: +49(228) / 52675-25        | fax: +49(30) / 78709617
durchwahl: +49(228) / 52675-17  | mobil: +49(171) / 7673249

Geschäftsführer:
Boris Esser, Elmar Geese, Thomas Müller-Ackermann
HRB AG Bonn 5168
Ust-ID: DE122264941

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 252 bytes
Desc: OpenPGP digital signature
Url : http://lists.openmoko.org/pipermail/openmoko-devel/attachments/20070808/7232f394/signature-0001.pgp


More information about the openmoko-devel mailing list