From owner-freebsd-fs Wed Jul 10 01:27:42 1996 Return-Path: owner-fs Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id BAA21545 for fs-outgoing; Wed, 10 Jul 1996 01:27:42 -0700 (PDT) Received: from soleil.uvsq.fr (soleil.uvsq.fr [193.51.24.1]) by freefall.freebsd.org (8.7.5/8.7.3) with ESMTP id BAA21527; Wed, 10 Jul 1996 01:27:31 -0700 (PDT) Received: from guillotin.prism.uvsq.fr (guillotin.prism.uvsq.fr [193.51.25.1]) by soleil.uvsq.fr (8.7.5/jtpda-5.2) with ESMTP id KAA17976 ; Wed, 10 Jul 1996 10:27:28 +0200 (METDST) Received: from angrand.prism.uvsq.fr (angrand.prism.uvsq.fr [193.51.25.85]) by guillotin.prism.uvsq.fr (8.7.5/jtpda-5.2) with ESMTP id KAA00273 ; Wed, 10 Jul 1996 10:27:27 +0200 (MET DST) Received: from (son@localhost) by angrand.prism.uvsq.fr (8.7.5/jtpda-5.2) id LAA02630 ; Wed, 10 Jul 1996 11:30:07 +0200 (MET DST) Date: Wed, 10 Jul 1996 11:30:07 +0200 (MET DST) Message-Id: <199607100930.LAA02630@angrand.prism.uvsq.fr> From: Nicolas Souchu To: freebsd-fs@freebsd.org CC: freebsd-scsi@freebsd.org Subject: msdosfs and scsi Sender: owner-fs@freebsd.org X-Loop: FreeBSD.org Precedence: bulk I've developed a polling driver for an scsi drive ZIP 100 drive connected to the parallel port. http://www.prism.uvsq.fr/~son/ppa3.html Here is my question/problem: When polling, the system load is horrible... then I want to insert some tsleep() in the driver. In fact, when data is not available, the process which runs into the driver is scheduled with : s = splbio(); tsleep(..., PRIBIO, "mywait", 1); splx (s); BUT: doing this leads 2 concurent processes to a deadlock. $ mount -t msdos /dev/sd0s4 /zip $ time dd if=/dev/zero of=/zip/file bs=8192 count=512 & $ ls -l /zip dd is waiting on channel "getblk", ls is waiting on channel "msdhgt". Debugging the driver shows that dd is scheduled and ls starts reading data from the disk. But then everythings stop. Should the driver be atomic until returning SUCCESSFULLY_QUEUED ? Why ? Why not ? I may get more info. if you need... nicolas -- Nicolas.Souchu@prism.uvsq.fr Laboratoire PRiSM - Versailles, FRANCE