Skip to contentSkip to conversation

mtd_info/mtd_info_user>size wrong type

DISCUSSION Charles Manning 2 participants 3 messages Apr 6, 2007 – Apr 7, 2007 Memory technology devices (MTD)

lore
Share & tools
lore
#0 lore raw

Folks
As people are starting to use larger NAND partitions (4GB+), an inconsistency in the size field has become apparent.

This is a unint32_t which is clearly too small for modern NAND arrays.

The read/write funcions use loff_t which is correct.

It would seem that size needs to be increated to loff_t too.

-- Charles

#1 lore raw
Quoted 5 lines · Charles Manning

Folks
As people are starting to use larger NAND partitions (4GB+), an inconsistency in the size field has become apparent.

This is a unint32_t which is clearly too small for modern NAND arrays.

Yes, known issue.

Quoted 3 lines

The read/write funcions use loff_t which is correct.

It would seem that size needs to be increated to loff_t too.

Have you tried doing that? I seem to recall hearing that it was a bit more involved than just changing the size member to be 64 bit.

josh

#2 lore raw
Quoted 7 lines · Josh Boyer
Quoted 5 lines · Charles Manning

Folks
As people are starting to use larger NAND partitions (4GB+), an inconsistency in the size field has become apparent.

This is a unint32_t which is clearly too small for modern NAND arrays.

Quoted 8 lines

Yes, known issue.

Quoted 3 lines

The read/write funcions use loff_t which is correct.

It would seem that size needs to be increated to loff_t too.

Have you tried doing that? I seem to recall hearing that it was a bit more involved than just changing the size member to be 64 bit.

I have not tried this though someone is aty present. I do know that someone has used YAFFS with Linux on a 6G or so partition.However they wanted a really fast nand driver and wrote a custom nand driver.

There definitely are some downstream problems too. It is not just a matter of changing the type.

eg using do_div() instead of divides and making sure that the right values flow through the whole mtd subsystem fron nand_base..c right through mtdpart, mtdcat, the tools etc.

-- Charles