kopia lustrzana https://gitlab.com/sane-project/website
138 wiersze
4.9 KiB
HTML
138 wiersze
4.9 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: RE: Problem in sanei_scsi.c</TITLE>
|
|
<META NAME="Author" CONTENT="Simon Munton (simon@munton.demon.co.uk)">
|
|
<META NAME="Subject" CONTENT="RE: Problem in sanei_scsi.c">
|
|
</HEAD>
|
|
<BODY BGCOLOR="#FFFFFF" TEXT="#000000">
|
|
<H1>RE: Problem in sanei_scsi.c</H1>
|
|
<!-- received="Tue Aug 22 14:08:28 2000" -->
|
|
<!-- isoreceived="20000822210828" -->
|
|
<!-- sent="Tue, 22 Aug 2000 22:17:11 +0100" -->
|
|
<!-- isosent="20000822211711" -->
|
|
<!-- name="Simon Munton" -->
|
|
<!-- email="simon@munton.demon.co.uk" -->
|
|
<!-- subject="RE: Problem in sanei_scsi.c" -->
|
|
<!-- id="002b01c00c7e$6b5acfa0$7a53dec2@simon" -->
|
|
<!-- inreplyto="Problem in sanei_scsi.c" -->
|
|
<STRONG>From:</STRONG> Simon Munton (<A HREF="mailto:simon@munton.demon.co.uk?Subject=RE:%20Problem%20in%20sanei_scsi.c&In-Reply-To=<002b01c00c7e$6b5acfa0$7a53dec2@simon>"><EM>simon@munton.demon.co.uk</EM></A>)<BR>
|
|
<STRONG>Date:</STRONG> Tue Aug 22 2000 - 14:17:11 PDT
|
|
<P>
|
|
<!-- next="start" -->
|
|
<LI><STRONG>Next message:</STRONG> <A HREF="0198.html">Stens, Ralph: "AW: AHA1505 on Linux, was Re: Agfa SnapScan 1236S"</A>
|
|
<UL>
|
|
<LI><STRONG>Previous message:</STRONG> <A HREF="0196.html">Oliver Schwartz: "Re: SnapScan Backend"</A>
|
|
<!-- nextthread="start" -->
|
|
<LI><STRONG>Next in thread:</STRONG> <A HREF="0204.html">abel deuring: "Re: Problem in sanei_scsi.c"</A>
|
|
<LI><STRONG>Reply:</STRONG> <A HREF="0204.html">abel deuring: "Re: Problem in sanei_scsi.c"</A>
|
|
<LI><STRONG>Reply:</STRONG> <A HREF="0210.html">Thomas Haberland: "Mustek SP12000pro Problem"</A>
|
|
<!-- reply="end" -->
|
|
<LI><STRONG>Messages sorted by:</STRONG>
|
|
<A HREF="date.html#197">[ date ]</A>
|
|
<A HREF="index.html#197">[ thread ]</A>
|
|
<A HREF="subject.html#197">[ subject ]</A>
|
|
<A HREF="author.html#197">[ author ]</A>
|
|
</UL>
|
|
<HR NOSHADE><P>
|
|
<!-- body="start" -->
|
|
<P>
|
|
I reported this problem back in May, and Abel Deuring applied my patch to
|
|
<BR>
|
|
CVS - but I've just noticed that it isn't in 1.0.3!
|
|
<BR>
|
|
<P>Simon Munton wrote:
|
|
<BR>
|
|
<EM>>
|
|
</EM><BR>
|
|
<EM>> Hi,
|
|
</EM><BR>
|
|
<EM>>
|
|
</EM><BR>
|
|
<EM>> I've found a problem in the issue() function in sanei_scsi.c, that results
|
|
</EM><BR>
|
|
<EM>> in the queue in sg filling up, and prevents any more scsi commands being
|
|
</EM><BR>
|
|
<EM>> issued until the device is closed.
|
|
</EM><BR>
|
|
<EM>>
|
|
</EM><BR>
|
|
<EM>> There is a test on line 1690 which can erroneously try to reissue a scsi
|
|
</EM><BR>
|
|
<EM>> command:
|
|
</EM><BR>
|
|
<EM>> if (rp == fdp->sane_qhead && errno == EAGAIN)
|
|
</EM><BR>
|
|
<EM>>
|
|
</EM><BR>
|
|
<EM>> The first time through the enclosing while loop, rp == fdp->sane_qhead.
|
|
</EM><BR>
|
|
But
|
|
<BR>
|
|
<EM>> if the write() call issuing the command was successful, errno is left
|
|
</EM><BR>
|
|
<EM>> unchanged, and if errno happens to contain EAGAIN, then the command is
|
|
</EM><BR>
|
|
<EM>> issued again, and again... until the command queue in sg is full.
|
|
</EM><BR>
|
|
<P>Anyway, here's a diff against 1.0.3:
|
|
<BR>
|
|
<P>--- sanei_scsi.c.orig Sat Aug 12 15:54:15 2000
|
|
<BR>
|
|
+++ sanei_scsi.c Tue Aug 22 22:00:43 2000
|
|
<BR>
|
|
@@ -1644,6 +1644,7 @@
|
|
<BR>
|
|
retries = 20;
|
|
<BR>
|
|
while (retries)
|
|
<BR>
|
|
{
|
|
<BR>
|
|
+ errno = 0;
|
|
<BR>
|
|
#ifdef SG_IO
|
|
<BR>
|
|
if (sg_version < 30000)
|
|
<BR>
|
|
{
|
|
<BR>
|
|
<P><P><P>Regards
|
|
<BR>
|
|
<P>Simon Munton
|
|
<BR>
|
|
<P><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:%20Problem%20in%20sanei_scsi.c&In-Reply-To=<002b01c00c7e$6b5acfa0$7a53dec2@simon>">majordomo@mostang.com</A>
|
|
</PRE>
|
|
<P><!-- body="end" -->
|
|
<HR NOSHADE>
|
|
<UL>
|
|
<!-- next="start" -->
|
|
<LI><STRONG>Next message:</STRONG> <A HREF="0198.html">Stens, Ralph: "AW: AHA1505 on Linux, was Re: Agfa SnapScan 1236S"</A>
|
|
<LI><STRONG>Previous message:</STRONG> <A HREF="0196.html">Oliver Schwartz: "Re: SnapScan Backend"</A>
|
|
<!-- nextthread="start" -->
|
|
<LI><STRONG>Next in thread:</STRONG> <A HREF="0204.html">abel deuring: "Re: Problem in sanei_scsi.c"</A>
|
|
<LI><STRONG>Reply:</STRONG> <A HREF="0204.html">abel deuring: "Re: Problem in sanei_scsi.c"</A>
|
|
<LI><STRONG>Reply:</STRONG> <A HREF="0210.html">Thomas Haberland: "Mustek SP12000pro Problem"</A>
|
|
<!-- reply="end" -->
|
|
<LI><STRONG>Messages sorted by:</STRONG>
|
|
<A HREF="date.html#197">[ date ]</A>
|
|
<A HREF="index.html#197">[ thread ]</A>
|
|
<A HREF="subject.html#197">[ subject ]</A>
|
|
<A HREF="author.html#197">[ 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>Tue Aug 22 2000 - 14:11:01 PDT</EM>
|
|
</EM>
|
|
</SMALL>
|
|
</BODY>
|
|
</HTML>
|