|
From: KRISHNAN SUDHAKAR-N. <sud...@mo...> - 2008-02-26 10:54:20
|
hi,
I am facing few flash file accessing problems ST Linux based systems.
I have modified the code in stboards.c file for creating partitions
static struct mtd_partition onboard_partitions[3] = {
{
.name = "VIP800 Boot",
.size = 0x00500000,
.offset = 0x00000000,
.mask_flags = 0 /* mask_flags: MTD_WRITEABLE *//* force read-only */
},
{
.name = "FFS0",
.size = 0x00100000,
.offset = 0x00500000,
.mask_flags = 0
},
{
.name = "FFS1",
.size = MTDPART_SIZ_FULL, /* will expand to the end of the flash */
.offset = 0x00600000,
.mask_flags = 0
}
Partition looks like the following
/tmp # cat /proc/mtd
dev: size erasesize name
mtd0: 00500000 00020000 "VIP800 Boot"
mtd1: 00100000 00020000 "FFS0"
mtd2: 01a00000 00020000 "FFS1"
if I do a flash info its working fine
/ # flash_info /dev/mtd2
Device /dev/mtd2 has 0 erase regions
if i try to unlock the partion its not happeniing
/ # flash_unlock /dev/mtd2
Could not unlock MTD device: /dev/mtd2
/ #
It will be very helpful if some one give some solutions
Thanks and Regards,
Sudhakar,
CHS-FCS,
Ex:1385
|