Re: [PATCH] workaround minor lockdep bug triggered by mm_take_all_locks
- Date: Mon, 04 Aug 2008 19:00:03 -0700
- From: Roland Dreier <rdreier@xxxxxxxxx>
- Subject: Re: [PATCH] workaround minor lockdep bug triggered by mm_take_all_locks
> The point is that this is a runtime evaluation of lock orders, if > runtime isn't the lucky one that reproduces the deadlock, it'll find > nothing at all. I think the point you miss is that lockdep can report a potential deadlock, even if the deadlock does not actually occur. For example suppose there is an AB-BA deadlock somewhere. For this to actually trigger, we have to have one CPU running the AB code path at exactly the moment another CPU runs the BA code path, with the right timing so one CPU holds A and tries to grab B while the other CPU already holds B. With lockdep, we just have to have the AB code path run once at any point, and then the BA code path run at any later time (even days after the AB code path has released all the locks). And then we get a warning dump that explains the exact potential deadlock. - R. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
- Follow-Ups:
- Re: [PATCH] workaround minor lockdep bug triggered by mm_take_all_locks
- From: Andrea Arcangeli
- Re: [PATCH] workaround minor lockdep bug triggered by mm_take_all_locks
- References:
- Re: [RFC][PATCH 7/7] lockdep: spin_lock_nest_lock()
- From: Dave Jones
- Re: [RFC][PATCH 7/7] lockdep: spin_lock_nest_lock()
- From: Peter Zijlstra
- Re: [RFC][PATCH 7/7] lockdep: spin_lock_nest_lock()
- From: Andrea Arcangeli
- Re: [RFC][PATCH 7/7] lockdep: spin_lock_nest_lock()
- From: Peter Zijlstra
- Re: [RFC][PATCH 7/7] lockdep: spin_lock_nest_lock()
- From: Andrea Arcangeli
- Re: [RFC][PATCH 7/7] lockdep: spin_lock_nest_lock()
- From: Andrea Arcangeli
- [PATCH] workaround minor lockdep bug triggered by mm_take_all_locks
- From: Andrea Arcangeli
- Re: [PATCH] workaround minor lockdep bug triggered by mm_take_all_locks
- From: Peter Zijlstra
- Re: [PATCH] workaround minor lockdep bug triggered by mm_take_all_locks
- From: Andrea Arcangeli
- Re: [PATCH] workaround minor lockdep bug triggered by mm_take_all_locks
- From: Peter Zijlstra
- Re: [PATCH] workaround minor lockdep bug triggered by mm_take_all_locks
- From: Andrea Arcangeli
- Re: [RFC][PATCH 7/7] lockdep: spin_lock_nest_lock()
- Prev by Date: Re: [PATCH] jbd: abort instead of waiting for nonexistent transactions
- Next by Date: Re: [rfc][patch 3/3] xfs: use new vmap API
- Previous by thread: Re: [PATCH] workaround minor lockdep bug triggered by mm_take_all_locks
- Next by thread: Re: [PATCH] workaround minor lockdep bug triggered by mm_take_all_locks
- Index(es):