netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Rompf <srompf@isg.de>
To: Michal Ostrowski <mostrows@watson.ibm.com>
Cc: netdev@oss.sgi.com
Subject: Re: Deadlock in sungem/ip_auto_config/linkwatch
Date: Mon, 5 Jan 2004 17:50:55 +0100	[thread overview]
Message-ID: <200401051750.56233.srompf@isg.de> (raw)
In-Reply-To: <1073319565.2043.98923.camel@brick.watson.ibm.com>

[-- Attachment #1: Type: text/plain, Size: 986 bytes --]

Am Montag, 05. Januar 2004 17:19 schrieb Michal Ostrowski:

> Suppose the linkwatch code backs-off in the case that rtnl_sem is held
> legitimately by thread A.  Meanwhile, thread B is doing a
> flush_scheduled_work in order to wait for pending linkwatch events to
> complete.

This won't happen. If a pending linkwatch event needs to be scheduled 
synchronously (f.e. when a device is unregistered), it is executed in context 
of the calling process, not inside the workqueue thread.

> My initial though was to use a seperate work-queue, un-entangled with
> the global queue used for flush_scheduled_work. This would allow
> linkwatch events to be synchronized against explicitly.

That's overkill, and if I understand flush_workqueue() right, it doesn't care 
about work that is queued with delay, so it even wouldn't help. That's why I 
thought about a function to unregister pending work.

Stefan
-- 
"doesn't work" is not a magic word to explain everything.

[-- Attachment #2: signature --]
[-- Type: application/pkcs7-signature, Size: 1691 bytes --]

  reply	other threads:[~2004-01-05 16:50 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-05 13:07 Deadlock in sungem/ip_auto_config/linkwatch Michal Ostrowski
2004-01-05 14:50 ` Stefan Rompf
2004-01-05 16:19   ` Michal Ostrowski
2004-01-05 16:50     ` Stefan Rompf [this message]
2004-01-05 19:02   ` David S. Miller

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=200401051750.56233.srompf@isg.de \
    --to=srompf@isg.de \
    --cc=mostrows@watson.ibm.com \
    --cc=netdev@oss.sgi.com \
    /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).