From owner-freebsd-hackers Fri Jul 18 09:48:52 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id JAA02502 for hackers-outgoing; Fri, 18 Jul 1997 09:48:52 -0700 (PDT) Received: from bmccane.uit.net (bmccane.uit.net [208.129.189.48]) by hub.freebsd.org (8.8.5/8.8.5) with ESMTP id JAA02413 for ; Fri, 18 Jul 1997 09:47:32 -0700 (PDT) Received: from bmccane.uit.net (localhost.mccane.com [127.0.0.1]) by bmccane.uit.net (8.8.5/8.8.5) with ESMTP id LAA17049 for ; Fri, 18 Jul 1997 11:42:18 -0500 (CDT) Message-Id: <199707181642.LAA17049@bmccane.uit.net> X-Mailer: exmh version 2.0gamma 1/27/96 To: hackers@FreeBSD.Org Subject: Strange SCSI problem Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Fri, 18 Jul 1997 11:42:18 -0500 From: Wm Brian McCane Sender: owner-hackers@FreeBSD.Org X-Loop: FreeBSD.org Precedence: bulk Howdy, I have built `gimp' on my system, and also have built `sane'. Sane is a scanner interface program that directly accesses the SCSI `uk0' device to get data from the scanner. Anyway, to make a long story short, when I try to use `sane', it doesn't get any data from the scanner. The `scsireq_enter' returns a success status, and that there were 96 bytes read, but the buffer contains the data that was in it when the function was called. To experiment with this, I used the `scsi' command: scsi -f /dev/uk0 -c "12 0 0 0 60 0" -i 96 "i4 i4 i4 i4 i4 i4 i4 i4" It reports 96 bytes read, but the buffer contains all 0's, because the `scsi' command bzero's the buffer before calling the `scsireq_enter' function. I have looked at the kernel code, and I can't find the problem, but I assume that the data is not being copied into user space from kernel space. Any ideas? brian