* nandwrite fix
@ 2006-07-18 11:44 Davide CASCONE
2006-07-18 12:15 ` Vitaly Wool
0 siblings, 1 reply; 2+ messages in thread
From: Davide CASCONE @ 2006-07-18 11:44 UTC (permalink / raw)
To: linux-mtd
I have tried to use the nandwrite utility with a large page nand, but it doesn't work properly. The problem is related to the jffs2_oobinfo struct. I have fixed the problem replacing the defined jffs2_oobinfo struct (for small page nand)
struct nand_oobinfo jffs2_oobinfo = {
.useecc = MTD_NANDECC_PLACE,
.eccbytes = 6,
.eccpos = { 0, 1, 2, 3, 6, 7 }
};
with the following struct (for large page nand)
struct nand_oobinfo jffs2_oobinfo = {
.useecc = MTD_NANDECC_AUTOPLACE,
.eccbytes = 24,
.eccpos = {
40, 41, 42, 43, 44, 45, 46, 47,
48, 49, 50, 51, 52, 53, 54, 55,
56, 57, 58, 59, 60, 61, 62, 63},
.oobfree = { {2, 38} }
};
Now the nandwrite utility works properly, but I think it's better to define a macro in order to select the correct jffs2_oobinfo struct depending on the device page size. What do you think about?
Best regards,
Davide
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: nandwrite fix
2006-07-18 11:44 nandwrite fix Davide CASCONE
@ 2006-07-18 12:15 ` Vitaly Wool
0 siblings, 0 replies; 2+ messages in thread
From: Vitaly Wool @ 2006-07-18 12:15 UTC (permalink / raw)
To: Davide CASCONE; +Cc: linux-mtd
Davide CASCONE wrote:
> Now the nandwrite utility works properly, but I think it's better to define a macro in order to select the correct jffs2_oobinfo struct depending on the device page size. What do you think about?
>
>
My POV is that it's better to never use anything but autoplacement and
remove jffs2_oobinfo from nandwrite completely.
Vitaly
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2006-07-18 12:15 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-07-18 11:44 nandwrite fix Davide CASCONE
2006-07-18 12:15 ` Vitaly Wool
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox