9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: erik quanstrom <quanstro@quanstro.net>
To: 9fans@9fans.net
Subject: Re: [9fans] new usb stack and implicit timeouts
Date: Sun, 19 Jul 2009 09:40:33 -0400	[thread overview]
Message-ID: <fe321bcc50c2892eb6fa513c8063792f@quanstro.net> (raw)
In-Reply-To: <1381313165a5f22aeb8498f958cd7513@hamnavoe.com>

On Sun Jul 19 07:53:33 EDT 2009, 9fans@hamnavoe.com wrote:
> > I think it's better to remove the timeout from bulk endpoints (perhaps by
> > making it optional)
>
> There's already a general way to time out any read/write operation
> alarm() and notify().  Why add a special case option for one particular
> type of file?  I would say just remove it.

i'm confliced on this one.  i want to agree with you, but have
recient memory of uncooperative devices.  and i would hate
to limit the functionality of usb because we're trying to
make things too simple.

i'm not up-to-speed on usb.  aren't there device types
that take timeouts in their requests?  isn't it easier to set
up time timeout at the beginning?  are there devices that
if given a timeout will give their best available data when
the timeout expires?

sd doesn't deal with this problem.  for example, currently most
of the sd devices (orion is an exception) are uninterruptable.
and you get whatever timeout you get.

the sticky bit is that scsi and ata devices implement timeouts
on the devices.  these might not always be appropriate and
you can't depend on anything.  i have drives that vary from
53000s default timeouts to 2s default r/w timeouts.  if you need
a longer timeout than the disk or driver wants, you can't
specify that with an alarm(2).  and if you want a shorter one,
aborting commands can take several seconds with sata devices.

- erik



  parent reply	other threads:[~2009-07-19 13:40 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-07-19  7:16 cinap_lenrek
2009-07-19  7:21 ` Bruce Ellis
2009-07-19  7:54   ` cinap_lenrek
2009-07-19  9:07     ` Francisco J Ballesteros
2009-07-19 11:05       ` Richard Miller
2009-07-19 11:30         ` Francisco J Ballesteros
2009-07-19 11:51           ` Richard Miller
2009-07-19 11:56             ` Francisco J Ballesteros
2009-07-19 13:40             ` erik quanstrom [this message]
2009-07-19 13:53               ` erik quanstrom
2009-07-19 14:03               ` Richard Miller
2009-07-19 14:32                 ` erik quanstrom
2009-07-19 15:14                   ` Francisco J Ballesteros
2009-07-19 15:46                     ` cinap_lenrek
2009-07-19 15:58                       ` Francisco J Ballesteros
2009-07-20  7:12                         ` Gorka Guardiola
2009-07-20 15:07                           ` Dan Cross
2009-07-20 16:25                             ` Francisco J Ballesteros
2009-07-20 18:10                           ` Lyndon Nerenberg
2009-07-20 19:51                             ` Dan Cross
2009-07-21  8:51                               ` Francisco J Ballesteros
2009-07-19 15:36                   ` Richard Miller
2009-07-19 11:41       ` Charles Forsyth

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=fe321bcc50c2892eb6fa513c8063792f@quanstro.net \
    --to=quanstro@quanstro.net \
    --cc=9fans@9fans.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).