* [PATCH RFC] vm: Adjust ifdef for TINY_RCU
@ 2013-03-04 16:02 Paul E. McKenney
0 siblings, 0 replies; only message in thread
From: Paul E. McKenney @ 2013-03-04 16:02 UTC (permalink / raw)
To: linux-kernel; +Cc: andi, akpm, mel, daniel.vetter, paul.gortmaker
There is an ifdef in page_cache_get_speculative() that checks for !SMP
and TREE_RCU, which has been an impossible combination since the advent
of TINY_RCU. The ifdef enables a fastpath that is valid when preemption
is disabled by rcu_read_lock() in UP systems, which is the case when
TINY_RCU is enabled. This commit therefore adjusts the ifdef to generate
the fastpath when TINY_RCU is enabled.
Reported-by: Andi Kleen <andi@firstfloor.org>
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
diff --git a/include/linux/pagemap.h b/include/linux/pagemap.h
index 0e38e13..e3dea75 100644
--- a/include/linux/pagemap.h
+++ b/include/linux/pagemap.h
@@ -149,7 +149,7 @@ static inline int page_cache_get_speculative(struct page *page)
{
VM_BUG_ON(in_interrupt());
-#if !defined(CONFIG_SMP) && defined(CONFIG_TREE_RCU)
+#ifdef CONFIG_TINY_RCU
# ifdef CONFIG_PREEMPT_COUNT
VM_BUG_ON(!in_atomic());
# endif
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2013-03-04 18:50 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-04 16:02 [PATCH RFC] vm: Adjust ifdef for TINY_RCU Paul E. McKenney
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox