From mboxrd@z Thu Jan 1 00:00:00 1970 From: rakesh rakesh Subject: Re: [PATCH 2.5.17] Making SCSI not copy the request structure Date: Fri, 24 May 2002 01:34:27 -0700 (PDT) Sender: linux-scsi-owner@vger.kernel.org Message-ID: <20020524083427.4608.qmail@web11005.mail.yahoo.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: In-Reply-To: List-Id: linux-scsi@vger.kernel.org To: Aron Zeh Cc: Doug Ledford , Alan Cox , patman@beaverton.ibm.com, James Bottomley , linux-scsi@vger.kernel.org But the whole hypothesis is that at any point of time mid level should be able to queue at least one command to low level driver.Reference to doc by Eric at www.andante.org --- Aron Zeh wrote: > > > James, > > I think we are talking about two different things. > If I am not mistaken, __scsi_insert_special is only > called for character > devices or ioctl (at least that is what it states in > the description). > My problem occurs during normal IO to a disk. I > believe it is something of > this sort: > scsi_dispatch_command is called, host->can_queue is > 4096 so the if > statement is true. > Then, the low-level driver's queuecommand returns > with FAILED. The command > is put into the mlqueue to be resent when a command > completes. > Due to the design of the zSeries FCP adapter, it is > however possible that > temporarily, no command can be accepted at all. > Thus it is possible for queuecommand to fail on the > one and only active > command, which will be put into the mlqueue. > There it will sit, waiting for the return of an > outstanding command, but > there are non. Hence the system will hang. > > I would think, that your problem only appears when > using ioctls (e.g. > fdisk) or going out to character device (st, sg). Am > I correct or am I > missing something? > Aron > > > Alas, there does not seem to be a timeout handler > to restart IO when > > queuecommand returned non 0. The only way to > retrigger IO seems to be > > a completion of an outstanding command. I have > seen a lot of hangs in > > the FCP driver I am contributing to because of > this. We finally > > decided never to let queuecommand fail and queue > failed requests > > internally while there might still be a chance to > send them. This is > > not too nice though, so it would probably be a > good idea to use a > > timeout as an alternative trigger to resend > commands in the mlqueue. > > Maybe a function to be called by the low-level > driver would also be an > > option. > > I've seen it too occasionally, but I can't reproduce > it consistently > enough. > I think the culprit may be our use of > _elv_add_request with a no-plug > argument. Can you just change the last argument > from 0 to 1 and see if > this > helps (in scsi_lib.c:__scsi_insert_special at about > line 90)? > > James > > > - > To unsubscribe from this list: send the line > "unsubscribe linux-scsi" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at > http://vger.kernel.org/majordomo-info.html > > > > > - > To unsubscribe from this list: send the line > "unsubscribe linux-scsi" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html __________________________________________________ Do You Yahoo!? LAUNCH - Your Yahoo! Music Experience http://launch.yahoo.com