From: Jarek Poplawski <jarkao2@gmail•com>
To: Jay Vosburgh <fubar@us•ibm.com>
Cc: Laurent Chavey <chavey@google•com>,
Johannes Berg <johannes@sipsolutions•net>,
Mikhail Markine <markine@google•com>,
netdev@vger•kernel.org, bonding-devel@lists•sourceforge.net,
Petri Gynther <pgynther@google•com>,
David Miller <davem@davemloft•net>
Subject: Re: [Bonding-devel] [PATCH] bonding: cancel_delayed_work() -> cancel_delayed_work_sync()
Date: Thu, 17 Dec 2009 22:58:23 +0100 [thread overview]
Message-ID: <20091217215823.GA3491@ami.dom.local> (raw)
In-Reply-To: <9587.1261086029@death.nxdomain.ibm.com>
On Thu, Dec 17, 2009 at 01:40:29PM -0800, Jay Vosburgh wrote:
> A less evil alternative would be to punt and reschedule the work
> if the rtnl_trylock failed, e.g.,
>
> if (bond_miimon_inspect(bond)) {
> read_unlock(&bond->lock);
> if (!rtnl_trylock()) {
> queue_work(...);
> return;
> }
>
> read_lock(&bond->lock);
>
> bond_miimon_commit(bond);
> [...]
>
> I'm not sure what the usual contention level on rtnl is (and,
> therefore, how often this will punt for the normal case that's not the
> race we're trying to avoid here).
Even if there is not much contention there is usually a lot of work
inside, so this looks most reasonable to me.
Jarek P.
next prev parent reply other threads:[~2009-12-17 21:59 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-12-17 0:28 [PATCH] bonding: cancel_delayed_work() -> cancel_delayed_work_sync() Mikhail Markine
2009-12-17 7:49 ` Jarek Poplawski
2009-12-17 13:36 ` Jarek Poplawski
2009-12-17 14:30 ` Johannes Berg
2009-12-17 16:12 ` [Bonding-devel] " Jay Vosburgh
2009-12-17 18:40 ` Jarek Poplawski
2009-12-17 18:49 ` Laurent Chavey
2009-12-17 19:37 ` Jay Vosburgh
2009-12-17 20:56 ` Jarek Poplawski
2009-12-17 21:16 ` Jarek Poplawski
2009-12-17 21:40 ` Jay Vosburgh
2009-12-17 21:58 ` Jarek Poplawski [this message]
2009-12-17 22:33 ` Jarek Poplawski
2009-12-17 21:25 ` Laurent Chavey
2009-12-17 21:31 ` Mikhail Markine
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=20091217215823.GA3491@ami.dom.local \
--to=jarkao2@gmail$(echo .)com \
--cc=bonding-devel@lists$(echo .)sourceforge.net \
--cc=chavey@google$(echo .)com \
--cc=davem@davemloft$(echo .)net \
--cc=fubar@us$(echo .)ibm.com \
--cc=johannes@sipsolutions$(echo .)net \
--cc=markine@google$(echo .)com \
--cc=netdev@vger$(echo .)kernel.org \
--cc=pgynther@google$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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