[oe] ARM bootloaders (Zaurus) and CMDLINE
Stanislav Brabec
utx at penguin.cz
Sat Jan 17 22:33:09 UTC 2009
Fri, 16 Jan 2009 20:08:03 +0300 Yuri Bushmelev wrote:
> > Kernel 2.4 used a trick - user space utility called writerominfo
> > read some of these values and sent them to kernel.
>
> Stanislav, can you please explain this a bit more?
>
If you look at Sharp system, you will find /sbin/writerominfo. I didn't
find source code for it, but I guess that it reads NAND config data and
initializes /proc/deviceinfo entries (and it performs some magic
with /.sys).
This utility is called early in the boot process. updater.sh
flashing utility uses it as well.
Other utilities used by update.sh:
nandlogical: source available
verchg: probably changes NAND section version info in NAND
nandcp: probably copies data to NAND
bcut: probably trivial file cutter
eraseall: probably MTD partition eraser
Note: current OE update.sh does not flash correct checksum after
flashing the kernel
Here is a rough and incomplete attempt to map PROM and NAND based on a
SL-6000 map somewhere on OESF (attached as PNG), my experimenting
with SL-C3200 and trying to understand, what one can see in the NAND
diagnostic.
One importand note: Linux kernel does not yet support all settings done
by the bootloader. For example LCD phase settings is done by bootloader
and not touched by Linux. Possible alternative bootloader may need to
set it as well.
PROM and NAND memory map on Sharp Zaurus SL-C3200
(it is known to be different from all other models including SL-C3100)
PROM
8 MiB PROM Read only memory for production models, NOR flash for
pre-production models.
PROM BOOTLOADER "ROM"
address 0x00000000, size 0x00140000
contents: Bootloader.
PROM MTD0 "Filesystem" "ROM DATA"
address 0x00140000, size 0x006b0000
contents: EN-JP dictionary database.
NAND
128MiB NAND flash, erase size 0x00020000
NAND MTD1 "smf" "BOOT"
address 0x00000000, size 0x00700000
address 0x00000000, size 0x00040000 MAINTE
0x48000 0x4000 VERBLOCK
0x70000 0x4000 MVRBLOCK
address 0x00040000, size 0x00040000 NAND bootloader
Values from SL-6000:
0x00040000 AdjValue
0020020 ffff ffff ffff ffff ffff ffff 5554 4843
0020040 80ec 3d87 70dc 3dbc ffee ffff fff0 ffff
0020060 ffff ffff ffff ffff 4850 4441 0000 0000
0x00044000 BootFlag ff
0x00048000 Version *
names of MTD sections
positions of sections
checksums
0x0004c000 Clock 0000000 0425 1971 82b1 4660
0x00050000 ROMount ff
0x00054000 RWMount ff
0x00058000 RSV_58
0x0005c000 RSV_5C
0x00060000 PartitionInfo1 *
0x00064000 PartitionInfo2 *
0x00068000 Model *
0x0006c000 RSV_6C
0x00070000 MVersion *
master version
checksums of mtd sections
0x00074000 RSV_74
0x00078000 RSV_78
* verified
0x000e0000 DATA standard kernel
Values from param_version:
0x00000000 Mainte "MAINTE" "MAINTE.BIN"
1. 00000000-00040000
0x00040000 Parameter Area
0x0007c000 NAND Diag "DIAG" "NANDDIAG.BIN"
2. 00080000-000e0000
0x000e0000 Zimage 2 "KERNEL2" "ZIMAGE.BIN+INITRD.BIN"
3. 00220000-0035c000
4. 00360000-00680000
0x00220000 Zimage 1 "KERNEL1" "ZIMAGE.BIN+INITRD.GZ"
5. 000e0000-0021c000
6. 07000000-03100000 (i. e. FSRO)
0x00360000 Initrd 2 "FLSYS2" "INITFS.BIN"
7. 03200000-08000000 (i. e. FSRW)
0x00700000 "ROFLSYS?" "PARAMINF.BI"
8. 00060000-0006c000
NAND MTD2 RO JFFS2 file system "root" "FSRO"
address 0x00700000, size 0x02b00000
NAND MTD3 RW JFFS2 file system "home" "FSRW"
address 0x03200000, size 0x04e00000
--
Stanislav Brabec
http://www.penguin.cz/~utx/zaurus
More information about the Openembedded-devel
mailing list