home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.unix.aix
- Path: sparky!uunet!zaphod.mps.ohio-state.edu!cs.utexas.edu!geraldo.cc.utexas.edu!portal.austin.ibm.com!awdprime.austin.ibm.com!swan
- From: swan@austin.ibm.com (Randal C. Swanberg)
- Subject: Re: Adding SCSI OSDISK
- Originator: swan@swan2.austin.ibm.com
- Sender: news@austin.ibm.com (News id)
- Message-ID: <C0I05H.1A5I@austin.ibm.com>
- Date: Thu, 7 Jan 1993 19:15:17 GMT
- References: <1993Jan6.105119.1266@yvax.byu.edu> <19930107.062511.795@almaden.ibm.com>
- Organization: IBM
- Lines: 38
-
-
- In article <19930107.062511.795@almaden.ibm.com>, russotto@vnet.ibm.com (Matthew T. Russotto) writes:
- >
- > Many disks have a jumper which set whether they spin-up on power-on
- > or only when they receive a SCSI start. Would an request to spin up
- > when the disk was already spun up give that result code?
- >
- > Some disks always spin up on power up, and probably wouldn't like SCSI
- > start at all... will such disks work with AIX?
-
- All of the SCSI disks that we have experience with (i.e. IBM Japan 160MB, IBM
- Havant 857MB, IBM Rochester 320MB, 400MB, 1 GB, MAXTOR 355MB, 670MB, Seagate 1GB,
- ...and I'm sure there are others) basically no-op a SCSI Start-Unit if the disk
- is already spun-up.
-
- If a disk will not allow a Start-Unit when already spun-up, then the answer
- is NO, it won't work with AIX. The SCSI disk driver issues a Start-Unit command
- on the first open() to the disk. Basically I guess the assumption that the AIX
- SCSI Driver makes is that a)the disk may be spun down and b)if it isn't the
- Start-Unit command will be a no-op, not an error.
-
- >
- > How does one learn to translate those sense codes, BTW?
-
- There may be a more elegant way available, but here is what I do:
-
- The sense data for a SCSI device maps to the struct sc_error_log_df found
- in /usr/include/sys/scsi.h, minus the first to fields of the structure. In other
- words, the sense data starts with the struct scsi scsi_command field of the
- sc_error_log_df structure. Then look at struct scsi (also in scsi.h) and
- from there you can determine what bytes make up the actual command.
-
-
- --
- _____________________________________________________________________________
-
- Randy Swanberg swan@austin.ibm.com
- AIX Kernel Development 512-838-3363
-