Everhart, Glenn
From:	Mark Berryman [Mark.Berryman@Mvb.Saic.Com]
Sent:	Thursday, August 27, 1998 8:31 PM
To:	Info-VAX@Mvb.Saic.Com
Subject:	Re: Solution: Why does Seagate ST19171N fail on INIT cmd?
Brian Schenkenberger, VAXman- wrote:
> 
> In article <6s45vt$96v$1@hecate.umd.edu>, bleau@umdsp.umd.edu (Lawrence Bleau) writes:
> >Hello, folks!  I'm back, posting a solution, rather than a problem.

[most of the description deleted...]

> >I gave the drive to a colleague, who used a utility to turn off the two bits
> >Stu mentioned.  It worked!  The drive can now be INITed, written, read,
> >everything.
> 
> Glenn (Mr. SCSI) Everhart told me of this problem when I recently queried
> him about a Seagate drive.
> 
> Could you get your "colleague" to explain how he went about disabling the
> two bits: ARRE and AWRE on this drive?  It would make my like a whole lot
> easier and less stressful.

It should be pretty straight-forward (if you have a system recent enough
to have the directory sys$etc and the utility contained therein called
SCSI_MODE.EXE).

Please note that all values given below are in hex which is the only
radix understood by this utility.

You will need DIAGNOSE and PHY_IO privilege.

Issue a command as follows:

$ mcr sys$etc:scsi_mode -devname dkb300 -page 1
  (-devname specifies the disk to be read and page 1 is the
   read-write error recovery page)

This command will read the current value of page 1 and indicate which
bits can be changed.  The resulting display should look something like
this:

$! Processing Page #1h
$!
$! Cur   00______ 04______ 08______ 0C______ 10______ 14______ 18______ 1C______
$! 0000  17001008 001F4B2C 00000200 810AE408 78000000 08000000
$!
$! Chng  00______ 04______ 08______ 0C______ 10______ 14______ 18______ 1C______
$! 0000  17001008 001F4B2C 00000200 810AFFFF FFFFFFFF FFFFFFFF
$!

The contents of page 1 are displayed beginning at offset 0C as follows:

0C = 81 = page number with the high bit set (which means the page can be saved)
0D = 0A = size of the rest of the page
0E = E4 = the read-write recovery flags, the value you want to change
          (and, as you can see from the change mask, the 1st byte that
           can be changed)

The AWRE and ARRE flags are the 2 high-order bits in the byte, thus - in
this example - we want to change the E4 to 24.

Issue the command: 

mcr sys$etc:scsi_mode -devname dkb300 -page 1 -offset 0E 24 -devtyp "????"

and it will display the change you are about to make and, after confirmation,
make the change.  Note that the -devtyp switch is required as a sanity check
and must equal the device-type string returned as the result of a SCSI INQUIRY
command (in my case: rz26).  If you don't know the devtyp of the device in
question, issue the command without the switch and it will tell you.

Hope this helps,

Mark Berryman
Mark.Berryman@Mvb.Saic.Com