Date: Tue, 11 Jul 1995 07:37:37 -0400 (EDT) From: Peter Dufault <dufault@hda.com> To: sysseh@devetir.qld.gov.au (Stephen Hocking) Cc: scsi@freebsd.org Subject: Re: Determining the sector size of a SCSI device in FreeBSD Message-ID: <199507111137.HAA02292@hda.com> In-Reply-To: <199507111050.KAA24365@netfl15a.devetir.qld.gov.au> from "Stephen Hocking" at Jul 11, 95 08:50:29 pm
next in thread | previous in thread | raw e-mail | index | archive | help
Stephen Hocking writes: > > Peter, do you know if there's a quick way to determine the transfer size of a > SCSI device under FreeBSD? The reason I want to know is so I can adapt the > existing seagate.c to do transfers without phase checking. The old (2.0R) > driver had the facility to do this, and as result it was more than two times > quicker off a given device than what I'm seeing now. Do you mean the sector size the device is formatted with or something different? For the sector size: from a user program you can check data bytes per physical sector in mode page 3: > hda# scsi -f /dev/rsd2.ctl -m 3 > Tracks per Zone: 21 > Alternate Sectors per Zone: 5 > Alternate Tracks per Zone: 0 > Alternate Tracks per Logical Unit: 21 > Sectors per Track: 88 > Data Bytes per Physical Sector: 512 > Interleave: 1 > Track Skew Factor: 10 > Cylinder Skew Factor: 17 > SSEC: 0 > HSEC: 1 > RMB: 0 > SURF: 0 It is also in the block descriptor header returned for the sense, and is stored in disk_parms->secsiz when the drive is successfully opened. Look around in "sd.c" for disk_parms->secsiz. Peter -- Peter Dufault Real Time Machine Control and Simulation HD Associates, Inc. Voice: 508 433 6936 dufault@hda.com Fax: 508 433 5267
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199507111137.HAA02292>