Am Montag, 20. Januar 2003 23:09 schrieb David Brownell:
> Oliver Neukum wrote:
> > this patch fixes a bug where submitting an sg request could get a task
> > stuck in state D if the first submission fails.
>
> Did you actually observe that?  I strongly suspect not.  Using yield()
> instead of that schedule() bit should be OK (is that what you're saying
> would get "stuck"?), but the rest isn't.

Did you observe this code working?

                        set_current_state (TASK_UNINTERRUPTIBLE);
                        schedule ();
                        break;
Here you schedule with the task state UNINTERRUPTIBLE and
you are not on a waitqueue. You are dead at this point.

> The patch is problematic, since it basically prevents submission of large
> scatterlists from working at all in cases where resources are very tight.
> It's placing an arbitrary and *very small* limit on how long it tries to
> recover from "can't proceed just now, try again later" types of faults.
>
> If there's to be a way to stop retrying, it should NOT be because of
> hitting some arbitrary limit, easily reached on busy systems.  I could
> understand allowing the task to be interrupted (maybe) since then the
> policy is clearly in the hands of someone with appropriate knowledge.

If you know a better way how to determine how often to loop, I'll
implement it. But we cannot loop forever. As for making this interruptible,
it's problematic to have that. The main user of this is storage, which will
have to react with an IO error eventually. You may change the number
of retries, but at some point, you have to give up. Perhaps we should
wait a little in each loop, too, but it doesn't solve the fundamental problem.
You'd have to use a mempool for that.

        Regards
                Oliver



-------------------------------------------------------
This SF.NET email is sponsored by: FREE  SSL Guide from Thawte
are you planning your Web Server Security? Click here to get a FREE
Thawte SSL guide and find the answers to all your  SSL security issues.
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0026en
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to