On Thu, 2007-07-05 at 19:36 +0400, Oleg Nesterov wrote: > So, __WORK_INITIALIZER() uses work_struct itself as a "struct lock_class_key" ? > How so? Well, this is for work_structs that are static (not dynamically allocated.) struct lock_class_key is just a single byte because its whole purpose is to be a unique pointer, there's nothing actually in it. Hence, taking the address of the work struct (when it's statically allocated) is a unique pointer just as well. johannes
Attachment:
signature.asc
Description: This is a digitally signed message part
- Follow-Ups:
- Re: [PATCH 2/2] workqueue: debug work related deadlocks with lockdep
- From: Oleg Nesterov <[email protected]>
- Re: [PATCH 2/2] workqueue: debug work related deadlocks with lockdep
- References:
- [PATCH 0/2] workqueue lockup debugging
- From: Johannes Berg <[email protected]>
- [PATCH 2/2] workqueue: debug work related deadlocks with lockdep
- From: Johannes Berg <[email protected]>
- Re: [PATCH 2/2] workqueue: debug work related deadlocks with lockdep
- From: Oleg Nesterov <[email protected]>
- [PATCH 0/2] workqueue lockup debugging
- Prev by Date: Re: [PATCH 1/2] workqueue: debug flushing deadlocks with lockdep
- Next by Date: Re: [ANNOUNCE] util-linux-ng 2.13-rc1
- Previous by thread: Re: [PATCH 2/2] workqueue: debug work related deadlocks with lockdep
- Next by thread: Re: [PATCH 2/2] workqueue: debug work related deadlocks with lockdep
- Index(es):