linux/kernel
Paul E. McKenney de078d875c rcu: Need to update rnp->gpnum if preemptable RCU is to be reliable
Without this patch, tasks preempted in RCU read-side critical
sections can fail to block the grace period, given that
rnp->gpnum is used to determine which rnp->blocked_tasks[]
element the preempted task is enqueued on.

Before the patch, rnp->gpnum is always zero, so preempted tasks
are always enqueued on rnp->blocked_tasks[0], which is correct
only when the current CPU has not checked into the current
grace period and the grace-period number is even, or,
similarly, if the current CPU -has- checked into the current
grace period and the grace-period number is odd.

Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Acked-by: Steven Rostedt <rostedt@goodmis.org>
Cc: laijs@cn.fujitsu.com
Cc: dipankar@in.ibm.com
Cc: akpm@linux-foundation.org
Cc: mathieu.desnoyers@polymtl.ca
Cc: josht@linux.vnet.ibm.com
Cc: dvhltc@us.ibm.com
Cc: niv@us.ibm.com
Cc: peterz@infradead.org
LKML-Reference: <12524504771622-git-send-email->
Signed-off-by: Ingo Molnar <mingo@elte.hu>
2009-09-18 00:04:54 +02:00
..
gcov powerpc: Enable GCOV 2009-08-20 10:29:28 +10:00
irq Merge branch 'irq-threaded-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip 2009-09-11 13:21:31 -07:00
power PM: Trivial fixes 2009-09-14 20:26:59 +02:00
time clockevent: Prevent dead lock on clockevents_lock 2009-08-19 18:15:10 +02:00
trace Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/percpu 2009-09-15 09:39:44 -07:00
.gitignore
Kconfig.freezer
Kconfig.hz
Kconfig.preempt
Makefile driver-core: move dma-coherent.c from kernel to driver/base 2009-09-15 09:50:47 -07:00
acct.c bsdacct: switch credentials for writing to the accounting file 2009-08-24 11:33:40 +10:00
async.c
audit.c
audit.h
audit_tree.c
audit_watch.c
auditfilter.c
auditsc.c
backtracetest.c
bounds.c
capability.c
cgroup.c writeback: add name to backing_dev_info 2009-09-11 09:20:26 +02:00
cgroup_debug.c
cgroup_freezer.c
compat.c
configs.c
cpu.c Merge branch 'x86-pat-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip 2009-09-15 09:19:38 -07:00
cpuset.c
cred-internals.h
cred.c CRED: Allow put_cred() to cope with a NULL groups list 2009-09-15 09:10:57 +10:00
delayacct.c
dma.c
exec_domain.c
exit.c Merge branch 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip 2009-09-11 13:20:18 -07:00
extable.c
fork.c Merge branch 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip 2009-09-11 13:20:18 -07:00
freezer.c
futex.c Merge branch 'core-futexes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip 2009-09-11 13:16:22 -07:00
futex_compat.c futex: Fix compat_futex to be same as futex for REQUEUE_PI 2009-08-10 15:41:12 +02:00
groups.c
hrtimer.c pktgen: spin using hrtimer 2009-08-28 23:41:29 -07:00
hung_task.c
itimer.c
kallsyms.c
kexec.c kexec: fix omitting offset in extended crashkernel syntax 2009-07-29 19:10:34 -07:00
kfifo.c
kgdb.c
kmod.c Merge branch 'tracing-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip 2009-09-11 13:24:03 -07:00
kprobes.c Merge branch 'linus' into tracing/core 2009-08-11 14:19:09 +02:00
ksysfs.c
kthread.c sched: Keep kthreads at default priority 2009-09-09 17:30:06 +02:00
latencytop.c
lockdep.c lockdep: Remove recursion stattistics 2009-08-29 13:22:36 +02:00
lockdep_internals.h lockdep: BFS cleanup 2009-07-24 10:53:29 +02:00
lockdep_proc.c Merge commit 'v2.6.31-rc8' into core/locking 2009-08-31 18:05:25 +02:00
lockdep_states.h
marker.c
module.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/percpu 2009-09-15 09:39:44 -07:00
mutex-debug.c
mutex-debug.h
mutex.c
mutex.h
notifier.c
ns_cgroup.c
nsproxy.c
panic.c trace: stop tracer in oops_enter() 2009-07-24 15:30:45 -04:00
params.c
perf_counter.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/percpu 2009-09-15 09:39:44 -07:00
pid.c
pid_namespace.c
pm_qos_params.c
posix-cpu-timers.c posix_cpu_timers_exit_group(): Do not use thread_group_cputimer() 2009-08-08 18:30:25 +02:00
posix-timers.c posix-timers: Fix oops in clock_nanosleep() with CLOCK_MONOTONIC_RAW 2009-08-04 10:16:41 +02:00
printk.c cleanup console_print() 2009-09-14 17:41:42 -07:00
profile.c profile: suppress warning about large allocations when profile=1 is specified 2009-07-29 19:10:36 -07:00
ptrace.c
rcupdate.c rcu: Delay rcu_barrier() wait until beginning of next CPU-hotunplug operation. 2009-08-19 13:58:54 +02:00
rcutorture.c
rcutree.c rcu: Need to update rnp->gpnum if preemptable RCU is to be reliable 2009-09-18 00:04:54 +02:00
rcutree.h rcu: Changes from reviews: avoid casts, fix/add warnings, improve comments 2009-08-29 15:34:40 +02:00
rcutree_plugin.h rcu: Changes from reviews: avoid casts, fix/add warnings, improve comments 2009-08-29 15:34:40 +02:00
rcutree_trace.c rcu: Merge preemptable-RCU functionality into hierarchical RCU 2009-08-23 10:32:40 +02:00
relay.c
res_counter.c
resource.c
rtmutex-debug.c
rtmutex-debug.h
rtmutex-tester.c
rtmutex.c rtmutex: Avoid deadlock in rt_mutex_start_proxy_lock() 2009-08-06 05:50:21 +02:00
rtmutex.h
rtmutex_common.h
rwsem.c
sched.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/percpu 2009-09-15 09:39:44 -07:00
sched_clock.c
sched_cpupri.c sched: Add new prio to cpupri before removing old prio 2009-08-02 14:26:09 +02:00
sched_cpupri.h
sched_debug.c sched: Provide iowait counters 2009-09-02 08:44:08 +02:00
sched_fair.c sched: Fix sched::sched_stat_wait tracepoint field 2009-09-10 20:52:54 +02:00
sched_features.h sched: Disable NEW_FAIR_SLEEPERS for now 2009-09-10 20:34:48 +02:00
sched_idletask.c
sched_rt.c sched: Scale down cpu_power due to RT tasks 2009-09-04 10:09:55 +02:00
sched_stats.h
seccomp.c
semaphore.c
signal.c do_sigaltstack: small cleanups 2009-08-01 11:18:56 -07:00
slow-work.c
smp.c Merge branch 'x86/urgent' into x86/pat 2009-08-26 17:24:28 -07:00
softirq.c rcu: Renamings to increase RCU clarity 2009-08-23 10:32:37 +02:00
softlockup.c
spinlock.c locking: Allow arch-inlined spinlocks 2009-08-31 18:08:50 +02:00
srcu.c
stacktrace.c
stop_machine.c
sys.c
sys_ni.c
sysctl.c block: fix linkage problem with blk_iopoll and !CONFIG_BLOCK 2009-09-15 21:53:11 +02:00
sysctl_check.c
taskstats.c
test_kprobes.c
time.c
timeconst.pl
timer.c rcu: Simplify rcu_pending()/rcu_check_callbacks() API 2009-08-23 10:32:39 +02:00
tracepoint.c tracing: Don't trace kernel thread syscalls 2009-08-26 21:29:52 +02:00
tsacct.c
uid16.c
up.c
user.c
user_namespace.c
utsname.c
utsname_sysctl.c
wait.c locking, sched: Give waitqueue spinlocks their own lockdep classes 2009-08-10 14:43:09 +02:00
workqueue.c Merge branch 'sched-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip 2009-09-11 13:23:18 -07:00