From owner-freebsd-hackers Mon Apr 28 01:40:24 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id BAA01567 for hackers-outgoing; Mon, 28 Apr 1997 01:40:24 -0700 (PDT) Received: from labinfo.iet.unipi.it (labinfo.iet.unipi.it [131.114.9.5]) by hub.freebsd.org (8.8.5/8.8.5) with SMTP id BAA01551 for ; Mon, 28 Apr 1997 01:40:18 -0700 (PDT) Received: from localhost (luigi@localhost) by labinfo.iet.unipi.it (8.6.5/8.6.5) id JAA29907; Mon, 28 Apr 1997 09:56:29 +0200 From: Luigi Rizzo Message-Id: <199704280756.JAA29907@labinfo.iet.unipi.it> Subject: DMA overruns ? To: hackers@freebsd.org Date: Mon, 28 Apr 1997 09:56:28 +0200 (MET DST) X-Mailer: ELM [version 2.4 PL23] Content-Type: text Sender: owner-hackers@freebsd.org X-Loop: FreeBSD.org Precedence: bulk Hi, for some unkonwn reason, my "asc" driver for a hand scanner occasionally loses some byte when transferring data from a color scanhead. The device is an ISA device, uses a 8-bit DMA channel, and probably does not have much buffering. Data are saved one scanline at a time, corresponding to about 2500 bytes/line, and the overruns are rare (say 1 lost byte every 20-30 lines on average when I save to disk). The overruns seem to occur almost independently from the speed the head is moving (provided it is not too fast...), both on a 486/66 and on a P5/133, even when saving to a mfs partition (and I checked, the system was not paging at the moment). The driver under Windows 3.1 does not seem to have this problem. Now I am wondering: is it possible that there is some long, uninterruptible operation which makes the bus unavailable for enough time to cause the overrun ? Although I am prepared to try toggling random bits in the driver (the controller chip is undocumented :( ) to see if the problem goes away, I'd like to understand what could be the problem. Thanks Luigi -----------------------------+-------------------------------------- Luigi Rizzo | Dip. di Ingegneria dell'Informazione email: luigi@iet.unipi.it | Universita' di Pisa tel: +39-50-568533 | via Diotisalvi 2, 56126 PISA (Italy) fax: +39-50-568522 | http://www.iet.unipi.it/~luigi/ _____________________________|______________________________________