mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Trond Myklebust <trond.myklebust@fys.uio.no>
To: Tim Hockin <thockin@hockin.org>
Cc: Tim Hockin <thockin@Sun.COM>,
	Linux Kernel mailing list <linux-kernel@vger.kernel.org>
Subject: Re: calling flush_scheduled_work()
Date: Fri, 12 Mar 2004 18:19:14 -0500	[thread overview]
Message-ID: <1079133554.3166.69.camel@lade.trondhjem.org> (raw)
In-Reply-To: <20040312223811.GA15636@hockin.org>

På fr , 12/03/2004 klokka 17:38, skreiv Tim Hockin:
> That just divides up the problem, but doesn't solve it.  The simplest would
> be to print a badness and somehow get out of the flush.  Then anyone who is
> triggering the corner case (us, in this case) can just solve it ourselves.
> It's not pretty.

Ewww.... That's saying "I'm just going to ignore the problem and pretend
I can continue". At least the hang will tell you that there *is* a
problem and points to where it is happening.

If I understood your description of where it is happening, then in this
case, continuing is likely to lead to an Oops later when all those open
RPC up/downcall pipes find that their parent directory has disappeared
from underneath them.

> In short, it's dubious that ANYONE call flush_scheduled_work() on a
> workqueue that they don't own.

Huh? You're saying that just because work has been scheduled on some
third party thread, you should not be allowed to wait on completion of
that work? That is a clearly unreasonable statement... Imagine doing
even memory allocation in such an environment...

I agree that we need to identify and solve the deadlocking problems, but
let's not start constricting developers with completely arbitrary rules.

The *real* problem here is that mput() is being run from keventd, and is
triggering code that was assumed to be running from an ordinary process
context. Let's concentrate on fixing that...

Cheers,
  Trond

  reply	other threads:[~2004-03-12 23:19 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-03-12 20:58 Tim Hockin
2004-03-12 22:00 ` Trond Myklebust
2004-03-12 22:38   ` Tim Hockin
2004-03-12 23:19     ` Trond Myklebust [this message]
2004-03-12 23:27       ` Tim Hockin
2004-03-12 23:27 ` Andrew Morton
2004-03-13  0:20   ` Tim Hockin
2004-03-13  1:17   ` Trond Myklebust
2004-03-13  2:12     ` Andrew Morton
2004-03-13  2:24       ` Trond Myklebust
2004-03-13 11:45 Stefan Rompf

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=1079133554.3166.69.camel@lade.trondhjem.org \
    --to=trond.myklebust@fys.uio.no \
    --cc=linux-kernel@vger.kernel.org \
    --cc=thockin@Sun.COM \
    --cc=thockin@hockin.org \
    /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

all inboxes | Powered by JetHome®