From owner-freebsd-bugs Sat Aug 14 10:31:36 1999 Delivered-To: freebsd-bugs@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id 1A6BB14E5A for ; Sat, 14 Aug 1999 10:31:33 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id KAA36476; Sat, 14 Aug 1999 10:30:00 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: by hub.freebsd.org (Postfix, from userid 32767) id 3406D14BE5; Sat, 14 Aug 1999 10:27:46 -0700 (PDT) Message-Id: <19990814172746.3406D14BE5@hub.freebsd.org> Date: Sat, 14 Aug 1999 10:27:46 -0700 (PDT) From: tobi@bland.fido.de To: freebsd-gnats-submit@freebsd.org X-Send-Pr-Version: www-1.0 Subject: kern/13141: Multiple LUN support in NCR driver is broken. Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 13141 >Category: kern >Synopsis: Multiple LUN support in NCR driver is broken. >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sat Aug 14 10:30:00 PDT 1999 >Closed-Date: >Last-Modified: >Originator: Tobias Ernst >Release: 3.2-STABLE >Organization: University of Stuttgart >Environment: FreeBSD romulus.bland.fido.de 3.2-STABLE FreeBSD 3.2-STABLE #1: Fri Jul 16 13:47:35 CEST 1999 root@romulus.bland.fido.de:/slices/nobackup/32src/sys/compile/ROMULUS i386 >Description: I am using an Asus SC-200 scsi card with NCR 810 chip, which is probed as follows: /kernel: ncr0: rev 0x12 int a irq 12 on pci0.14.0 I have a Pioneer DRM 624X CD changer connected to this controller. The changer presents 6 multiple LUNS, which are recognise as cd0 until cd5 and can be independently used, in theory. Here is how the Pioneer is probed (note that for this example, it was connected to an Adaptec controller instead): /kernel: cd0 at aha0 bus 0 target 6 lun 0 /kernel: cd0: Removable CD-ROM SCSI-2 device /kernel: cd1 at aha0 bus 0 target 6 lun 1 /kernel: cd1: Removable CD-ROM SCSI-2 device [...] The problem is that the NCR support for multiple LUNs is severly broken. As soon as I try to access any of the cd devices, I get messages about "CCB already dequeued", and am even able to bring the system to a complete halt, e.g. if trying to access two devices simultaneously. On the one hand, if I connect the CD changer to an Adaptec 1542, everything works expected: No messages about CCBs, no kernel panics, no system halts, even if two CDs are accessed simultaneously. Also, if I connect the CD changer to the Asus SC200, but use a different operating system (e.g.: OS/2), everything works as suspected. So I conclude it must be a problem in the FreeBSD NCR driver. >How-To-Repeat: Connect a multiple LUN device (a CD changer if possible) to an NCR 810 - based controller and try to access the first LUN (by mounting a CD from it), and then the second (by mounting another CD without unmounting the first). This should already trigger the bug, but if not, just try to access the second CD while copying files from the first CD to hard disk. (The expected result is that at least one of the two processes terminates with an error code). >Fix: Nearly same problem existed in FreeBSD 2.2.5. At that time, I reported it informally to the owner of the ncr driver code at that time. I never got a response, but after I did an upgrade to 2.2.7, the problem was solved. It worked until I upgraded to 3.x (in my case, 3.1-RELEASE). Probably, the fixes that had been applied to the NCR driver between 2.2.5 and 2.2.7 have not been migrated up to the 3.x branch. Maybe this helps in finding the problem. >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message