kopia lustrzana https://gitlab.com/sane-project/website
327 wiersze
12 KiB
HTML
327 wiersze
12 KiB
HTML
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
|
||
|
"http://www.w3.org/TR/REC-html40/loose.dtd">
|
||
|
<HTML>
|
||
|
<HEAD>
|
||
|
<TITLE>sane-devel: SCSI problems with SANE 1.0.5, Linux 2.4.x and doub</TITLE>
|
||
|
<META NAME="Author" CONTENT="Henning Meier-Geinitz (henning@meier-geinitz.de)">
|
||
|
<META NAME="Subject" CONTENT="SCSI problems with SANE 1.0.5, Linux 2.4.x and double buffering">
|
||
|
</HEAD>
|
||
|
<BODY BGCOLOR="#FFFFFF" TEXT="#000000">
|
||
|
<H1>SCSI problems with SANE 1.0.5, Linux 2.4.x and double buffering</H1>
|
||
|
<!-- received="Sat, 7 Jul 2001 14:57:29 +0200" -->
|
||
|
<!-- isoreceived="20010707125729" -->
|
||
|
<!-- sent="Sat, 7 Jul 2001 14:57:29 +0200" -->
|
||
|
<!-- isosent="20010707125729" -->
|
||
|
<!-- name="Henning Meier-Geinitz" -->
|
||
|
<!-- email="henning@meier-geinitz.de" -->
|
||
|
<!-- subject="SCSI problems with SANE 1.0.5, Linux 2.4.x and double buffering" -->
|
||
|
<!-- id="20010707145729.B11412@vortex.swb.de" -->
|
||
|
<STRONG>From:</STRONG> Henning Meier-Geinitz (<A HREF="mailto:henning@meier-geinitz.de?Subject=Re:%20SCSI%20problems%20with%20SANE%201.0.5,%20Linux%202.4.x%20and%20double%20buffering&In-Reply-To=<20010707145729.B11412@vortex.swb.de>"><EM>henning@meier-geinitz.de</EM></A>)<BR>
|
||
|
<STRONG>Date:</STRONG> Sat Jul 07 2001 - 05:57:29 PDT
|
||
|
<P>
|
||
|
<!-- next="start" -->
|
||
|
<LI><STRONG>Next message:</STRONG> <A HREF="0076.html">Henning Meier-Geinitz: "Re: What's the status of sanei-thread?"</A>
|
||
|
<UL>
|
||
|
<LI><STRONG>Previous message:</STRONG> <A HREF="0074.html">PeterMcConnell: "webstar 9636 scanner aka Mustek"</A>
|
||
|
<!-- nextthread="start" -->
|
||
|
<LI><STRONG>Next in thread:</STRONG> <A HREF="0080.html">abel deuring: "Re: SCSI problems with SANE 1.0.5, Linux 2.4.x and double buffering"</A>
|
||
|
<LI><STRONG>Reply:</STRONG> <A HREF="0080.html">abel deuring: "Re: SCSI problems with SANE 1.0.5, Linux 2.4.x and double buffering"</A>
|
||
|
<LI><STRONG>Reply:</STRONG> <A HREF="0092.html">Henning Meier-Geinitz: "Re: SCSI problems with SANE 1.0.5, Linux 2.4.x and double buffering"</A>
|
||
|
<LI><STRONG>Reply:</STRONG> <A HREF="0099.html">Frederik Ramm: "Re: SCSI problems with SANE 1.0.5, Linux 2.4.x and double buffering"</A>
|
||
|
<!-- reply="end" -->
|
||
|
<LI><STRONG>Messages sorted by:</STRONG>
|
||
|
<A HREF="date.html#75">[ date ]</A>
|
||
|
<A HREF="index.html#75">[ thread ]</A>
|
||
|
<A HREF="subject.html#75">[ subject ]</A>
|
||
|
<A HREF="author.html#75">[ author ]</A>
|
||
|
</UL>
|
||
|
<HR NOSHADE><P>
|
||
|
<!-- body="start" -->
|
||
|
<P>
|
||
|
Hi,
|
||
|
<BR>
|
||
|
<P>I got several reports of SCSI problems with Mustek scanners in the
|
||
|
<BR>
|
||
|
last days. I don't think that these are mustek-bugs. The bug reporters
|
||
|
<BR>
|
||
|
provided the following common facts:
|
||
|
<BR>
|
||
|
<P>* Linux 2.4.x
|
||
|
<BR>
|
||
|
* a SCSI controller that has a queue depth of 1 (e.g. Adaptec 1520)
|
||
|
<BR>
|
||
|
* SuSe 7.x (may be coincidence)
|
||
|
<BR>
|
||
|
<P>They tried to scan an image but they only get the first stripe of
|
||
|
<BR>
|
||
|
aprox. 64k that is repeated until the page is completely scanned. The
|
||
|
<BR>
|
||
|
scanner stops after this first stripe. Sometimes the system freezes
|
||
|
<BR>
|
||
|
completely, sometimes there is only an error message and sometimes no
|
||
|
<BR>
|
||
|
error is output at all.
|
||
|
<BR>
|
||
|
<P>I tried to reproduce this bug but couldn't until I did the following:
|
||
|
<BR>
|
||
|
rename /usr/include/scsi/sg.h to something else. After recompile
|
||
|
<BR>
|
||
|
sanei_scsi.c seems to use the kernel headers from /usr/src/linux
|
||
|
<BR>
|
||
|
(which are the right ones for my current kernel 2.4.5). I'm using
|
||
|
<BR>
|
||
|
Debian 2.2.
|
||
|
<BR>
|
||
|
<P>It doesn't happen if I use a SCSI controller with a queue depth of 2
|
||
|
<BR>
|
||
|
or more (e.g. Adaptec 2940) or if I disable double buffering in
|
||
|
<BR>
|
||
|
mustek.c. Double buffering means, that the backend sends two read
|
||
|
<BR>
|
||
|
requests to the scanner before waiting for the first one. So maybe
|
||
|
<BR>
|
||
|
this is a bug in queuing the commands sanei_scsi.c? It works if I use
|
||
|
<BR>
|
||
|
a 2.2 kernel.
|
||
|
<BR>
|
||
|
<P>Some parts of the debug log ans questions about it (color preview with
|
||
|
<BR>
|
||
|
a Paragon 1200SP). Questions/comments are marked with "---". The full
|
||
|
<BR>
|
||
|
logs are available on request.:
|
||
|
<BR>
|
||
|
<P>[mustek] SANE mustek backend version 1.0 build 107 from sane-backends-1.0.5
|
||
|
<BR>
|
||
|
[...]
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi_open: sanei_scsi_max_request_size=131072 bytes
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi_open: SG driver version: 30117
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi_open_extended: using 8192 bytes as SCSI buffer
|
||
|
<BR>
|
||
|
[sanei_scsi] trying to enable low level command queueing
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi_open: Host adapter queue depth: 1
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi_open: SG driver can change buffer size at run time
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi_open: using new SG header structure
|
||
|
<BR>
|
||
|
--- The last line isn't printed if I use /usr/include/scsi/sg.h
|
||
|
<BR>
|
||
|
[...]
|
||
|
<BR>
|
||
|
[mustek] attach: sending INQUIRY
|
||
|
<BR>
|
||
|
[sanei_scsi] scsi_req_enter: entered 0x80f6d88
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi.issue: 0x80f6d88
|
||
|
<BR>
|
||
|
dev_max(currently)=7 max_active_device=1 (origin 1)
|
||
|
<BR>
|
||
|
scsi_dma_free_sectors=48 sg_pool_secs_aval=320 def_reserved_size=32768
|
||
|
<BR>
|
||
|
<EM> >>> device=sg0 scsi0 chan=0 id=6 lun=0 em=0 sg_tablesize=255 excl=1
|
||
|
</EM><BR>
|
||
|
FD(1): timeout=600000ms bufflen=8192 (res)sgat=0 low_dma=0
|
||
|
<BR>
|
||
|
cmd_q=1 f_packid=0 k_orphan=0 closed=0
|
||
|
<BR>
|
||
|
rb>> rcv: id=0 blen=96 dur=10ms sgat=0 op=0x12
|
||
|
<BR>
|
||
|
--- Where does this come from? I can't find it in sanei_scsci.c.
|
||
|
<BR>
|
||
|
[...]
|
||
|
<BR>
|
||
|
[mustek] sane_start
|
||
|
<BR>
|
||
|
[...]
|
||
|
<BR>
|
||
|
[mustek] reader_process: buffer 1: entering read request for 64470 bytes (buffer 1)
|
||
|
<BR>
|
||
|
[...]
|
||
|
<BR>
|
||
|
[mustek] reader_process: buffer 1: entered (line 35 of 995, buffer 1)
|
||
|
<BR>
|
||
|
[mustek] reader_process: buffer 2: entering read request for 64470 bytes (buffer 2)
|
||
|
<BR>
|
||
|
[...]
|
||
|
<BR>
|
||
|
[sanei_scsi] scsi_req_enter: entered 0x81d4150
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi.issue: 0x81d4150
|
||
|
<BR>
|
||
|
[sanei_scsi] scsi_req_enter: queue_used: 1, queue_max: 1
|
||
|
<BR>
|
||
|
[mustek] reader_process: buffer 2: entered (line 70 of 995, buffer 2)
|
||
|
<BR>
|
||
|
[mustek] reader_process: buffer 1: waiting for request to be ready
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi_req_wait: waiting for 0x81b2d58
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi.issue: 0x81b2d58
|
||
|
<BR>
|
||
|
dev_max(currently)=7 max_active_device=1 (origin 1)
|
||
|
<BR>
|
||
|
scsi_dma_free_sectors=48 sg_pool_secs_aval=320 def_reserved_size=32768
|
||
|
<BR>
|
||
|
<EM> >>> device=sg0 scsi0 chan=0 id=6 lun=0 em=0 sg_tablesize=255 excl=1
|
||
|
</EM><BR>
|
||
|
FD(1): timeout=600000ms bufflen=131072 (res)sgat=4 low_dma=0
|
||
|
<BR>
|
||
|
cmd_q=1 f_packid=0 k_orphan=0 closed=0
|
||
|
<BR>
|
||
|
rb>> rcv: id=14 blen=64470 dur=2690ms sgat=2 op=0x08
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi.issue: 0x81d4150
|
||
|
<BR>
|
||
|
dev_max(currently)=7 max_active_device=1 (origin 1)
|
||
|
<BR>
|
||
|
scsi_dma_free_sectors=48 sg_pool_secs_aval=320 def_reserved_size=32768
|
||
|
<BR>
|
||
|
<EM> >>> device=sg0 scsi0 chan=0 id=6 lun=0 em=0 sg_tablesize=255 excl=1
|
||
|
</EM><BR>
|
||
|
FD(1): timeout=600000ms bufflen=131072 (res)sgat=4 low_dma=0
|
||
|
<BR>
|
||
|
cmd_q=1 f_packid=0 k_orphan=0 closed=0
|
||
|
<BR>
|
||
|
rb>> rcv: id=15 blen=64470 dur=0ms sgat=2 op=0x83
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi_req_wait: read 64 bytes
|
||
|
<BR>
|
||
|
--- Why is this only 64 bytes (that's printed for every req_wait even
|
||
|
<BR>
|
||
|
if the buffer is much bigger)?
|
||
|
<BR>
|
||
|
[mustek] reader_process: buffer 1 is ready, wanted 64470, got 64470 bytes
|
||
|
<BR>
|
||
|
[mustek] reader_process: buffer 1: sending 64470 bytes to output_data
|
||
|
<BR>
|
||
|
[...]
|
||
|
<BR>
|
||
|
[mustek] reader_process: buffer 1: entering read request for 64470 bytes (buffer 3)
|
||
|
<BR>
|
||
|
[...]
|
||
|
<BR>
|
||
|
<P>This goes on until the full page is scanned. No error occurs but the
|
||
|
<BR>
|
||
|
resulting image conatines the first buffer over and over again.
|
||
|
<BR>
|
||
|
<P>From a bug-reporter I got a debug log that's a bit different:
|
||
|
<BR>
|
||
|
<P>[...]
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi.issue: 0x80bcef0
|
||
|
<BR>
|
||
|
dev_max(currently)=9 max_active_device=3 (origin 1)
|
||
|
<BR>
|
||
|
scsi_dma_free_sectors=144 sg_pool_secs_aval=320 def_reserved_size=32768
|
||
|
<BR>
|
||
|
<EM> >>> device=sg0 scsi0 chan=0 id=6 lun=0 em=0 sg_tablesize=255 excl=1
|
||
|
</EM><BR>
|
||
|
FD(1): timeout=600000ms bufflen=131072 (res)sgat=4 low_dma=0
|
||
|
<BR>
|
||
|
cmd_q=1 f_packid=0 k_orphan=0 closed=0
|
||
|
<BR>
|
||
|
rb>> act: id=12 blen=44208 t_o/elap=600000/40ms sgat=2 op=0x53
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi_req_wait: read 64 bytes
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi_req_wait: SCSI command complained: Success
|
||
|
<BR>
|
||
|
[sanei_scsi] sense buffer: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
|
||
|
<BR>
|
||
|
[sanei_scsi] target status: 00 host status: 0007 driver status: 0000
|
||
|
<BR>
|
||
|
[mustek] sense_handler: got sense code 00 for fd 7 (arg = null)
|
||
|
<BR>
|
||
|
[...]
|
||
|
<BR>
|
||
|
[mustek] reader_process: buffer 1: waiting for request to be ready
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi_req_wait: waiting for 0x80bcef0
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi.issue: 0x80bcef0
|
||
|
<BR>
|
||
|
dev_max(currently)=9 max_active_device=3 (origin 1)
|
||
|
<BR>
|
||
|
scsi_dma_free_sectors=144 sg_pool_secs_aval=320 def_reserved_size=32768
|
||
|
<BR>
|
||
|
<EM> >>> device=sg0 scsi0 chan=0 id=6 lun=0 em=0 sg_tablesize=255 excl=1
|
||
|
</EM><BR>
|
||
|
FD(1): timeout=600000ms bufflen=131072 (res)sgat=4 low_dma=0
|
||
|
<BR>
|
||
|
cmd_q=1 f_packid=0 k_orphan=0 closed=0
|
||
|
<BR>
|
||
|
rb>> rcv: id=12 blen=44208 dur=260ms sgat=2 op=0x53
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi.issue: 0x80e3710
|
||
|
<BR>
|
||
|
dev_max(currently)=9 max_active_device=3 (origin 1)
|
||
|
<BR>
|
||
|
scsi_dma_free_sectors=144 sg_pool_secs_aval=320 def_reserved_size=32768
|
||
|
<BR>
|
||
|
<EM> >>> device=sg0 scsi0 chan=0 id=6 lun=0 em=0 sg_tablesize=255 excl=1
|
||
|
</EM><BR>
|
||
|
FD(1): timeout=600000ms bufflen=131072 (res)sgat=4 low_dma=0
|
||
|
<BR>
|
||
|
cmd_q=1 f_packid=0 k_orphan=0 closed=0
|
||
|
<BR>
|
||
|
rb>> act: id=13 blen=44208 t_o/elap=600000/30ms sgat=2 op=0x53
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi_req_wait: read 64 bytes
|
||
|
<BR>
|
||
|
[sanei_scsi] sanei_scsi_req_wait: SCSI command complained: Success
|
||
|
<BR>
|
||
|
[sanei_scsi] sense buffer: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
|
||
|
<BR>
|
||
|
[sanei_scsi] target status: 00 host status: 0001 driver status: 0000
|
||
|
<BR>
|
||
|
[mustek] reader_process: failed to read data, status: Device busy, buffer: 1
|
||
|
<BR>
|
||
|
[...]
|
||
|
<BR>
|
||
|
<P>--- What's this funny error message?
|
||
|
<BR>
|
||
|
<P>Any ideas?
|
||
|
<BR>
|
||
|
<P>Bye,
|
||
|
<BR>
|
||
|
Henning
|
||
|
<BR>
|
||
|
<P><P><PRE>
|
||
|
--
|
||
|
Source code, list archive, and docs: <A HREF="http://www.mostang.com/sane/">http://www.mostang.com/sane/</A>
|
||
|
To unsubscribe: echo unsubscribe sane-devel | mail <A HREF="mailto:majordomo@mostang.com?Subject=Re:%20SCSI%20problems%20with%20SANE%201.0.5,%20Linux%202.4.x%20and%20double%20buffering&In-Reply-To=<20010707145729.B11412@vortex.swb.de>">majordomo@mostang.com</A>
|
||
|
</PRE>
|
||
|
<P><!-- body="end" -->
|
||
|
<HR NOSHADE>
|
||
|
<UL>
|
||
|
<!-- next="start" -->
|
||
|
<LI><STRONG>Next message:</STRONG> <A HREF="0076.html">Henning Meier-Geinitz: "Re: What's the status of sanei-thread?"</A>
|
||
|
<LI><STRONG>Previous message:</STRONG> <A HREF="0074.html">PeterMcConnell: "webstar 9636 scanner aka Mustek"</A>
|
||
|
<!-- nextthread="start" -->
|
||
|
<LI><STRONG>Next in thread:</STRONG> <A HREF="0080.html">abel deuring: "Re: SCSI problems with SANE 1.0.5, Linux 2.4.x and double buffering"</A>
|
||
|
<LI><STRONG>Reply:</STRONG> <A HREF="0080.html">abel deuring: "Re: SCSI problems with SANE 1.0.5, Linux 2.4.x and double buffering"</A>
|
||
|
<LI><STRONG>Reply:</STRONG> <A HREF="0092.html">Henning Meier-Geinitz: "Re: SCSI problems with SANE 1.0.5, Linux 2.4.x and double buffering"</A>
|
||
|
<LI><STRONG>Reply:</STRONG> <A HREF="0099.html">Frederik Ramm: "Re: SCSI problems with SANE 1.0.5, Linux 2.4.x and double buffering"</A>
|
||
|
<!-- reply="end" -->
|
||
|
<LI><STRONG>Messages sorted by:</STRONG>
|
||
|
<A HREF="date.html#75">[ date ]</A>
|
||
|
<A HREF="index.html#75">[ thread ]</A>
|
||
|
<A HREF="subject.html#75">[ subject ]</A>
|
||
|
<A HREF="author.html#75">[ author ]</A>
|
||
|
</UL>
|
||
|
<!-- trailer="footer" -->
|
||
|
<HR NOSHADE>
|
||
|
<P>
|
||
|
<SMALL>
|
||
|
<EM>
|
||
|
This archive was generated by <A HREF="http://www.hypermail.org/">hypermail 2b29</A>
|
||
|
: <EM>Sat Jul 07 2001 - 05:49:28 PDT</EM>
|
||
|
</EM>
|
||
|
</SMALL>
|
||
|
</BODY>
|
||
|
</HTML>
|