1*61599Sbostic.\" Copyright (c) 1991, 1993, 19801988 2*61599Sbostic.\" The Regents of the University of California. All rights reserved. 320665Smckusick.\" 447674Scael.\" %sccs.include.redist.man% 520665Smckusick.\" 6*61599Sbostic.\" @(#)hp.4 8.1 (Berkeley) 06/05/93 747674Scael.\" 847674Scael.Dd 947674Scael.Dt HP 4 vax 1047674Scael.Os BSD 4 1147674Scael.Sh NAME 1247674Scael.Nm hp 1347674Scael.Nd 1447674Scael.Tn MASSBUS 1547674Scaeldisk interface 1647674Scael.Sh SYNOPSIS 1747674Scael.Cd "disk hp0 at mba0 drive 0" 1847674Scael.Sh DESCRIPTION 1947674ScaelThe 2047674Scael.Nm hp 2147674Scaeldriver 2247674Scaelis a generic Massbus disk driver which handles both the standard 2347674Scael.Tn DEC 2447674Scaelcontrollers and the Emulex 2547674Scael.Tn SC750 2647674Scaeland 2747674Scael.Tn SC780 2847674Scaelcontrollers. 2947674ScaelIt is typical of a block-device disk driver; block 3047674Scael.Tn I/O 3147674Scaelis 3247674Scaeldescribed in 3347674Scael.Xr physio 4 . 3447674Scael.Pp 3547674ScaelThe script 3647674Scael.Xr MAKEDEV 8 3747674Scaelshould be used to create the special files; if a special file 3847674Scaelneeds to be created by hand consult 3947674Scael.Xr mknod 8 . 4047674ScaelIt is recommended as a security precaution to not create special files 4147674Scaelfor devices which may never be installed. 4247674Scael.Pp 4334730SkarelsThe first sector of each disk contains both a first-stage bootstrap program 4434730Skarelsand a disk label containing geometry information and partition layouts (see 4547674Scael.Xr disklabel 5 . 4634730SkarelsThis sector is normally write-protected, and disk-to-disk copies should 4734730Skarelsavoid copying this sector. 4834730SkarelsThe label may be updated with 4947674Scael.Xr disklabel 8 , 5034730Skarelswhich can also be used to write-enable and write-disable the sector. 5134730SkarelsThe next 15 sectors contain a second-stage bootstrap program. 5247674Scael.Sh DISK SUPPORT 5347674ScaelThis driver handles both standard 5447674Scael.Tn DEC 5547674Scaelcontrollers and Emulex 5647674Scael.Tn SC750 5747674Scaeland 5847674Scael.Tn SC780 5947674Scaelcontrollers. 6034730SkarelsDuring autoconfiguration or whenever a drive comes on line for the first time, 6147674Scaelor when a drive is opened after all partitions are closed, 6234730Skarelsthe first sector of the drive is examined for a disk label. 6334730SkarelsIf a label is found, the geometry of the drive and the partition tables 6434730Skarelsare taken from it. 6534730SkarelsIf no label is found, 6647674Scaelstandard 6747674Scael.Tn DEC 6847674Scaeldrive types are 6947674Scaelrecognized according to the 7047674Scael.Tn MASSBUS 7147674Scaeldrive type register, 7234730Skarelsand default partitions are used. 7334730SkarelsFor the Emulex controller the drive type register should be configured 7447674Scaelto indicate the drive is an 7547674Scael.Tn RM02 . 7647674ScaelWhen this is encountered, 7720666Smckusickthe driver checks the holding register to find out 7820666Smckusickthe disk geometry and, based on this information, decides what 7947674Scaelthe drive type is. 8047674Scael.Pp 8147674ScaelSpecial file names begin with 8247674Scael.Sq Li hp 8347674Scaeland 8447674Scael.Sq Li rhp 8547674Scaelfor the block and character files respectively. The second 8647674Scaelcomponent of the name, a drive unit number in the range of zero to 8747674Scaelseven, is represented by a 8847674Scael.Sq Li ? 8947674Scaelin the disk layouts below. 9047674ScaelThe last component is the file system partition 9147674Scaeldesignated 9247674Scaelby a letter from 9347674Scael.Sq Li a 9447674Scaelto 9547674Scael.Sq Li h 9647674Scaeland also corresponds to a minor device number set: zero to seven, 9747674Scaeleight to 15, 16 to 23 and so forth for drive zero, drive two and drive 9847674Scaelthree respectively. 9947674ScaelThe following disks are supported: 10047674Scael.Tn RM03 , 10147674Scael.Tn RM05 , 10247674Scael.Tn RP06 , 10347674Scael.Tn RM80 , 10447674Scael.Tn RP05 , 10547674Scael.Tn RP07 , 10647674Scael.Tn ML11A , 10747674Scael.Tn ML11B , 10847674Scael.Tn CDC 9775 , 10947674Scael.Tn CDC 9730 , 11047674Scael.Tn AMPEX 11147674ScaelCapricorn (32 sectors/track), 11247674Scael.Tn FUJITSU 11347674ScaelEagle (48 sectors/track), 11447674Scael.Tn FUJITSU 2361, 11547674Scaeland 11647674Scael.Tn AMPEX 11747674Scael9300. The default layout and size (in sectors) of the 11847674Scaelpartitions for these drives: 11947674Scael.Bl -column header diskx undefined length 12047674Scael.Tn RM03 No partitions 12147674Scael.Sy disk start length cyls 12220665Smckusick hp?a 0 15884 0-99 12320665Smckusick hp?b 16000 33440 100-309 12420665Smckusick hp?c 0 131680 0-822 12520666Smckusick hp?d 49600 15884 309-408 12620666Smckusick hp?e 65440 55936 409-758 12720666Smckusick hp?f 121440 10080 759-822 12820666Smckusick hp?g 49600 82080 309-822 12947674Scael 13047674Scael.Tn RM05 No partitions 13147674Scael.Sy disk start length cyls 13220665Smckusick hp?a 0 15884 0-26 13320665Smckusick hp?b 16416 33440 27-81 13420665Smckusick hp?c 0 500384 0-822 13520665Smckusick hp?d 341696 15884 562-588 13620665Smckusick hp?e 358112 55936 589-680 13720666Smckusick hp?f 414048 86176 681-822 13820666Smckusick hp?g 341696 158528 562-822 13920665Smckusick hp?h 49856 291346 82-561 14047674Scael 14147674Scael.Tn RP06 No partitions 14247674Scael.Sy disk start length cyls 14320666Smckusick hp?a 0 15884 0-37 14420666Smckusick hp?b 15884 33440 38-117 14520666Smckusick hp?c 0 340670 0-814 14620666Smckusick hp?d 49324 15884 118-155 14720666Smckusick hp?e 65208 55936 156-289 14820666Smckusick hp?f 121220 219296 290-814 14920666Smckusick hp?g 49324 291192 118-814 15047674Scael 15147674Scael.Tn RM80 No partitions 15247674Scael.Sy disk start length cyls 15320665Smckusick hp?a 0 15884 0-36 15420665Smckusick hp?b 16058 33440 37-114 15520665Smckusick hp?c 0 242606 0-558 15620666Smckusick hp?d 49910 15884 115-151 15720666Smckusick hp?e 68096 55936 152-280 15820666Smckusick hp?f 125888 120466 281-558 15920666Smckusick hp?g 49910 192510 115-558 16047674Scael 16147674Scael.Tn RP05 No partitions 16247674Scael.Sy disk start length cyls 16320666Smckusick hp?a 0 15884 0-37 16420666Smckusick hp?b 15884 33440 38-117 16520666Smckusick hp?c 0 171798 0-410 16620666Smckusick hp?d 2242 15884 118-155 16720666Smckusick hp?e 65208 55936 156-289 16820666Smckusick hp?f 121220 50424 290-410 16920666Smckusick hp?g 2242 122320 118-410 17047674Scael 17147674Scael.Tn RP07 No partitions 17247674Scael.Sy disk start length cyls 17320665Smckusick hp?a 0 15884 0-9 17420666Smckusick hp?b 16000 66880 10-51 17520665Smckusick hp?c 0 1008000 0-629 17620666Smckusick hp?d 376000 15884 235-244 17720666Smckusick hp?e 392000 307200 245-436 17820666Smckusick hp?f 699200 308600 437-629 17920666Smckusick hp?g 376000 631800 235-629 18020666Smckusick hp?h 83200 291346 52-234 18147674Scael 18247674Scael.Tn CDC No 9775 partitions 18347674Scael.Sy disk start length cyls 18420666Smckusick hp?a 0 15884 0-12 18520666Smckusick hp?b 16640 66880 13-65 18628250Skarels hp?c 0 1077760 0-841 18720666Smckusick hp?d 376320 15884 294-306 18820666Smckusick hp?e 392960 307200 307-546 18928250Skarels hp?f 700160 377440 547-841 19028250Skarels hp?g 376320 701280 294-841 19120666Smckusick hp?h 84480 291346 66-293 19247674Scael 19347674Scael.Tn CDC No 9730 partitions 19447674Scael.Sy disk start length cyls 19520666Smckusick hp?a 0 15884 0-49 19620666Smckusick hp?b 16000 33440 50-154 19720666Smckusick hp?c 0 263360 0-822 19820666Smckusick hp?d 49600 15884 155-204 19920666Smckusick hp?e 65600 55936 205-379 20020666Smckusick hp?f 121600 141600 380-822 20120666Smckusick hp?g 49600 213600 155-822 20247674Scael 20347674Scael.Tn AMPEX No Capricorn partitions 20447674Scael.Sy disk start length cyls 20520666Smckusick hp?a 0 15884 0-31 20620666Smckusick hp?b 16384 33440 32-97 20720666Smckusick hp?c 0 524288 0-1023 20820666Smckusick hp?d 342016 15884 668-699 20920666Smckusick hp?e 358400 55936 700-809 21020666Smckusick hp?f 414720 109408 810-1023 21120666Smckusick hp?g 342016 182112 668-1023 21220666Smckusick hp?h 50176 291346 98-667 21347674Scael 21447674Scael.Tn FUJITSU No Eagle partitions 21547674Scael.Sy disk start length cyls 21620666Smckusick hp?a 0 15884 0-16 21720666Smckusick hp?b 16320 66880 17-86 21820666Smckusick hp?c 0 808320 0-841 21920666Smckusick hp?d 375360 15884 391-407 22020666Smckusick hp?e 391680 55936 408-727 22120666Smckusick hp?f 698880 109248 728-841 22220666Smckusick hp?g 375360 432768 391-841 22320666Smckusick hp?h 83520 291346 87-390 22447674Scael 22547674Scael.Tn FUJITSU No 2361 partitions 22647674Scael.Sy disk start length cyls 22728936Smis hp?a 0 15884 0-12 22828936Smis hp?b 16640 66880 13-65 22928936Smis hp?c 0 1077760 0-841 23028936Smis hp?d 376320 15884 294-306 23128936Smis hp?e 392960 307200 307-546 23228936Smis hp?f 700160 377408 547-841 23328936Smis hp?g 363520 701248 294-841 23428936Smis hp?h 84480 291346 66-293 23547674Scael 23647674Scael.Tn AMPEX No 9300 partitions 23747674Scael.Sy disk start length cyl 23820666Smckusick hp?a 0 15884 0-26 23920666Smckusick hp?b 16416 33440 27-81 24020666Smckusick hp?c 0 495520 0-814 24120666Smckusick hp?d 341696 15884 562-588 24220666Smckusick hp?e 358112 55936 589-680 24320666Smckusick hp?f 414048 81312 681-814 24420666Smckusick hp?g 341696 153664 562-814 24520666Smckusick hp?h 49856 291346 82-561 24647674Scael.El 24747674Scael.Pp 24820665SmckusickThe hp?a partition is normally used for the root file system, 24920665Smckusickthe hp?b partition as a paging area, 25020665Smckusickand the hp?c partition for pack-pack copying (it maps the entire disk). 25120666SmckusickOn disks larger than about 205 Megabytes, the hp?h partition 25220666Smckusickis inserted prior to the hp?d or hp?g partition; 25320666Smckusickthe hp?g partition then maps the remainder of the pack. 25420666SmckusickAll disk partition tables are calculated using the 25547674Scael.Xr diskpart 8 25620666Smckusickprogram. 25747674Scael.Pp 25847674Scael.Sh FILES 25947674Scael.Bl -tag -width /dev/rhp[0-7][a-h] -compact 26047674Scael.It Pa /dev/hp[0-7][a-h] 26147674Scaelblock files 26247674Scael.It Pa /dev/rhp[0-7][a-h] 26347674Scaelraw files 26447674Scael.El 26547674Scael.Sh DIAGNOSTICS 26647674Scael.Bl -diag 26747674Scael.It "hp%d%c: hard error %sing fsbn %d [of %d-%d] (hp%d bn %d cn %d tn %d sn %d) mbsr=%b er1=%b er2=%b." 26834730SkarelsAn unrecoverable error occurred during transfer of the specified 26934730Skarelsfilesystem block number, 27034730Skarelswhich is a logical block number on the indicated partition. 27134730SkarelsIf the transfer involved multiple blocks, the block range is printed as well. 27234730SkarelsThe parenthesized fields list the actual disk sector number 27334730Skarelsrelative to the beginning of the drive, 27434730Skarelsas well as the cylinder, track and sector number of the block. 27547674ScaelThe 27647674Scael.Tn MASSBUS 27747674Scaelstatus register is printed in hexadecimal and 27847674Scaelwith the error bits decoded if any error bits other than 27947674Scael.Tn MBEXC 28047674Scaeland 28147674Scael.Tn DTABT 28220665Smckusickare set. In any case the contents of the two error registers are also printed 28320665Smckusickin octal and symbolically with bits decoded. 28447674Scael(Note that er2 is what old 28547674Scael.Tn RP06 28647674Scaelmanuals would call 28747674Scael.Tn RPER3 ; 28847674Scaelthe terminology 28947674Scaelis that of the 29047674Scael.Tn RM 29147674Scaeldisks). 29220665SmckusickThe error was either unrecoverable, or a large number of retry attempts 29320665Smckusick(including offset positioning and drive recalibration) could not 29420665Smckusickrecover the error. 29547674Scael.Pp 29647674Scael.It hp%d: write locked. 29747674ScaelThe write protect switch was set on the drive 29820665Smckusickwhen a write was attempted. The write operation is not recoverable. 29947674Scael.Pp 30047674Scael.It hp%d: not ready . 30147674ScaelThe drive was spun down or off line when it was 30247674Scaelaccessed. The 30347674Scael.Tn I/O 30447674Scaeloperation is not recoverable. 30547674Scael.Pp 30647674Scael.It "hp%d%c: soft ecc reading fsbn %d [of %d-%d] (hp%d bn %d cn %d tn %d sn %d)." 30747674ScaelA recoverable 30847674Scael.Tn ECC 30947674Scaelerror occurred on the 31020666Smckusickspecified sector of the specified disk partition. 31134730SkarelsIf the transfer involved multiple blocks, the block range is printed as well. 31234730SkarelsThe parenthesized fields list the actual disk sector number 31334730Skarelsrelative to the beginning of the drive, 31434730Skarelsas well as the cylinder, track and sector number of the block. 31520666SmckusickThis happens normally 31620665Smckusicka few times a week. If it happens more frequently than 31720666Smckusickthis the sectors where the errors are occurring should be checked to see 31820665Smckusickif certain cylinders on the pack, spots on the carriage of the drive 31920665Smckusickor heads are indicated. 32047674Scael.Pp 32147674Scael.It hp%d: 9775 (direct). 32247674Scael.It hp%d: 9730 (direct). 32347674Scael.It hp%d: 9300. 32447674Scael.It hp%d: 9762. 32547674Scael.It hp%d: capricorn. 32647674Scael.It hp%d: eagle. 32747674Scael.It hp%d: 2361. 32847674Scael.It hp%d: ntracks %d, nsectors %d: unknown device. 32947674ScaelDuring autoconfiguration one of the above messages may appear 33020666Smckusickon the console indicating the appropriate drive type was recognized. 33120666SmckusickThe last message indicates the drive is of a unknown type. 33234730SkarelsIn this case, the correct geometry is set, and one partition is created 33334730Skarelsthat contains the entire drive. 33447674Scael.Pp 33547674Scael.El 33647674Scael.Sh SEE ALSO 33747674Scael.Xr physio 4 , 33847674Scael.Xr up 4 , 33947674Scael.Xr disklabel 5 , 34047674Scael.Xr MAKEDEV 8 34147674Scael.Xr disklabel 8 34247674Scael.Xr mknod 8 34347674Scael.Sh HISTORY 34447674ScaelThe 34547674Scael.Nm 34647674Scaeldriver appeared in 34747674Scael.Bx 4.0 . 34847674Scael.Sh BUGS 34947674Scael.Tn DEC Ns -standard 35047674Scaelerror logging should be supported. 35147674Scael.Pp 35220665SmckusickA program to analyze the logged error information (even in its 35320665Smckusickpresent reduced form) is needed. 354