public inbox for netdev@vger.kernel.org 
 help / color / mirror / Atom feed
From: Ben Hutchings <bhutchings@solarflare•com>
To: Ben Greear <greearb@candelatech•com>
Cc: NetDev <netdev@vger•kernel.org>
Subject: Re: Question on ipmr.c locking in 2.6.25
Date: Wed, 28 May 2008 22:58:34 +0100	[thread overview]
Message-ID: <20080528215833.GA14038@solarflare.com> (raw)
In-Reply-To: <483DD0EE.1020700@candelatech.com>

Ben Greear wrote:
> It looks like this method can return without unlocking the
> mrt_lock or mfc_unres_lock.  Is this a bug, or am I just
> confused about how it is supposed to work?
<snip>

Since it returns without unlocking in the normal (not error) case, I would
guess that's how it's supposed to work.  The caller can uses the it->cache
pointer to work out which lock (if any) it needs to unlock.

Still, this is an unusual way of doing things, and rates about a 2 on
Rusty's scale <http://ozlabs.org/~rusty/index.cgi/2008/03/30/> (though
to be fair this is not critical for static functions).

Ben.

-- 
Ben Hutchings, Senior Software Engineer, Solarflare Communications
Not speaking for my employer; that's the marketing department's job.

  reply	other threads:[~2008-05-28 21:58 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-05-28 21:38 Question on ipmr.c locking in 2.6.25 Ben Greear
2008-05-28 21:58 ` Ben Hutchings [this message]
2008-05-28 22:06   ` Ben Greear
2008-05-29 10:47     ` David 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=20080528215833.GA14038@solarflare.com \
    --to=bhutchings@solarflare$(echo .)com \
    --cc=greearb@candelatech$(echo .)com \
    --cc=netdev@vger$(echo .)kernel.org \
    /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