Messages in this thread | | | Subject | Re: [PATCH RFC 00/11] lock monitor: Separate features related to lock | From | Peter Zijlstra <> | Date | Tue, 23 Mar 2010 16:45:34 +0100 |
| |
On Wed, 2010-03-17 at 16:39 +0100, Frederic Weisbecker wrote: > > might_lock_read() uses might_fault(), rcu, workqueues and probably > yet some others use sequences of lock_acquire/lock_release to prove > locking while there is actually no real lock operation involved, but > this is to detect dependency/balance mistakes.
might_fault() simply always takes the mmap_sem because actually hitting the fault path (which otherwise would establish that relation) is very rare for some cases, so by forcing that dependency we get better coverage.
rcu_read_lock() is an actual lock :-)
workqueues use 'fake' locks to connect lock chains to flush, so that we can detect things like trying to flush a workqueue while holding a lock that is required to complete the work.
| |