From: Eric Dumazet <eric.dumazet@gmail.com>
To: Cong Wang <xiyou.wangcong@gmail.com>
Cc: linux-kernel@vger.kernel.org,
Andrew Morton <akpm@linux-foundation.org>,
Dennis1.Chen@amd.com,
"Paul E. McKenney" <paulmck@linux.vnet.ibm.com>,
Rusty Russell <rusty@rustcorp.com.au>,
Alexander Viro <viro@zeniv.linux.org.uk>,
NeilBrown <neilb@suse.de>, Kay Sievers <kay.sievers@vrfy.org>,
Joe Perches <joe@perches.com>,
linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH 5/7] module: take rcu_read_lock_sched() for /proc read
Date: Thu, 15 Mar 2012 09:18:49 -0700 [thread overview]
Message-ID: <1331828329.4874.7.camel@edumazet-glaptop> (raw)
In-Reply-To: <1331822941-19938-5-git-send-email-xiyou.wangcong@gmail.com>
On Thu, 2012-03-15 at 22:48 +0800, Cong Wang wrote:
> In the seq file operations, it still hold module_mutex for just reading
> the module list, switch to rcu_read_lock_sched() too.
>
Why is it needed ?
1) insmod/rmmod/lsmod is hardly in fast path.
2) after a mutex_lock(), a task is still preemptible
after rcu_read_lock_sched(), preemption is disabled
with NR_CPUS=4096, getting module refcounts is _very_ slow
RCU doesnt fit every workload.
next prev parent reply other threads:[~2012-03-15 16:18 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-15 14:48 [V3 PATCH 1/7] module: replace preempt_disable with rcu_read_lock_sched Cong Wang
2012-03-15 14:48 ` [PATCH 2/7] module: take rcu_read_lock_sched for find_symbol Cong Wang
2012-03-15 14:48 ` [PATCH 3/7] module: take rcu_read_lock_sched for find_module Cong Wang
2012-03-15 16:29 ` Eric Dumazet
2012-03-15 14:48 ` [PATCH 4/7] module: take rcu_read_lock_sched in module_kallsyms_on_each_symbol() Cong Wang
2012-03-15 14:48 ` [PATCH 5/7] module: take rcu_read_lock_sched() for /proc read Cong Wang
2012-03-15 16:18 ` Eric Dumazet [this message]
2012-03-15 14:49 ` [PATCH 6/7] module: add two missing synchronize_sched() Cong Wang
2012-03-15 16:26 ` Eric Dumazet
2012-03-15 14:49 ` [PATCH 7/7] module: avoid exporting module_mutex Cong Wang
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=1331828329.4874.7.camel@edumazet-glaptop \
--to=eric.dumazet@gmail.com \
--cc=Dennis1.Chen@amd.com \
--cc=akpm@linux-foundation.org \
--cc=joe@perches.com \
--cc=kay.sievers@vrfy.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=neilb@suse.de \
--cc=paulmck@linux.vnet.ibm.com \
--cc=rusty@rustcorp.com.au \
--cc=viro@zeniv.linux.org.uk \
--cc=xiyou.wangcong@gmail.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
all inboxes | Powered by JetHome®