[Parted-maintainers] Bug#578097: [parted-devel] Debian Bug #578097: No support for CMS-formatted disks

Stephen Powell zlinuxman at wowway.com
Sat May 8 03:50:16 BST 2010


As promised earlier today, I now have the following patch files on my
web site ready for download:

http://www.wowway.com/~zlinuxman/parted/vtoc.h.diff   (apply to include/parted/vtoc.h)
http://www.wowway.com/~zlinuxman/parted/dasd.c.diff   (apply to libparted/labels/dasd.c)
http://www.wowway.com/~zlinuxman/parted/fdasd.c.diff  (apply to libparted/labels/fdasd.c)
http://www.wowway.com/~zlinuxman/parted/vtoc.c.diff   (apply to libparted/labels/vtoc.c)

I have not made any updates to NEWS.  You can edit that as you see
fit.  These are ordinary "context diffs", with three lines of context.
I don't understand this "git" stuff.  I've never used it.  Sorry.
My starting point was the Debian source package for parted, version 2.2-5.

To my way of thinking, these patches are logically one fix, which I
would describe as "corrections to partition size and location
calculations for type 1 partitions for s390 dasd".  If you want to
treat it as two separate fixes, one to make corrections for LDL
formatted disks and one to add support for CMS formatted disks, that's
up to you.  I see CMS formatted disks as a variant of LDL formatted
disks, with the additional twist that CMS formatted disks can be
reserved or recomped, which LDL formatted disks cannot be.  This
affects the size and location of the partition.

With these patches, parted matches the behavior of the Linux kernel
in recognizing partitions on CMS- and LDL-formatted disks, as documented
in the Linux kernel source code in routine fs/partitions/ibm.c.
Calculation of the metadata has also been changed so that parted will
show no free space on such a disk.  In some cases there are now two
non-contiguous metadata extents: one at the beginning of the disk and
one at the end.

As before, parted only supports CKD DASD using the ECKD driver.
FBA DASD and CKD DASD using the DIAG driver are still not supported.
Someday I may work on that.  Maybe.  But not today.

In my regression testing I have discovered some problems in the area
of recognizing file system options.  However, since I can duplicate
these errors on a version of parted which does not contain my changes,
I have concluded that my changes did not cause this and therefore
this is an unrelated bug.

I make no claim to be a C programmer.  I'm just starting to learn C.
You C experts might want to take a look at my code.  It does seem to
work, but that doesn't necessarily mean that it's well written.  There
may be a better way to do what I did.  Feel free to change it, as long
as the end result is the same.

If you have any questions, please feel free to ask.

-- 
  .''`.     Stephen Powell    
 : :'  :
 `. `'`
   `-





More information about the Parted-maintainers mailing list