From: Flavio Leitner <fleitner@redhat.com>
To: David Miller <davem@davemloft.net>
Cc: netdev@vger.kernel.org
Subject: Re: [PATCH] niu: fix SMP race protecting rx_rings and tx_rings
Date: Thu, 3 Feb 2011 21:47:48 -0200 [thread overview]
Message-ID: <20110203234748.GB3710@redhat.com> (raw)
In-Reply-To: <20110203.152214.59684545.davem@davemloft.net>
On Thu, Feb 03, 2011 at 03:22:14PM -0800, David Miller wrote:
> From: Flavio Leitner <fleitner@redhat.com>
> Date: Thu, 3 Feb 2011 21:18:05 -0200
>
> > Ok, I can write a new version using RCU if you like.
>
> Don't worry, I'll take care of it, I actually have the
> hardware to test on :-)
Ok. Having the hardware around indeed helps :)
> > I've chose rwsem because I think those operations aren't
> > frequent. The RCU leaves an operation to run later during
> > a safe context, so I thought the cost doesn't worth it.
>
> One thing I'm worried about with your patch is that the statistics
> method can be called in basically any context, therefore a sleeping
> lock like the rw_semaphore is probably not usable.
>
> In fact I'm going to revert your patch for now because of this issue.
Oops, I didn't see it there. I thought all calls there were process
context. Anyway, RCU then...
thanks for reviewing it,
--
Flavio
next prev parent reply other threads:[~2011-02-03 23:47 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-02-03 18:45 [PATCH] niu: fix SMP race protecting rx_rings and tx_rings Flavio Leitner
2011-02-03 22:21 ` David Miller
2011-02-03 23:18 ` Flavio Leitner
2011-02-03 23:22 ` David Miller
2011-02-03 23:47 ` Flavio Leitner [this message]
2011-02-03 23:53 ` 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=20110203234748.GB3710@redhat.com \
--to=fleitner@redhat.com \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.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;
as well as URLs for NNTP newsgroup(s).