hcr 2011-02-08
1.了解 NandFlash 信息 :
FS2410开发板的Nand Flash 型号K91208 ;
PageSize = 512 Bytes + 16 Bytes(OOB);
BlockSize = 32 pages *(512 Bytes + 16 Bytes(OOB)) = 32 pages * 528 Bytes = 16K +512 Bytes(OOB) ;
DeviceSize = 4096 blocks * (32 *(512 Bytes + 16 Bytes(OOB))) = 4096 blocks * 16K +4096 *512 Bytes(OOB) = 64MBytes + 2KBytes (OOB) ;
所以 制作文件系统竟像时的 -e/--eraseblock = 0x4000 -s/--pagesize = 0x200 -p/--pad = 根文件系统分区大小,这里为20MBytes;
S3C24XX NAND Driver, (c) 2004 Simtec Electronics
s3c24xx-nand s3c2410-nand: Tacls=3, 29ns Twrph0=7 69ns, Twrph1=3 29ns
s3c24xx-nand s3c2410-nand: NAND soft ECC
NAND device: Manufacturer ID: 0xec, Chip ID: 0x76 (Samsung NAND 64MiB 3,3V 8-bit)
Scanning device for bad blocks
Bad eraseblock 3946 at 0x000003da8000
Creating 4 MTD partitions on "NAND 64MiB 3,3V 8-bit":
0x000000000000-0x000000040000 : "u-boot"
0x000000040000-0x000000400000 : "kernel-linux-2.6.35"
0x000000400000-0x000001800000 : "rootfs"
0x000001800000-0x000004000000 : "userdata"
Nand Flash 分区修改,linux-2.6.35/arch/arm/plat-s3c24xx/common-smdk.c 109 line;
setenv bootargs root=/dev/mtdblock2 rootfstype=jffs2 rw console=ttySAC0,115200 init=/linuxrc mem=64M
saveenv