diff options
author | Sven Eckelmann <sven.eckelmann@gmx.de> | 2010-09-18 21:01:17 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-09-20 16:29:49 -0700 |
commit | 952c699c06f562b07dba4b1f91dfc02de928545d (patch) | |
tree | 90bf11b1b6f3f25789cc912bb52bfe16dc8c3bc8 /drivers/staging/batman-adv | |
parent | 2250840111b362a30e35ce52770bde3692e402b2 (diff) | |
download | blackbird-obmc-linux-952c699c06f562b07dba4b1f91dfc02de928545d.tar.gz blackbird-obmc-linux-952c699c06f562b07dba4b1f91dfc02de928545d.zip |
Staging: batman-adv: Remove unneeded rcu_read_lock
Regions which do not use rcu functions don't need to protected by
rcu_read_lock. If we want to protect data from being freed than it must
be covered by the same read-side critical section or otherwise the grace
period may already ended and freed the memory before we called
rcu_read_lock again.
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/batman-adv')
-rw-r--r-- | drivers/staging/batman-adv/originator.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/staging/batman-adv/originator.c b/drivers/staging/batman-adv/originator.c index f25d7fdfe811..c530df12e03e 100644 --- a/drivers/staging/batman-adv/originator.c +++ b/drivers/staging/batman-adv/originator.c @@ -329,7 +329,6 @@ int orig_seq_print_text(struct seq_file *seq, void *offset) net_dev->name); } - rcu_read_lock(); seq_printf(seq, "[B.A.T.M.A.N. adv %s%s, MainIF/MAC: %s/%s (%s)]\n", SOURCE_VERSION, REVISION_VERSION_STR, bat_priv->primary_if->net_dev->name, @@ -337,7 +336,6 @@ int orig_seq_print_text(struct seq_file *seq, void *offset) seq_printf(seq, " %-15s %s (%s/%i) %17s [%10s]: %20s ...\n", "Originator", "last-seen", "#", TQ_MAX_VALUE, "Nexthop", "outgoingIF", "Potential nexthops"); - rcu_read_unlock(); spin_lock_irqsave(&bat_priv->orig_hash_lock, flags); |