From: Ingo Molnar Date: Fri, 11 Jul 2008 08:46:50 +0000 (+0200) Subject: Merge branch 'linus' into core/rcu X-Git-Tag: v2.6.27-rc1~1070^2^2~1 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=0c81b2a1448bc6a2a9b2d6469fb0669fb4b25e5b;p=linux-2.6-omap-h63xx.git Merge branch 'linus' into core/rcu Conflicts: include/linux/rculist.h kernel/rcupreempt.c Signed-off-by: Ingo Molnar --- 0c81b2a1448bc6a2a9b2d6469fb0669fb4b25e5b diff --cc kernel/rcupreempt.c index 396b121edfe,41d275a81df..536ce83c55f --- a/kernel/rcupreempt.c +++ b/kernel/rcupreempt.c @@@ -1056,42 -925,23 +1056,38 @@@ void rcu_offline_cpu(int cpu spin_unlock_irqrestore(&rdp->lock, flags); } - void __devinit rcu_online_cpu(int cpu) + #else /* #ifdef CONFIG_HOTPLUG_CPU */ + + void rcu_offline_cpu(int cpu) + { + } + + #endif /* #else #ifdef CONFIG_HOTPLUG_CPU */ + + void __cpuinit rcu_online_cpu(int cpu) { unsigned long flags; + struct rcu_data *rdp; spin_lock_irqsave(&rcu_ctrlblk.fliplock, flags); cpu_set(cpu, rcu_cpu_online_map); spin_unlock_irqrestore(&rcu_ctrlblk.fliplock, flags); + + /* + * The rcu_sched grace-period processing might have bypassed + * this CPU, given that it was not in the rcu_cpu_online_map + * when the grace-period scan started. This means that the + * grace-period task might sleep. So make sure that if this + * should happen, the first callback posted to this CPU will + * wake up the grace-period task if need be. + */ + + rdp = RCU_DATA_CPU(cpu); + spin_lock_irqsave(&rdp->lock, flags); + rdp->rcu_sched_sleeping = 1; + spin_unlock_irqrestore(&rdp->lock, flags); } - #else /* #ifdef CONFIG_HOTPLUG_CPU */ - - void rcu_offline_cpu(int cpu) - { - } - - void __devinit rcu_online_cpu(int cpu) - { - } - - #endif /* #else #ifdef CONFIG_HOTPLUG_CPU */ - static void rcu_process_callbacks(struct softirq_action *unused) { unsigned long flags;