class: change internal semaphore to a mutex
Now that the lockdep infrastructure in the class core is in place, we should be able to properly change the internal class semaphore to be a mutex. David wrote the original patch, and Greg fixed it up to apply properly due to all of the recent changes in this area. From: Dave Young <hidave.darkstar@gmail.com> Cc: Matthew Wilcox <matthew@wil.cx> Cc: Kay Sievers <kay.sievers@vrfy.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
d2a3b9146e
commit
f75b1c60fc
@@ -44,7 +44,7 @@ struct driver_private {
|
||||
* @class_devices - list of devices associated with this class
|
||||
* @class_interfaces - list of class_interfaces associated with this class
|
||||
* @class_dirs - "glue" directory for virtual devices associated with this class
|
||||
* @class_sem - semaphore to protect the children, devices, and interfaces lists.
|
||||
* @class_mutex - mutex to protect the children, devices, and interfaces lists.
|
||||
* @class - pointer back to the struct class that this structure is associated
|
||||
* with.
|
||||
*
|
||||
@@ -57,7 +57,7 @@ struct class_private {
|
||||
struct list_head class_devices;
|
||||
struct list_head class_interfaces;
|
||||
struct kset class_dirs;
|
||||
struct semaphore class_sem;
|
||||
struct mutex class_mutex;
|
||||
struct class *class;
|
||||
};
|
||||
#define to_class(obj) \
|
||||
|
Reference in New Issue
Block a user