Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!sdd.hp.com!spool.mu.edu!snorkelwacker.mit.edu!bloom-beacon!eru!hagbard!sunic!isgate!krafla!adamd From: adamd@rhi.hi.is (Adam David) Newsgroups: comp.os.minix Subject: Larger / non-std fd formats (ST). Message-ID: <3143@krafla.rhi.hi.is> Date: 14 May 91 15:57:15 GMT Article-I.D.: krafla.3143 References: <3115@krafla.rhi.hi.is> Organization: University of Iceland Lines: 34 In a previous article with subject 'Cannot open /dev/rfd? (ST 1.5:3)' I wrote: >So, why is it that /dev/rfd? fails during open()? (I didn't break it). >Has anybody already tackled the issue of formatting different floppy disk >parameters under minix? There are several issues involved, most notably >which interleave and skew factors to use and reducing the inter-sector gap >to add another 10% to disk capacity. The error was found in stfloppy.c and was causing open() to fail for all /dev/*fd? devices (except /dev/fmtfd? which was disabled). Actually it would handle SS disks correctly but barfed on DS disks. simple fix: multiply nr_sectors by nr_heads in the sanity checks at the end. I have heavily modified format.c and it now succesfully formats DD disks to 924k and HD disks to 1848k using 512-byte sectors. Changes to support ED disks up to 3696k are trivial. An ED format of 3864k is possible using 1024-byte sectors but will require further modification to the system, because the 512-byte sector size seems to be fairly extensively used as a constant. stfloppy.c could handle the deblocking internally, and no other part of the system would have to know about it - but there might be better ways since the minix system works mainly with 1024-byte disk blocks. The formatter supports complete flexibility in specifying interleave and skew factors, also various sector and track combinations. Slight squeezing of sector gaps is used for the 21-sector HD format, and tight squeezing is used for the 11-sector DD and 22-sector HD format. When they are implemented the ED formats above 42-sector will also need to use squeezing. If there is reasonable interest I shall post the stfloppy.c patches and the modified version of format.c, otherwise I will make them available by email. -- Adam David. (adamd@rhi.hi.is)