Date: Thu, 8 Apr 1999 14:26:42 -0600 (MDT) From: "Kenneth D. Merry" <ken@plutotech.com> To: wilko@yedi.iaf.nl (Wilko Bulte) Cc: freebsd-scsi@freebsd.org Subject: Re: Getting Pioneer CD changer to work Message-ID: <199904082026.OAA11726@panzer.plutotech.com> In-Reply-To: <199904081839.UAA01138@yedi.iaf.nl> from Wilko Bulte at "Apr 8, 1999 8:39:55 pm"
next in thread | previous in thread | raw e-mail | index | archive | help
[ CCing this to -scsi since you seem to be sending things separately to me and then the -scsi list ] Wilko Bulte wrote... > As Kenneth D. Merry wrote ... > > Wilko Bulte wrote... > > > As Kenneth D. Merry wrote ... > > > > Wilko Bulte wrote... > > > > > As Kenneth D. Merry wrote ... > > > > > > Wilko Bulte wrote... > > FWIW, Justin and I have been talking about making the CD and DA drivers > > attach to devices "no matter what", for the most part. (unless they say > > something like "logical unit not supported") > > To be honest I never saw the point in doing a READ CAPACITY etc on a CD > drive. If it responds to an inquiry OK, does not produce sense codes > like hardware error I'd conclude we have a working drive on our hands. > But that might be too simplistic. We have to do a read capacity if we're going to mount the CD at all. The read capacity provides two critical pieces of information: the sector/block size of the device, and the size of the device. Both are needed for the disklabel and for mounting filesystems. Now the read capacity may not be necessary on attach, but it must be done before we can open the CD. I think it's generally worthwhile to do on attach as well. > > > I bumped the timeout to 120000 (ugh) 'cause the drive takes a considerable > > > time to 'inventory' the magazine. Especially when errors occur a long > > > timeout seems to be needed. > > > > You shouldn't need to do that unless it really does take 2 minutes to probe > > each lun. Once the changer code in the CD driver sees a CDROM device on a > > LUN other than 0, it assumes that it is a changer. > > > > That means that the probing should happen sequentially, not in parallel. > > So your timeout should be the time it takes for one LUN to probe, not all > > of them. > > OK. I just went back to the driver. I put the original driver in the tree > again and just added the 0xb0 ASC the drive reports during probe when no > magazine/cds are loaded. I left all the timeouts alone for now. > > Will test this later tonight when it has completed a complete magazine > test cycle. > > > You can put a quirk entry in the CD driver to make sure the CD driver sees > > even LUN 0 as part of a changer, but I don't think it'll have any noticable > > effect on the way things work. > > It has no problems detecting the 6 LUNs. The CD driver will detect all 6 LUNs with or without a quirk. The only reason for a quirk entry is that the various LUNs of the changer will not be seen/grouped as a changer until the CD driver sees a LUN greater than 1. Once a group of CD devices is recognized as a changer, I/O to any of those devices goes through the changer scheduler in the CD driver. The changer scheduler schedules I/O to each LUN in a changer, makes sure one LUN can't hog the changer if there is outstanding I/O to another LUN, etc. I don't think it's really necessary to have a quirk entry, though, since all the LUNs will be put in the changer scheduler before any I/O goes to LUN 1 of the device. > > > A mount of a plain iso9660 cd produced a new interesting message: > > > > > > Apr 8 00:52:46 p100 /kernel: (cd3:isp0:0:5:3): READ TOC/PMA/ATIP {MMC > > > Proposed}. CDB: 43 60 0 0 0 0 0 0 4 0 > > > Apr 8 00:52:46 p100 /kernel: (cd3:isp0:0:5:3): ILLEGAL REQUEST asc:20,0 > > > Apr 8 00:52:46 p100 /kernel: (cd3:isp0:0:5:3): ILLEGAL REQUEST asc:20,0 > > > Apr 8 00:52:46 p100 /kernel: (cd3:isp0:0:5:3): Invalid command operation > > > code > > > > > > Makes me wonder, especially because the Pioneer firmware claims to be CCS > > > only. There is a little dipswitch claiming to select SCSI-2 mode but it > > > does not have any obvious effect. I guess this is a pre-SCSI-2 firmware rev > > > and it does not have the standard SCSI cmds for optical devices. They were > > > introduced in SCSI-2 IIRC. Really a funky piece of hardware ;-) > > > > Yeah, definitely makes me wonder. I wonder how you get the table of > > contents off the thing, since that is the standard CDROM TOC command that > > should work on most any CDROM.. > > 'Most any' appears to be the right term for it ;) I'll experiment a bit > more. Just go a solid system lockup by running a 'dd if=/dev/rcd0a' and > a 'mount /dev/cd1a ...' at the same time. Only ping still works. Hmm. > More testing to do I guess Hmm, interesting. What happens if you just try the DD? Can you break into the debugger when the machine locks up? Ken -- Kenneth Merry ken@plutotech.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-scsi" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199904082026.OAA11726>