hd(7) hd(7)
NAME
hd - hard disk interface
DESCRIPTION
hd provides the interface to all types of SCSI hard disk units, and
uses the scsi(7) interface to communicate with the SCSI hardware.
The binary representation of the minor device number is encoded as
tttdddmpppp where ttt is the SCSI target id and ddd is the SCSI
logical unit (drive) number and pppp is the partition number on that
drive. The f partition is reserved to access the whole physical
disk. This can be useful when, for example, it is required to make a
copy of an entire removable disk cartridge.
The following extra fields are implemented in the pdsector structure
(which is defined in /usr/include/sys/vtoc.h).
#define interleave devsp[0]
#define wholedisksize devsp[1]
The meanings of these fields are as follows:
wholedisksize
The total physical disk size (in 512-byte blocks).
interleave
Used during SCSI formatting to specify the hardware interleave.
Both block and character (raw) interfaces are provided. The block
interface accesses the disk via the system's normal buffering
mechanism and may be read or written without regard to physical disk
records.
The raw interface provides for direct transmission between the disk
and the user's data area; thus I/O is considerably more efficient
when large amounts of data are to be transferred. However, seeks are
truncated to 512-byte block boundaries and attempts to transfer data
in quantities that are not in multiples of 512 bytes will fail,
returning an error condition.
The device tables, i.e. the pdsector and vtoc are obtained upon
opening any disk partition except the last, which is reserved as the
whole physical disk. All disk administration tools should therefore
avoid using the f partition, as it will not load the required disk
tables. Partinit must use the f partition.
FILES
/dev/dsk/cXdYsZ Block interface for SCSI target X, logical unit Y,
partition (slice) Z.
7/91 Page 1
hd(7) hd(7)
/dev/dsk/cXdYsf Block whole disk interface for physical drive on
SCSI target X, logical unit Y.
/dev/rdsk/cXdYsZ Raw interface for SCSI target X, logical unit Y,
partition Z.
/dev/rdsk/cXdYsf Raw whole disk interface for physical drive on SCSI
target X, logical unit Y.
SEE ALSO
disk(7), scsi(7).
Page 2 7/91