From: Benjamin Poirier <benjamin.poirier@gmail.com>
To: Michael Chan <mchan@broadcom.com>
Cc: davem@davemloft.net, netdev@vger.kernel.org, nhorman@tuxdriver.com
Subject: Re: [PATCH 2/3] cnic: Don't take cnic_dev_lock in cnic_alloc_uio_rings()
Date: Mon, 2 Jun 2014 14:24:27 -0700 [thread overview]
Message-ID: <20140602212427.GC17916@f1.synalogic.ca> (raw)
In-Reply-To: <1401741114.6344.2.camel@LTIRV-MCHAN1.corp.ad.broadcom.com>
On 2014/06/02 13:31, Michael Chan wrote:
> On Fri, 2014-05-30 at 15:33 -0700, Benjamin Poirier wrote:
> > On 2014/05/30 16:18, Michael Chan wrote:
> > > We are allocating memory with GFP_KERNEL under spinlock. Since this is
> > > the only call manipulating the cnic_udev_list and it is always under
> > > rtnl_lock, cnic_dev_lock can be safely removed.
> >
> > In that case, the many other instances of cnic_dev_lock throughout cnic
> > should also be removed, no?
>
> I don't think so. cnic_dev_list still needs to be protected using
> cnic_dev_lock. cnic_register_driver() for example is not called with
> rtnl_lock().
>
Ah, that's right. I had not paid attention to the fact that the same
lock protected cnic_dev_list and cnic_udev_list. Thanks for pointing it
out.
next prev parent reply other threads:[~2014-06-02 21:24 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-30 23:18 [PATCH 0/3] cnic fixes Michael Chan
2014-05-30 23:18 ` [PATCH 1/3] cnic: Don't take rcu_read_lock in cnic_rcv_netevent() Michael Chan
2014-05-30 23:18 ` [PATCH 2/3] cnic: Don't take cnic_dev_lock in cnic_alloc_uio_rings() Michael Chan
2014-05-30 22:33 ` Benjamin Poirier
2014-06-02 20:31 ` Michael Chan
2014-06-02 21:24 ` Benjamin Poirier [this message]
2014-05-30 22:50 ` Benjamin Poirier
2014-05-31 5:40 ` Michael Chan
2014-05-30 23:18 ` [PATCH 3/3] cnic: Fix missing ISCSI_KEVENT_IF_DOWN message Michael Chan
2014-05-31 13:07 ` [PATCH 2/3] cnic: Don't take cnic_dev_lock in cnic_alloc_uio_rings() Neil Horman
2014-06-01 0:07 ` Michael Chan
2014-06-02 23:53 ` [PATCH 0/3] cnic fixes David Miller
2014-06-02 23:57 ` David Miller
2014-06-03 0:08 ` Michael Chan
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=20140602212427.GC17916@f1.synalogic.ca \
--to=benjamin.poirier@gmail.com \
--cc=davem@davemloft.net \
--cc=mchan@broadcom.com \
--cc=netdev@vger.kernel.org \
--cc=nhorman@tuxdriver.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 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.