From owner-freebsd-current Mon Oct 13 15:52:23 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id PAA00609 for current-outgoing; Mon, 13 Oct 1997 15:52:23 -0700 (PDT) (envelope-from owner-freebsd-current) Received: from sax.sax.de (sax.sax.de [193.175.26.33]) by hub.freebsd.org (8.8.7/8.8.7) with SMTP id PAA00596 for ; Mon, 13 Oct 1997 15:52:17 -0700 (PDT) (envelope-from j@uriah.heep.sax.de) Received: (from uucp@localhost) by sax.sax.de (8.6.12/8.6.12-s1) with UUCP id AAA03267 for current@FreeBSD.ORG; Tue, 14 Oct 1997 00:52:14 +0200 Received: (from j@localhost) by uriah.heep.sax.de (8.8.7/8.8.5) id WAA01453; Mon, 13 Oct 1997 22:49:05 +0200 (MET DST) Message-ID: <19971013224905.XP26919@uriah.heep.sax.de> Date: Mon, 13 Oct 1997 22:49:05 +0200 From: j@uriah.heep.sax.de (J Wunsch) To: current@FreeBSD.ORG Subject: Re: multiple cd drives, how to... References: <19971013112612.HL01030@uriah.heep.sax.de> <199710131131.NAA19129@sos.freebsd.dk> X-Mailer: Mutt 0.60_p2-3,5,8-9 Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Phone: +49-351-2012 669 X-PGP-Fingerprint: DC 47 E6 E4 FF A6 E9 8F 93 21 E0 7D F9 12 D6 4E Reply-To: joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch) In-Reply-To: =?iso-8859-1?Q?=3C199710131131=2ENAA19129=40sos=2Efreebsd=2Edk=3E=3B_fro?= =?iso-8859-1?Q?m_S=F8ren_Schmidt_on_Oct_13=2C_1997_13=3A31=3A40_+0200?= Sender: owner-freebsd-current@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk As Søren Schmidt wrote: (I misunderstood your question before.) > See :), as I understand it, there is no support in the SCSI cd driver > for this, its supposed to be handeled by the "changer" device which > reacts to ioctl commands (can you spell ugly).. I wish it would. The SCSI-2 medium changer interface would have been the cleanest (and _not_ the ugliest) way to handle this. Alas, SCSI vendors went the route to make CD-ROM changer devices look like multiple CD-ROM drives on multiple LUNs. The actual changing is done automatically. This seems to be a bright idea -- until you start using such a beast in a multiuser/multitasking environment. There's no way to lock a medium in the drive (PREVENT ALLOW MEDIUM REMOVAL will only lock the medium inside the entire device), so if you start concurrent accesses to the virtual CD-ROM drives, it simply goes thrashing. It takes 20 seconds to swap a medium, then it reads a block or two, then it swaps for the next medium, then it reads a block or two,... you get the picture. You can't blame the driver for this: it has been told there were multiple drives. Using the changer approach (which is standardized by SCSI-2) would have been _so_ much better, since you get control about when to change the medium. > I like phk's idea (and my inital thought), of the driver allocating > so many minors as the device supports slots, and then let the > driver shuffle the CD's as needed... The cd driver simply allocates new devices for them, they show up as cd0 through cd6 (for a 7-disk changer). -- cheers, J"org joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ -- NIC: JW11-RIPE Never trust an operating system you don't have sources for. ;-)