From wilko@dontpanic.tcja.nl Sat Jul  3 05:56:58 1999
Return-Path: <wilko@dontpanic.tcja.nl>
Received: from mailhub.tcja.nl (mailhub.tcja.nl [194.178.62.127])
	by hub.freebsd.org (Postfix) with ESMTP id D484714DDB
	for <FreeBSD-gnats-submit@freebsd.org>; Sat,  3 Jul 1999 05:56:56 -0700 (PDT)
	(envelope-from wilko@dontpanic.tcja.nl)
Received: (from uucp@localhost)
	by mailhub.tcja.nl (8.9.1/8.9.1) with UUCP id PAA10086
	for FreeBSD-gnats-submit@freebsd.org; Sat, 3 Jul 1999 15:18:27 +0200 (CEST)
Received: (from wilko@localhost)
	by dontpanic.tcja.nl (8.8.8/8.8.5) id OAA07636;
	Sat, 3 Jul 1999 14:56:41 +0200 (CEST)
Message-Id: <199907031256.OAA07636@dontpanic.tcja.nl>
Date: Sat, 3 Jul 1999 14:56:41 +0200 (CEST)
From: wilko@freebsd.org
Sender: wilko@dontpanic.tcja.nl
Reply-To: wilko@freebsd.org,frank@tcja.nl
To: FreeBSD-gnats-submit@freebsd.org
Subject: cdrom drive detection failure during install
X-Send-Pr-Version: 3.2

>Number:         12495
>Category:       kern
>Synopsis:       3.1 install fails to detect Toshiba CDROM on AHA1740 adapter
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Jul  3 06:00:01 PDT 1999
>Closed-Date:    Wed Apr 26 12:51:30 PDT 2000
>Last-Modified:  Wed Apr 26 12:52:37 PDT 2000
>Originator:     Wilko Bulte
>Release:        FreeBSD 3.1-RELEASE
>Organization:
TCJA
>Environment:

	EISA machine with a single Adaptec 1740A adapter.
	Toshiba XM-5401B SCSI cdrom. FreeBSD 3.1-RELEASE CDROM. Boot from
	bootfloppy taken from 3.1-cdrom.

>Description:

	After poweron both the harddisk (SCSI ID #0) and the Toshiba CD
	(ID #4) are detected OK by the 1740A BIOS. The bootfloppy kernel
	initiates a bus reset and waits for 15 secs. During this time
	the LED of the CD blinks. The booted install kernel fails to detect
	the cdrom drive though.

	An attempt with a FreeBSD 2.2.6-RELEASE bootfloppy detects the
	cdrom drive just fine. 2.2.6 install runs fine.

	Guessing: it looks like 15 secs delay is too short for this CDROM
	type. See also kern/5181 for a similar Toshiba problem.

>How-To-Repeat:

	See above

>Fix:
	
	Most likely increasing the 15 secs delay in the install floppy
	will help. Is there any way of changing the delay used by 
	the boot floppy? If not, I'm willing to test drive a floppy 
	with an increased delay (25 - 30 secs should do it I guess).
	Testdrive may take a couple of days as I'm remote from the machine.
	


>Release-Note:
>Audit-Trail:

From: "Kenneth D. Merry" <ken@plutotech.com>
To: wilko@FreeBSD.ORG
Cc: FreeBSD-gnats-submit@FreeBSD.ORG
Subject: Re: kern/12495: cdrom drive detection failure during install
Date: Sat, 3 Jul 1999 13:11:11 -0600 (MDT)

 wilko@FreeBSD.ORG wrote...
 > 
 > >Number:         12495
 > >Category:       kern
 > >Synopsis:       3.1 install fails to detect Toshiba CDROM on AHA1740 adapter
 > >Confidential:   no
 > >Severity:       non-critical
 > >Priority:       medium
 > >Responsible:    freebsd-bugs
 > >State:          open
 > >Quarter:        
 > >Keywords:       
 > >Date-Required:
 > >Class:          sw-bug
 > >Submitter-Id:   current-users
 > >Arrival-Date:   Sat Jul  3 06:00:01 PDT 1999
 > >Closed-Date:
 > >Last-Modified:
 > >Originator:     Wilko Bulte
 > >Release:        FreeBSD 3.1-RELEASE
 > >Organization:
 > TCJA
 > >Environment:
 > 
 > 	EISA machine with a single Adaptec 1740A adapter.
 > 	Toshiba XM-5401B SCSI cdrom. FreeBSD 3.1-RELEASE CDROM. Boot from
 > 	bootfloppy taken from 3.1-cdrom.
 > 
 > >Description:
 > 
 > 	After poweron both the harddisk (SCSI ID #0) and the Toshiba CD
 > 	(ID #4) are detected OK by the 1740A BIOS. The bootfloppy kernel
 > 	initiates a bus reset and waits for 15 secs. During this time
 > 	the LED of the CD blinks. The booted install kernel fails to detect
 > 	the cdrom drive though.
 > 
 > 	An attempt with a FreeBSD 2.2.6-RELEASE bootfloppy detects the
 > 	cdrom drive just fine. 2.2.6 install runs fine.
 > 
 > 	Guessing: it looks like 15 secs delay is too short for this CDROM
 > 	type. See also kern/5181 for a similar Toshiba problem.
 > 
 > >How-To-Repeat:
 > 
 > 	See above
 > 
 > >Fix:
 > 	
 > 	Most likely increasing the 15 secs delay in the install floppy
 > 	will help. Is there any way of changing the delay used by 
 > 	the boot floppy? If not, I'm willing to test drive a floppy 
 > 	with an increased delay (25 - 30 secs should do it I guess).
 > 	Testdrive may take a couple of days as I'm remote from the machine.
 
 
 Did you have a CDROM in the drive when you booted?  If not, that's your
 problem.  There is a known problem with sysinstall and booting without a CD
 inserted.  It won't detect the CDROM drive, because it tries to do an open
 of all sorts of devices at boot to see if they exist.
 
 In any case, changing the bus settle delay won't really help you any, I
 don't think.  The XM-5401B isn't exactly an old device, I don't think, and
 shouldn't need any longer for a bus settle delay.
 
 Assuming you did have a CD in the drive, probably the thing that's taking a
 while is the read capacity of the CDROM drive, which happens after the bus
 reset and bus settle delay.  I've got a couple of ideas of how to fix
 this, but none of them are especially "clean".
 
 Ken
 -- 
 Kenneth Merry
 ken@plutotech.com
 

From: Wilko Bulte <wilko@freebsd.org>
To: freebsd-gnats-submit@freebsd.org, wilko@freebsd.org
Cc:  
Subject: Re: kern/12495: 3.1 install fails to detect Toshiba CDROM on AHA1740 
 adapter
Date: Sun, 04 Jul 1999 12:08:50 +0200

 Hi Ken,
 
 Thanks for your reply.
 
 On your question: yes, there was a 3.1 release CD in the drive during
 the boot.
 
 And you are right, the Toshiba drive is not exactly an ancient device.
 Not new either, it is a 4x
 cdrom.
 
 What puzzles me is the fact that 2.2.x has always worked just fine,
 I have multiple of the
 same Toshiba model in both my Intel and Alpha machines.
 
 I'll probably give 3.2-release a try next Saturday.
 
 Wilko
 
 

From: "Kenneth D. Merry" <ken@plutotech.com>
To: wilko@FreeBSD.ORG (Wilko Bulte)
Cc: freebsd-bugs@FreeBSD.ORG, freebsd-gnats-submit@FreeBSD.ORG
Subject: Re: kern/12495: 3.1 install fails to detect Toshiba CDROM on AHA1740  adapter
Date: Mon, 5 Jul 1999 03:33:58 -0600 (MDT)

 [ If you don't CC messages to me, it'll take a lot longer to get a reply. ]
 
 Wilko Bulte wrote...
 > The following reply was made to PR kern/12495; it has been noted by GNATS.
 > 
 > From: Wilko Bulte <wilko@freebsd.org>
 > To: freebsd-gnats-submit@freebsd.org, wilko@freebsd.org
 > Cc:  
 > Subject: Re: kern/12495: 3.1 install fails to detect Toshiba CDROM on AHA1740 
 >  adapter
 > Date: Sun, 04 Jul 1999 12:08:50 +0200
 > 
 >  Hi Ken,
 >  
 >  Thanks for your reply.
 >  
 >  On your question: yes, there was a 3.1 release CD in the drive during
 >  the boot.
 
 Okay, that rules out that problem.
 
 >  And you are right, the Toshiba drive is not exactly an ancient device.
 >  Not new either, it is a 4x
 >  cdrom.
 >  
 >  What puzzles me is the fact that 2.2.x has always worked just fine,
 >  I have multiple of the
 >  same Toshiba model in both my Intel and Alpha machines.
 
 It's not as puzzling as you might think.  We don't wait for the CDROM drive
 to finish probing before we start booting.  So if sysinstall probes right
 away, it might not see the cdrom drive.
 
 The old SCSI layer probed things sequentially, so you would finish probing
 everything, no matter how long it took, before any booting took place.
 
 >  I'll probably give 3.2-release a try next Saturday.
  
 Good idea, it's possible that'll fix the problem, although I'm not so sure
 it will.
 
 Ken
 -- 
 Kenneth Merry
 ken@plutotech.com
 

From: Wilko Bulte <wilko@yedi.iaf.nl>
To: ken@plutotech.com (Kenneth D. Merry)
Cc: wilko@FreeBSD.ORG, freebsd-bugs@FreeBSD.ORG,
	freebsd-gnats-submit@FreeBSD.ORG, ken@plutotech.com
Subject: Re: kern/12495: 3.1 install fails to detect Toshiba CDROM on AHA1740  adapter
Date: Mon, 5 Jul 1999 20:50:24 +0200 (CEST)

 As Kenneth D. Merry wrote ...
 > [ If you don't CC messages to me, it'll take a lot longer to get a reply. ]
 
 OK, done.
 
 > >  Hi Ken,
 > >  
 > >  Thanks for your reply.
 > >  
 > >  On your question: yes, there was a 3.1 release CD in the drive during
 > >  the boot.
 > 
 > Okay, that rules out that problem.
 > 
 > >  And you are right, the Toshiba drive is not exactly an ancient device.
 > >  Not new either, it is a 4x
 > >  cdrom.
 > >  
 > >  What puzzles me is the fact that 2.2.x has always worked just fine,
 > >  I have multiple of the
 > >  same Toshiba model in both my Intel and Alpha machines.
 > 
 > It's not as puzzling as you might think.  We don't wait for the CDROM drive
 > to finish probing before we start booting.  So if sysinstall probes right
 > away, it might not see the cdrom drive.
 
 Right, I should have thought of that myself (from my adventures with the
 Pioneer CD changer drive).
 
 > The old SCSI layer probed things sequentially, so you would finish probing
 > everything, no matter how long it took, before any booting took place.
 
 Right. Maybe the install kernel should stick to sequential probing? 
 I don't particularly like 'time dependent' probing with the variety of
 hardware that is out there.
 
 > >  I'll probably give 3.2-release a try next Saturday.
 >  
 > Good idea, it's possible that'll fix the problem, although I'm not so sure
 > it will.
 
 I'll post results later.
 
 Wilko
 --
 |   / o / /  _  	 Arnhem, The Netherlands	- Powered by FreeBSD -
 |/|/ / / /( (_) Bulte 	 WWW  : http://www.tcja.nl 	http://www.freebsd.org
 

From: "Justin T. Gibbs" <gibbs@caspian.plutotech.com>
To: Wilko Bulte <wilko@yedi.iaf.nl>
Cc: ken@plutotech.com (Kenneth D. Merry), wilko@FreeBSD.ORG,
	freebsd-bugs@FreeBSD.ORG, freebsd-gnats-submit@FreeBSD.ORG
Subject: Re: kern/12495: 3.1 install fails to detect Toshiba CDROM on AHA1740 adapter 
Date: Mon, 05 Jul 1999 18:52:59 -0600

 >> The old SCSI layer probed things sequentially, so you would finish probing
 >> everything, no matter how long it took, before any booting took place.
 >
 >Right. Maybe the install kernel should stick to sequential probing? 
 >I don't particularly like 'time dependent' probing with the variety of
 >hardware that is out there.
 
 All CAM device instances 'exist' before the boot up is allowed to progress.
 If you attempt to open the device while it is initializing, you will block
 in open until the initialization is complete, but the open will eventually
 succeed (assuming we were successful in our attempts to initialize the device).
 The same probing mechanism (parallel probing) is used to find our root
 device, and I have not heard of an instance where that has failed.  I would
 not expect sysintall to see the world any differently than the mount root
 code.
 
 Perhaps there is another bug in the ahb driver...
 
 --
 Justin
 
 

From: Wilko Bulte <wilko@yedi.iaf.nl>
To: gibbs@caspian.plutotech.com (Justin T. Gibbs)
Cc: ken@plutotech.com, wilko@FreeBSD.ORG, freebsd-bugs@FreeBSD.ORG,
	freebsd-gnats-submit@FreeBSD.ORG
Subject: Re: kern/12495: 3.1 install fails to detect Toshiba CDROM on AHA1740 adapter
Date: Sat, 10 Jul 1999 18:56:11 +0200 (CEST)

 As Justin T. Gibbs wrote ...
 
 > >> The old SCSI layer probed things sequentially, so you would finish probing
 > >> everything, no matter how long it took, before any booting took place.
 > >
 > >Right. Maybe the install kernel should stick to sequential probing? 
 > >I don't particularly like 'time dependent' probing with the variety of
 > >hardware that is out there.
 > 
 > All CAM device instances 'exist' before the boot up is allowed to progress.
 > If you attempt to open the device while it is initializing, you will block
 > in open until the initialization is complete, but the open will eventually
 > succeed (assuming we were successful in our attempts to initialize the device).
 > The same probing mechanism (parallel probing) is used to find our root
 > device, and I have not heard of an instance where that has failed.  I would
 > not expect sysintall to see the world any differently than the mount root
 > code.
 > 
 > Perhaps there is another bug in the ahb driver...
 
 No.
 
 Today I did the following experiment (on the same machine):
 
 - 3.1-release install on Adaptec 1740A (ahb driver): cdrom not detected
 
 - 3.1-release install on Adaptec 2740 (ahc driver): cdrom not detected
 
 - 3.2-release install on Adaptec 2740 (ahc driver): cdrom detected on 
   one occasion, subsequent attempts resulted in cdrom not detected.
 
 We decided to install 3.1-release (that is the cd version the machine
 owner has bought) via het Ethernet. This went fine. Booting the installed
 system results in detection of the cdrom drive just fine, reliable and all.
 We left the 2740 in the machine for the 3.1 network installation. 
 
 My new theory is that sysinstall is the culprit, not the CAM/scsi subsystem.
 
 Any idea how I can verify this idea?
 
 NB the same guy that has this problem reported an identical "cdrom not
 found" problem on an IDE system. I remember having seen some discussions
 on this subject on the lists. But I am strictly SCSI-only so I did not 
 pay too much attention.
 
 Wilko
 --
 |   / o / /  _  	 Arnhem, The Netherlands	- Powered by FreeBSD -
 |/|/ / / /( (_) Bulte 	 WWW  : http://www.tcja.nl 	http://www.freebsd.org
 
 
State-Changed-From-To: open->closed 
State-Changed-By: wilko 
State-Changed-When: Wed Apr 26 12:51:30 PDT 2000 
State-Changed-Why:  
PR originator reports problem is no longer reproducible using 
4.0-R 
>Unformatted:
