[U-Boot] [PATCH v4 2/4] mtdparts: show net size in mtdparts list

Ben Gardiner bengardiner at nanometrics.ca
Fri Aug 27 18:45:01 CEST 2010


On Fri, Aug 27, 2010 at 12:02 PM, Scott Wood <scottwood at freescale.com> wrote:
> On 08/27/2010 10:44 AM, Ben Gardiner wrote:
>>
>> On Thu, Aug 26, 2010 at 2:57 PM, Scott Wood<scottwood at freescale.com>
>>  wrote:
>>>
>>> Don't assume partition size fits in 32 bits.  part->size is uint64_t.
>>
>> I understand that (at some point) we need to support part->size
>> uint64_t but the HEAD of u-boot [1],  u-boot-nand-flash/master [2] and
>> u-boot-nand-flash/next [3] have u32 for part->size.
>
> I see, I was looking at mtd_partition, not part_info.  Why are we using
> jffs2's partition struct for anything other than jffs2?  Why does jffs2 have
> its own partition struct at all?

I don't know why. I can only offer the following information:

Cscope says that include/jffs2/load_kernel.h is the file in which
part_info is defined.

'git blame' indicates that part_info has been used in
common/cmd_mtdparts.c since 68d7d65100e84df00bca971c114092731b441090
when Stefan Roese <sr at denx.de> extracted the command from
common/cmd_jffs2.c

The users of mtd_partition (add_one_partition and add_mtd_partitions)
are called from ubi_dev_scan where the mtd_partition structure is
intialized from a part_info structure.

Best Regards,
Ben Gardiner

---
Nanometrics Inc.
+1 (613) 592-6776 x239
http://www.nanometrics.ca


More information about the U-Boot mailing list