Skip to content

RFC using lockdep to validate rcu usage

Peter Zijlstra lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest6 patches 23 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/6lockdep: annotate rcu_read_{,un}lock{,_bh}include/linux/lockdep.h include/linux/rcupdate.h kernel/rcupdate.c+29 -01 reply
2/6lockdep: validate rcu_dereference() vs rcu_read_lock()include/linux/lockdep.h include/linux/rcupdate.h kernel/lockdep.c+67 -021 replies
3/6lockdep: rcu_dereference() vs preempt_disable()include/linux/preempt.h kernel/sched.c lib/Kconfig.debug+22 -120 replies
4/6implicit vs explicit preempt_disable()include/linux/preempt.h kernel/sched.c kernel/spinlock.c +1 more+82 -570 replies
5/6fixup funny preemption tricks in irq_exitkernel/softirq.c+1 -10 replies
6/6fixup early bootinit/main.c+3 -20 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [RFC][PATCH 0/6] using lockdep to validate rcu usage

This patch set uses lockdep to validate rcu usage.

It annotates rcu_read_{,un}lock{,_bh}() to catch imbalances. And further uses that information to establish a proper context for rcu_dereference().

It also separates implicit from explicit preempt_disable() usage, in order to separate rcu_dereference() from the locking model.

A kernel (2.6.23-rc4-mm1) with these patches boots but does have some funnies - I suspect it calls printf from places it doesn't like.

The first patch should be safe to apply, the rest is RFC.

If people want to see the very noisy bootlog this generates:
http://programming.kicks-ass.net/kernel-patches/lockdep_rcu/lockdep_rcu.log