home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / unix / bsd / 3101 < prev    next >
Encoding:
Internet Message Format  |  1992-07-29  |  3.6 KB

  1. Path: sparky!uunet!dtix!darwin.sura.net!Sirius.dfn.de!math.fu-berlin.de!unidui!du9ds3!veit
  2. From: veit@du9ds3.uni-duisburg.de (Holger Veit)
  3. Newsgroups: comp.unix.bsd
  4. Subject: Re: 386BSD 0.1, disklabel problem isolated !
  5. Message-ID: <veit.712417271@du9ds3>
  6. Date: 29 Jul 92 13:41:11 GMT
  7. References: <1992Jul26.080147.4506@data.fls.dk>
  8. Sender: @unidui.uni-duisburg.de
  9. Reply-To: veit@du9ds3.uni-duisburg.de
  10. Organization: Uni-Duisburg FB9 Datenverarbeitung
  11. Lines: 71
  12.  
  13. In <1992Jul26.080147.4506@data.fls.dk> phk@data.fls.dk (Poul-Henning Kamp) writes:
  14.  
  15. >I have a Western Digital WDC 4200 "Piranha" disk, it's an IDE of 202 Mb.
  16. >The real physical layout is 1263 cyl, 8 heads, 41 sectors.  But to keep
  17. >MS/DOS happy the drive reports 967 cyl, 12 heads 35 sect.  If I set the
  18. >BIOS to the real values 1263,8,41 and create a 15 Mb DOS partition,
  19. >install 386BSD 0.1 from the dist.fs things are OK until I try to boot the
  20. >386BSD from the disk.
  21.  
  22. >It seems from the debug that the disklabel IS found, but then the drive 
  23. >is probed and the cylinder count is clipped to 967, though the heads and the
  24. >sect counts is left untouched.
  25.  
  26. >Since a lot of this translation stuff is going on, I think it is important
  27. >to get this handled right:
  28.  
  29. >    1) Use BIOS-values and boot-block to find disklabel.
  30.  
  31. >    2) Use values in disklabel, unless the drive tells us otherwise:
  32.  
  33. >    if(drive.sect == label.sect && drive.head == label.head)
  34. >        label.cyl = drive.cyl;
  35.  
  36. >In my experience this will solve the most widespread problems with
  37. >ESDI/IDE drives:
  38.  
  39. >    1) drives simply not matched by the BIOS, in this case the disklabel
  40. >       can containe the right values, supported by the drives own idea.
  41.  
  42. >    2) drives crippled by manufactures to match a "VENDOR_X"-67 Mb drive,
  43. >       even though the drive is 84 Mb, the right cylinder count can be picked
  44. >       up from the drive.
  45.  
  46. >    3) cases like mine where even the bloddy drive is exposed to the famous
  47. >       MS-DOS brain-damage...
  48.  
  49. >As soon as I can I'll produce a patch for this.
  50.  
  51. >Don't forget to enjoy other aspects of life, even though you have got your
  52. >own unix box at home now !  :-)
  53. >-- 
  54. >phk@data.fls.dk          || If you can't join 'em -- beat 'em !
  55. >Poul-Henning Kamp      ||            the Danish foreign minister
  56. >FLS DATA A/S          ||
  57. >Phone: (+45) 36 18 12 35  ||
  58.  
  59. I would consider it dangerous to take the "real physical layout" as a 
  60. reference (here "1263 cyl, 8 heads, 41 sectors"), in particular the number of
  61. sectors. Unlike MFM and RLL drives it is a common practice of the 
  62. "intelligent" (?) IDE controller on the disk board to have different numbers
  63. of sectors depending on the length/diameter of the track. Provided a constant
  64. write density you can place more sectors on an outer track than on an
  65. inner track. There are IDE drives which accept whatever configuration they are
  66. told and do translation of these values to their native internal format. 
  67. Seems to be that you have such a drive. 
  68. BTW, how can you enter 1263 cylinders in the free BIOS entry? Your BIOS may 
  69. accept this value (although it should be clipped to 1023), but do you know
  70. what DOS makes of this. The parameter list of the generic INT13 calls clip
  71. the cylinder number to 10 bits (unless you have an AWARD AT BIOS which uses
  72. more bits, according to Ralf Brown's INTERRUPT.LST). 
  73.  
  74. But I wish you good luck with you patch, although I suspect that it will be
  75. yet another not portable island solution.
  76.  
  77. Holger
  78.  
  79. -- 
  80. |  |   / Holger Veit             | INTERNET: veit@du9ds3.uni-duisburg.de
  81. |__|  /  University of Duisburg  | BITNET: veit%du9ds3.uni-duisburg.de@UNIDO
  82. |  | /   Dept. of Electr. Eng.   | "No, my programs are not BUGGY, these are
  83. |  |/    Inst. f. Dataprocessing |          just unexpected FEATURES"
  84.