All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@osdl.org>
To: Russell King <rmk+lkml@arm.linux.org.uk>
Cc: linux-kernel@vger.kernel.org
Subject: Re: 2.6.5-rc2-mm5
Date: Mon, 29 Mar 2004 02:49:59 -0800	[thread overview]
Message-ID: <20040329024959.34c9b77e.akpm@osdl.org> (raw)
In-Reply-To: <20040329113321.A23135@flint.arm.linux.org.uk>

Russell King <rmk+lkml@arm.linux.org.uk> wrote:
>
> On Mon, Mar 29, 2004 at 02:25:56AM -0800, Andrew Morton wrote:
> > > and it is completely valid for ->close to be called while
> > > another thread is in ->open.  In fact, it's desirable since ->open may
> > > be waiting for the DCD line from a modem to activate, while there may
> > > be a simultaneous O_NONBLOCK open/ioctl/close from stty.
> > 
> > ->open is not called under tty_sem.  With this change, ->close is called
> > under tty_sem.
> > 
> > Are ->close implementations likely to block on hardware events?
> 
> Historically they have blocked in a well defined manner - eg when
> dropping the DTR signal for a specified minimum time period.
> 
> They can also block until the data awaiting transmission has been
> sent, which by default has a 30 second timeout, or may be configured
> to be "until sent".  Of course, if CTS is deasserted, we will wait
> until the timeout.

I suspect such drivers have always had a barndoor-sized hole in them, if
someone tries to open the thing while ->close is sleeping.

I'll take another look at the darn thing tomorrrow.


  reply	other threads:[~2004-03-29 10:50 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-03-29  9:45 2.6.5-rc2-mm5 Andrew Morton
2004-03-29  9:57 ` 2.6.5-rc2-mm5 Russell King
2004-03-29 10:25   ` 2.6.5-rc2-mm5 Andrew Morton
2004-03-29 10:33     ` 2.6.5-rc2-mm5 Russell King
2004-03-29 10:49       ` Andrew Morton [this message]
2004-03-30  9:27 ` 2.6.5-rc2-mm5 R. J. Wysocki
2004-03-30  9:24   ` 2.6.5-rc2-mm5 Andrew Morton
2004-03-30  9:40     ` 2.6.5-rc2-mm5 R. J. Wysocki

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=20040329024959.34c9b77e.akpm@osdl.org \
    --to=akpm@osdl.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rmk+lkml@arm.linux.org.uk \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.