平台:Redhat9.0 + S3C2440
编译环境: 2.6.18.2 + gcc-3.4.1
根据NAND FLASH的datasheet修改kernel对nand flash的访问,
在CPU主机为405M时,tacls,twrph0,twrph1的数值如下:
进入 arch/arm/mach-s3c2410/common-smdk.c
static struct s3c2410_platform_nand smdk_nand_info = { .tacls = 15, //default(for 300M) 20,
.twrph0 = 45, //default(for 300M) 60,
.twrph1 = 15, //default(for 300M) 20,
.nr_sets = ARRAY_SIZE(smdk_nand_sets), .sets = smdk_nand_sets, };
|
在128M的Nand Flash上建立分区表,
进入 arch/arm/mach-s3c2410/common-smdk.c
修改
static struct mtd_partition smdk_default_nand_part[] = {
// U-boot 256K
[0] = { .name = "uboot", .offset = 0, .size = SZ_256K, }, // Kernel 2M - 256K
[1] = { .name = "kernel", .offset = SZ_256K, .size = (SZ_2M - SZ_256K), }, // rootfs 16M
[2] = { .name = "rootfs", .offset = SZ_2M, .size = (16 * SZ_1M), }, // app 16M
[3] = { .name = "app", .offset = 18 * SZ_1M, .size = 16 * SZ_1M, }, // other (127 - 34)M
[4] = { .name = "other", .offset = 34 * SZ_1M, .size = (127 - 34) * SZ_1M, }, };
|
阅读(2832) | 评论(0) | 转发(0) |