From owner-FreeBSD-users-jp@jp.freebsd.org  Wed Dec 10 00:19:26 1997
Received: by jaz.jp.freebsd.org (8.8.8+3.0Wbeta7/8.7.3) id AAA05359
	Wed, 10 Dec 1997 00:19:26 +0900 (JST)
Received: by jaz.jp.freebsd.org (8.8.8+3.0Wbeta7/8.7.3) with SMTP id AAA05353
	for <FreeBSD-users-jp@jp.freebsd.org>; Wed, 10 Dec 1997 00:19:24 +0900 (JST)
From: fujiwara@rcac.tdi.co.jp
Received: (qmail 26882 invoked from network); 9 Dec 1997 15:19:22 -0000
Received: from localhost (fujiwara@127.0.0.1)
  by localhost with SMTP; 9 Dec 1997 15:19:22 -0000
To: FreeBSD-users-jp@jp.freebsd.org
X-Mailer: Mew version 1.90 on Emacs 19.28  / Mule 2.3 (SUETSUMUHANA)
Mime-Version: 1.0
Content-Type: Multipart/Mixed;
	boundary="--Next_Part(Wed_Dec_10_00:19:04_1997_731)--"
Content-Transfer-Encoding: 7bit
Message-Id: <19971210001921U.fujiwara@rcac.tdi.co.jp>
Date: Wed, 10 Dec 1997 00:19:21 +0900 (JST)
X-Dispatcher: imput version 970918
Lines: 84
Reply-To: FreeBSD-users-jp@jp.freebsd.org
Precedence: bulk
X-Distribute: distribute [version 2.1 (Alpha) patchlevel=24]
X-Sequence: FreeBSD-users-jp 22045
Subject: [FreeBSD-users-jp 22045] ATAPI CD-ROM changer on 2.2.5R
Errors-To: owner-FreeBSD-users-jp@jp.freebsd.org
Sender: owner-FreeBSD-users-jp@jp.freebsd.org

----Next_Part(Wed_Dec_10_00:19:04_1997_731)--
Content-Type: Text/Plain; charset=iso-2022-jp
Content-Transfer-Encoding: 7bit

FreeBSD-current$B$K(BATAPI CD-ROM Changer$B$N(Bcode$B$,F~$C$?$N$r8+$D$1$?$N$G(B
2.2.5R$B$K;}$C$F$-$F;H$C$F$_$^$7$?!#(B

ftp.cdrom.com$B$N(B/pub/FreeBSD/FreeBSD-current/src$B$+$i!"(B

sys/i386/isa/atapi.h
sys/i386/isa/wcd.c

$B$r$b$C$F$-$F!"(B

$B0J2<$N(Bpatch$B$r$"$F$F(Bkernel$B$r:n$jD>$7$?$H$3$m!"G'<1$7!";H$($^$7$?!#(B
wcd1,wcd2,wcd3,wcd4, wcd5,...$B$r:n$i$J$$$H$$$1$^$;$s$,!#(B

# code$B$r<P$aFI$_$7$?$@$1$J$N$G!"L5J]>Z!#(B

--
						$BF#86OBE5(B
						Kazunori Fujiwara


----Next_Part(Wed_Dec_10_00:19:04_1997_731)--
Content-Type: Text/Plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

--- wcd.c.current.971202	Tue Dec  2 23:29:20 1997
+++ wcd.c	Tue Dec  9 23:23:22 1997
@@ -305,7 +305,7 @@
 	if (!ptr)
 		return NULL;
 	bzero(ptr, sizeof(struct wcd));
-	bufq_init(&ptr->buf_queue);
+/*	bufq_init(&ptr->buf_queue);	*/
 	ptr->ata = ata;
 	ptr->unit = unit;
 	ptr->lun = lun;
@@ -613,7 +613,7 @@
 	x = splbio();
 
 	/* Place it in the queue of disk activities for this disk. */
-	bufqdisksort (&t->buf_queue, bp);
+	tqdisksort (&t->buf_queue, bp);
 
 	/* Tell the device to get going on the transfer if it's
 	 * not doing anything, otherwise just wait for completion. */
@@ -631,7 +631,7 @@
  */
 static void wcd_start (struct wcd *t)
 {
-	struct buf *bp = bufq_first(&t->buf_queue);
+	struct buf *bp = TAILQ_FIRST(&t->buf_queue);
 	u_long blkno, nblk;
 
 	/* See if there is a buf to do and we are not already doing one. */
@@ -639,7 +639,7 @@
 		return;
 
 	/* Unqueue the request. */
-	bufq_remove(&t->buf_queue, bp);
+	TAILQ_REMOVE(&t->buf_queue, bp, b_act);
 
 	/* Should reject all queued entries if media have changed. */
 	if (t->flags & F_MEDIA_CHANGED) {
@@ -1365,13 +1365,13 @@
 	/* XXX Poking around in the LKM internals like this is bad.
 	 */
 	/* Register the cdevsw entry. */
-	lkmtp->private.lkm_dev = & MOD_PRIVATE(rwcd);
+	lkmtp->private.lkm_dev = &rwcd_module;
 	err = lkmdispatch (lkmtp, cmd);
 	if (err)
 		return err;
 
 	/* Register the bdevsw entry. */
-	lkmtp->private.lkm_dev = & MOD_PRIVATE(wcd);
+	lkmtp->private.lkm_dev = &wcd_module;
 	return lkmdispatch (lkmtp, cmd);
 }
 #endif /* WCD_MODULE */

----Next_Part(Wed_Dec_10_00:19:04_1997_731)----
