mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-04 13:21:45 +00:00
driver core: fix namespace issue with devices assigned to classes
- uses a kset in "struct class" to keep track of all directories belonging to this class - merges with the /sys/devices/virtual logic. - removes the namespace-dir if the last member of that class leaves the directory. There may be locking or refcounting fixes left, I stopped when it seemed to work with network and sound modules. :) From: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
00ed8e3dda
commit
864062457a
6 changed files with 89 additions and 28 deletions
|
@ -181,10 +181,9 @@ struct class {
|
|||
struct list_head children;
|
||||
struct list_head devices;
|
||||
struct list_head interfaces;
|
||||
struct kset class_dirs;
|
||||
struct semaphore sem; /* locks both the children and interfaces lists */
|
||||
|
||||
struct kobject *virtual_dir;
|
||||
|
||||
struct class_attribute * class_attrs;
|
||||
struct class_device_attribute * class_dev_attrs;
|
||||
struct device_attribute * dev_attrs;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue