Altera_Forum
Honored Contributor
20 years agoMTD do_write_oneword fails
Hi
I'm having some trouble with writing to a flash partition on our board running Microtronix 1.4 uclinux 2.6 We have 5 partitions on our flash:static struct mtd_partition microtronix_partitions = {
{
.name = "romfs/jffs2",
.size = 0x160000,
.offset = 0x190000,
},{
.name = "loader/kernel",
.size = 0x190000,
.offset = 0,
}, {
.name = "HMConfig",
.size = 0x010000,
.offset = 0x1F0000,
}, {
.name = "User configuration",
.size = 0x080000,
.offset = 0x300000,
}, {
.name = "safe configuration",
.size = 0x080000,
.offset = 0x380000,
}
}; for the sake of testing , we have made an ext2 fs image, which is downloaded to the "User configuration" partition, and mounted this on a /mnt/rwfs dev. We are now able to see the files on the mounted partion (those that were already on the image), but we are not able to write anything to the partition. Whenever we copy a file to the partition, it fails with a "MTD do_write_oneword(): software timeout" when the cache is flushed. The error seems to be on random sectors and not all sectors. The Flash is OK, because we are able to load the entire partiton with the ext2 fs image, through the Flash-Programmer. We have even tried to make a image with 0x55 pattern to make sure that the entire partition is written physically and this is working when using the Flash-Programmer. Does anyone have an idea, as to why we are have this problem?