]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Modify the changer driver so it can handle (hopefully!) changers that need
authorKenneth D. Merry <ken@FreeBSD.org>
Fri, 2 Oct 1998 05:25:49 +0000 (05:25 +0000)
committerKenneth D. Merry <ken@FreeBSD.org>
Fri, 2 Oct 1998 05:25:49 +0000 (05:25 +0000)
commit696db22238a0d7fd09dad2981476323ed1dd3f10
treeebf838e4663aefc64c568fb481ed63cc4c6391f7
parent9dfb44710eb19263e2d3ce12983467b828155aa0
Modify the changer driver so it can handle (hopefully!) changers that need
block descriptors enabled on mode sense commands.

Basically, we try sending a mode sense with block descriptors disabled (the
previous default), and if it fails, we try sending the mode sense with
block descriptors enabled.  If that works, we note that in a runtime quirk
entry, so we don't bother disabling block descriptors again for the device.

This problem was first reported by Chris Jones <cjones@honors.montana.edu>
on one of the NetBSD lists, but I'd imagine that some FreeBSD users would
have run into it eventually as well, since our changer driver is derived
form the NetBSD changer driver.

Also, change some of the probe logic so that we do the right thing in the
case of a failure to attach.

Fix a memory leak in chgetparams().

Add a couple of inline helper functions to scsi_all.h to correctly return
the start of a mode page.

NetBSD PR: kern/6214
Reviewed by: gibbs
sys/cam/scsi/scsi_all.h
sys/cam/scsi/scsi_ch.c