Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 23 Jan 2004 11:42:57 -0500
From:      Jesse Guardiani <jesse@wingnet.net>
To:        freebsd-scsi@freebsd.org
Subject:   Re: adaptec 2940u/uw dump card state ends
Message-ID:  <buriui$2ks$1@sea.gmane.org>
References:  <buoiuh$msf$1@sea.gmane.org> <200401230843.i0N8hZ7E066527@gw.catspoiler.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Don Lewis wrote:

> On 22 Jan, Jesse Guardiani wrote:
>> Jesse Guardiani wrote:

[...]

>>> (ch0:ahc0:0:2:1): SCB 0xe - timed out
> 
> Just a guess ... maybe the changer mechanism requires a longer time than
> what the driver thinks.  At the top of /usr/src/sys/cam/scsi/scsi_ch.c
> there is the following:
> 
> /*
>  * Timeout definitions for various changer related commands.  They may
>  * be too short for some devices (especially the timeout for INITIALIZE
>  * ELEMENT STATUS).
>  */
>           
> static const u_int32_t  CH_TIMEOUT_MODE_SENSE                = 6000;
> static const u_int32_t  CH_TIMEOUT_MOVE_MEDIUM               = 100000;
> static const u_int32_t  CH_TIMEOUT_EXCHANGE_MEDIUM           = 100000;
> static const u_int32_t  CH_TIMEOUT_POSITION_TO_ELEMENT       = 100000;
> static const u_int32_t  CH_TIMEOUT_READ_ELEMENT_STATUS       = 10000;
> static const u_int32_t  CH_TIMEOUT_SEND_VOLTAG               = 10000;
> static const u_int32_t  CH_TIMEOUT_INITIALIZE_ELEMENT_STATUS = 500000;
> 
> I think these times are milliseconds.  The scsi command that you are
> using may be using one of these timeouts: CH_TIMEOUT_MOVE_MEDIUM,
> CH_TIMEOUT_EXCHANGE_MEDIUM, or CH_TIMEOUT_POSITION_TO_ELEMENT (I'm not
> very familiar with changers).  These appear to be set to 100 seconds, so
> if your changer takes longer than this, the driver will time out the
> command before the changer indicates that it is finished.  Try bumping
> these up and rebuild your kernel.  They should probably be tunable ...

Hmmm...


The device works absolutely perfectly after that first timeout. Do you still
think it's a timeout issue? Personally, I'm leaning toward it being a problem
with termination because I _believe_ this autoloader is an 8 bit device.

Unfortunately, I don't understand the problem, so I don't really know how to
fix it. :( Maybe some googling will help.


>>> So far, all further commands have been successfull.
>>> 
>>> Here's my uname:
>>> 
>>> # uname -a
>>> FreeBSD billmax.int.wingnet.net 4.9-RELEASE FreeBSD 4.9-RELEASE #0: Sun
>>> Jan 18 18:29:28 EST 2004
>>> jesse@billmax.int.wingnet.net:/usr/src/sys/compile/BILLMAX  i386
>>> 
>>> Any suggestions?
>> 
>> Surely someone on the -SCSI list can at LEAST answer my simple questions
>> about TERM PWR vs SCSI TERM jumpers on drives....
>> 
>> I'd love to know why I'm getting the above timeout too, but if someone
>> could just verify the difference between TERM PWR and SCSI TERM, and
>> how they should be used then I can at least get a starting point.
> 
> One of the wires the SCSI bus (TERMPWR) is used to supply termination
> power to any passive terminators (or active terminators without their
> own power source) at the ends of the bus.  Usually you will want the
> host adapter to supply termination power.  Peripherals also commonly
> have jumpers or switches that can be set to cause them to supply power
> to the TERMPWR line.  If the peripheral has a jumper labeled TERM PWR,
> it is used to supply power to the TERMPWR line on the SCSI bus.  As I
> recall, no more than two devices should power the TERMPWR line, to limit
> the amount of current that would flow if the TERMPWR line is shorted to
> ground, so that nothing catches on fire.
> 
> Many peripherals are also able to terminate the bus so that an external
> terminator is not needed.  This is typically done by setting a jumper or
> switch, or plugging a resistor pack into a socket on the peripheral.  If
> the peripheral at the end of a bus is used to terminate the bus instead
> of using an external terminator, the power for the terminator can either
> be taken from the power supplied to the peripheral, or from the TERM PWR
> line on the SCSI bus.  You would want to do the latter if you want the
> bus to operate properly even if power to the peripheral is shut off.
> 
> I typically use Seagate SCSI disks which have two jumper positions to
> control termination and termination power.  I believe there are five
> different jumper arrangements allowed (at least for single-ended SCSI)
> for the different termination configurations.
> 
> When the host adapter is at one end of the bus, I prefer to let it feed
> TERMPWR along with the peripheral at the other end of the bus (assuming
> that it is always powered on), so that the power to the terminator at
> the far end of the bus is as clean as possible.


Great explanation! Thanks!

-- 
Jesse Guardiani, Systems Administrator
WingNET Internet Services,
P.O. Box 2605 // Cleveland, TN 37320-2605
423-559-LINK (v)  423-559-5145 (f)
http://www.wingnet.net




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?buriui$2ks$1>