cmdlinepart.c patch

Chuck Meade chuckmeade at
Mon Mar 6 10:46:30 EST 2006

The cmdlinepart.c logic treats a partition offset that has been explicitly
specified as zero the same as an unspecified offset.  This causes the
partitioning logic to fail if your partition that starts at 0x0 is not the
first partition listed on the cmdline.

For example, if you have several partitions, and you want the third partition
to be an all-encompassing partition covering the whole device, then you
would give it offset 0x0.  The cmdlinepart.c logic treats this the same as
if you had not specified an offset, and instead tries to start the third
partition after the end of your second partition.  This is because the logic
uses zero as the "unspecified offset" value.  However, zero is not a good
choice for "unspecified offset" -- it is quite valid as a "specified" offset.

The attached patch defines the "unspecified offset" value as 0xffffffff and
makes the changes needed to support partitions that explicitly start at
offset 0x0, but are not necessarily listed first on the cmdline.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: cmdlinepart.c.patch
Type: application/octet-stream
Size: 965 bytes
Desc: not available
Url : 

More information about the linux-mtd mailing list