Subject: Re: AHA1542B stopped working!
To: Charles M. Hannum <mycroft@mit.edu>
From: Tom I Helbekkmo <tih@Hamartun.Priv.NO>
List: port-i386
Date: 03/30/1996 10:03:45
On 29 Mar 1996, Charles M. Hannum wrote:

| It looks like the `inquire installed devices' command is timing out,
| and it ends up colliding with the following command.  I'm not sure why
| it would take so long; maybe one of your drives is jumpered to not
| spin up until it gets a START UNIT command?  Could you try increasing
| the timeout for AHA_INQUIRE_DEVICES (near the top of aha_cmd()) from
| 15 to maybe 60 seconds, and see if that helps?

That did it:  I'm now happily booting, although it takes 80 seconds
for the AHA_INQUIRE_DEVICES command to complete.  This is repeatable;
it takes 80 seconds on every NetBSD boot with the new AHA code, and
the old SCSICNTL application (under DOS, booted from floppy) that I
mentioned sits for the same 80 seconds with a "Probing for devices on
the SCSI bus..." message on the screen.

However, I've found the problem.  Knowing that something was just
taking "forever" during the probing, my thoughts naturally turned to
this little fellow:

cd0 at scsibus0 targ 4 lun 0: <HITACHI, CDR-3650/1650S, 0003> SCSI1 5/cdrom removable

It turns out that if I just stuff a CD in this old Hitachi drive, the
boot is quick and easy, and NetBSD and SCSICNTL both take just a few
seconds to scan the bus.  Without a CD in the drive, it's 80 seconds.

Maybe, for weird cases like this, you should have some sort of a
double timeout?  If the AHA_INQUIRE_DEVICES command doesn't complete
within, say, 10 seconds, you output a message saying something like
"aha0: probing for devices, will time out within two minutes", and
then give it some more time before giving up on it.  After all, my CD
ROM drive works perfectly, it just take a while to autodetect it...

Thanks for your help, Charles!  It's good to be back to normal!  :-)

-tih
--
Tom Ivar Helbekkmo
tih@Hamartun.Priv.NO