[comp.os.minix] disk geometry. Geometry Sector.

aubrey@rpp386.cactus.org (Aubrey McIntosh) (01/16/90)

In article <LLOYD.90Jan15094225@kaukau.comp.vuw.ac.nz> lloyd@comp.vuw.ac.nz (Lloyd Parkes) writes:
>In article <7866@nigel.udel.EDU> Peter_Van_Epp@cc.sfu.ca writes:
>
>The problem of finding out the geometry of a disk with no file system
>on it is very hard (if you don't want to thrash the drive). One
>solution, might be start the sector numbering (on track 0 anyway) from
>some number other than zero. Different start numbers would indicate
>different disk geometries, and you would avoid those deadly seek to
>track 79 :-) This of course raises other problems.

It is trivial (a mathematical term meaning either totally obvious to
everybody, or incomprehensible to the author as well) to change the
interleave.  It it more interesting to detect the change.  However,
a very similar idea might work.

The sector number and size are given to the NEC controller on a sector by
sector basis during format time.  It is possible to make a sector number,
say 0, that is a small sector and not a usual one.  Such a sector could
be explicitly read by the boot software, and would otherwise be unobtrousive.

The geometry sector would not be copied or written by  dd, tar, mkfs, ...
under the existing code.

In those cases where another sector will not fit due to some circumstance
of controller/drive/media brand, one of the standard sectors could be
replaced with the sentinal sector, and the bit map told that it is bad.

This resultant disk could be used interchangeably with other operating
systems, since the NEC reads until either a sector id match occurs, or
a double index hole detect occurs.  Funny and/or out of sequence numbers
are (typically--exclusive of sophisticate track buffer code) no problem.

One of the features on the list-to-implement in my format program is a
"read existing data and keep it" feature.  It would be straightforward
to extend that to "add a disk geometry sector" as well.

-- 
Aubrey McIntosh        
comp.os.minix, comp.lang.modula2, soc.culture.celtic         
Austin, TX 78723 
1-(512)-452-1540  (v)