Help - Search - Members - Calendar
Full Version: C3200 Boot Process
OESF Forums > Distros, Development, and Model Specific Forums > Model Specific Forums > C1000/3x00 General discussions
Skaarj
Hi. I'm very interesting how zaurus boots up.
What does happen when power is applied?
There is no information about internal flash in PXA270 datasheet. So where is maintenance menu (and rescue mode) code located? What does handle special key pressing?
Unfortunately, I haven't found any really useful information.
utx
QUOTE(Skaarj @ Sep 11 2011, 01:24 PM) *
Hi. I'm very interesting how zaurus boots up.
What does happen when power is applied?
There is no information about internal flash in PXA270 datasheet. So where is maintenance menu (and rescue mode) code located? What does handle special key pressing?
Unfortunately, I haven't found any really useful information.


It jumps somewhere to the PROM and runs bootloader (or ROM menu). In the standard mode, it loads NAND bootloader (or NAND menu). NAND bootloader processes records in the dedicated NAND area, sets the hardware, creates kernel arguments and runs one of the kernels in the dedicated areas. Then it continues with a standard Linux boot depending on the image in the flash.

At least one code is processed by the PROM code (ROM diag), most of the rest by rthe NAND code.
Skaarj
QUOTE(utx @ Sep 11 2011, 06:43 PM) *
It jumps somewhere to the PROM and runs bootloader (or ROM menu). In the standard mode, it loads NAND bootloader (or NAND menu). NAND bootloader processes records in the dedicated NAND area, sets the hardware, creates kernel arguments and runs one of the kernels in the dedicated areas. Then it continues with a standard Linux boot depending on the image in the flash.

Thank you. Is it possible to obtain detailed information about this process somewhere?
utx
QUOTE(Skaarj @ Sep 12 2011, 01:50 PM) *
Thank you. Is it possible to obtain detailed information about this process somewhere?


There is a list of known keys somewhere in this forum as well as partially decoded NAND map, but both loaders are (probably) undocumented proprietary applications. It seems that both loaders are very similar (if not the same).
Skaarj
I've tried to make a little investigation
CODE
# cat /proc/mtd
dev:    size   erasesize  name
mtd0: 006b0000 00020000 "Boot PROM Filesystem"
mtd1: 00700000 00020000 "Logical"
mtd2: 07900000 00020000 "JFFS2"

mtd2 contains jffs2 filesystem. After mounting /dev/mtdblock2 I've got opt/native/arm/3.4.6-xscale-sftvfp directory with system files (bin, include etc)
After dumping mtd1 and analyzing strings, I've found that it's UBoot.
One interesting string:
QUOTE
bootargs=console=ttyS0,115200 console=tty1 root=/dev/ram rw fbcon=rotate:1 ramdisk_size=8192
bootcmd=if testkey 101 ; then nand read.logical 0xa1000000 0x00060000 0x00540000; setenv bootargs console=ttyS0,115200 console=tty1 root=/dev/ram rw fbcon=rotate:1 ramdisk_size=8192; bootm; fi; if testkey 2 ; then nand read.logical 0xa1000000 0x005a0000 0x00160000; setenv bootargs console=ttyS0,115200 console=tty1 root=/dev/mmcblk0p1 fbcon=rotate:1; bootm; fi; if testkey 18 ; then nand read.logical 0xa1000000 0x005a0000 0x00160000; setenv bootargs console=ttyS0,115200 console=tty1 root=/dev/hda1 fbcon=rotate:1; bootm; fi; if testkey 3 ; then nand read.logical 0xa1000000 0x005a0000 0x00160000; setenv bootargs console=ttyS0,115200 console=tty1 root=/dev/hdc1 fbcon=rotate:1; bootm; fi; nand read.logical 0xa1000000 0x005a0000 0x00160000; setenv bootargs console=ttyS0,115200 console=tty1 root=/dev/mtdblock2 rootfstype=jffs2 fbcon=rotate:1; bootm;


dmesg says that mtd0 is sharpsl flash and mtd1 and mtd2 are sharpsl nand

What is sharpsl flash?
utx
QUOTE(Skaarj @ Sep 13 2011, 03:50 PM) *
I've tried to make a little investigation
CODE
# cat /proc/mtd
dev:    size   erasesize  name
mtd0: 006b0000 00020000 "Boot PROM Filesystem"
mtd1: 00700000 00020000 "Logical"
mtd2: 07900000 00020000 "JFFS2"

mtd2 contains jffs2 filesystem. After mounting /dev/mtdblock2 I've got opt/native/arm/3.4.6-xscale-sftvfp directory with system files (bin, include etc)
After dumping mtd1 and analyzing strings, I've found that it's UBoot.
One interesting string:
QUOTE
bootargs=console=ttyS0,115200 console=tty1 root=/dev/ram rw fbcon=rotate:1 ramdisk_size=8192
bootcmd=if testkey 101 ; then nand read.logical 0xa1000000 0x00060000 0x00540000; setenv bootargs console=ttyS0,115200 console=tty1 root=/dev/ram rw fbcon=rotate:1 ramdisk_size=8192; bootm; fi; if testkey 2 ; then nand read.logical 0xa1000000 0x005a0000 0x00160000; setenv bootargs console=ttyS0,115200 console=tty1 root=/dev/mmcblk0p1 fbcon=rotate:1; bootm; fi; if testkey 18 ; then nand read.logical 0xa1000000 0x005a0000 0x00160000; setenv bootargs console=ttyS0,115200 console=tty1 root=/dev/hda1 fbcon=rotate:1; bootm; fi; if testkey 3 ; then nand read.logical 0xa1000000 0x005a0000 0x00160000; setenv bootargs console=ttyS0,115200 console=tty1 root=/dev/hdc1 fbcon=rotate:1; bootm; fi; nand read.logical 0xa1000000 0x005a0000 0x00160000; setenv bootargs console=ttyS0,115200 console=tty1 root=/dev/mtdblock2 rootfstype=jffs2 fbcon=rotate:1; bootm;


dmesg says that mtd0 is sharpsl flash and mtd1 and mtd2 are sharpsl nand

What is sharpsl flash?


There are two partitions on PROM:
Boot PROM code: invisible partition, you can find a patch to make it visible on my Zaurus web pages.
English-Japanese dictionary database: here it is called "Boot PROM Filesystem"

And three partitions on NAND:
Initial partition that does not contain filesystem and contains configuration, NAND bootloader and two kernel images
Two JFFS2 file systems with root and home for Sharp ROM. (Note that partitioning in kernel 2.6 is incorrect for SL-C3200.)

See this post for details.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2014 Invision Power Services, Inc.