aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul E. McKenney <paulmck@linux.vnet.ibm.com>2013-05-09 11:55:54 -0400
committerPaul E. McKenney <paulmck@linux.vnet.ibm.com>2013-08-18 21:06:44 -0400
commitfeed66ed26a53e700ca02ce1744fed7d0c647292 (patch)
tree63ce47c2a3882ff58c281ea53f3b19afaa1a4882
parentf7f7bac9cb1c50783f15937a11743655a5756a36 (diff)
rcu: Eliminate unused APIs intended for adaptive ticks
The rcu_user_enter_after_irq() and rcu_user_exit_after_irq() functions were intended for use by adaptive ticks, but changes in implementation have rendered them unnecessary. This commit therefore removes them. Reported-by: Frederic Weisbecker <fweisbec@gmail.com> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Reviewed-by: Josh Triplett <josh@joshtriplett.org>
-rw-r--r--include/linux/rcupdate.h4
-rw-r--r--kernel/rcutree.c43
2 files changed, 0 insertions, 47 deletions
diff --git a/include/linux/rcupdate.h b/include/linux/rcupdate.h
index 0c38abbe6e35..30bea9c25735 100644
--- a/include/linux/rcupdate.h
+++ b/include/linux/rcupdate.h
@@ -229,13 +229,9 @@ extern void rcu_irq_exit(void);
229#ifdef CONFIG_RCU_USER_QS 229#ifdef CONFIG_RCU_USER_QS
230extern void rcu_user_enter(void); 230extern void rcu_user_enter(void);
231extern void rcu_user_exit(void); 231extern void rcu_user_exit(void);
232extern void rcu_user_enter_after_irq(void);
233extern void rcu_user_exit_after_irq(void);
234#else 232#else
235static inline void rcu_user_enter(void) { } 233static inline void rcu_user_enter(void) { }
236static inline void rcu_user_exit(void) { } 234static inline void rcu_user_exit(void) { }
237static inline void rcu_user_enter_after_irq(void) { }
238static inline void rcu_user_exit_after_irq(void) { }
239static inline void rcu_user_hooks_switch(struct task_struct *prev, 235static inline void rcu_user_hooks_switch(struct task_struct *prev,
240 struct task_struct *next) { } 236 struct task_struct *next) { }
241#endif /* CONFIG_RCU_USER_QS */ 237#endif /* CONFIG_RCU_USER_QS */
diff --git a/kernel/rcutree.c b/kernel/rcutree.c
index 338f1d1c1c66..8807019138c6 100644
--- a/kernel/rcutree.c
+++ b/kernel/rcutree.c
@@ -444,27 +444,6 @@ void rcu_user_enter(void)
444{ 444{
445 rcu_eqs_enter(1); 445 rcu_eqs_enter(1);
446} 446}
447
448/**
449 * rcu_user_enter_after_irq - inform RCU that we are going to resume userspace
450 * after the current irq returns.
451 *
452 * This is similar to rcu_user_enter() but in the context of a non-nesting
453 * irq. After this call, RCU enters into idle mode when the interrupt
454 * returns.
455 */
456void rcu_user_enter_after_irq(void)
457{
458 unsigned long flags;
459 struct rcu_dynticks *rdtp;
460
461 local_irq_save(flags);
462 rdtp = &__get_cpu_var(rcu_dynticks);
463 /* Ensure this irq is interrupting a non-idle RCU state. */
464 WARN_ON_ONCE(!(rdtp->dynticks_nesting & DYNTICK_TASK_MASK));
465 rdtp->dynticks_nesting = 1;
466 local_irq_restore(flags);
467}
468#endif /* CONFIG_RCU_USER_QS */ 447#endif /* CONFIG_RCU_USER_QS */
469 448
470/** 449/**
@@ -581,28 +560,6 @@ void rcu_user_exit(void)
581{ 560{
582 rcu_eqs_exit(1); 561 rcu_eqs_exit(1);
583} 562}
584
585/**
586 * rcu_user_exit_after_irq - inform RCU that we won't resume to userspace
587 * idle mode after the current non-nesting irq returns.
588 *
589 * This is similar to rcu_user_exit() but in the context of an irq.
590 * This is called when the irq has interrupted a userspace RCU idle mode
591 * context. When the current non-nesting interrupt returns after this call,
592 * the CPU won't restore the RCU idle mode.
593 */
594void rcu_user_exit_after_irq(void)
595{
596 unsigned long flags;
597 struct rcu_dynticks *rdtp;
598
599 local_irq_save(flags);
600 rdtp = &__get_cpu_var(rcu_dynticks);
601 /* Ensure we are interrupting an RCU idle mode. */
602 WARN_ON_ONCE(rdtp->dynticks_nesting & DYNTICK_TASK_NEST_MASK);
603 rdtp->dynticks_nesting += DYNTICK_TASK_EXIT_IDLE;
604 local_irq_restore(flags);
605}
606#endif /* CONFIG_RCU_USER_QS */ 563#endif /* CONFIG_RCU_USER_QS */
607 564
608/** 565/**