diff options
author | 2016-11-28 16:41:41 +0100 | |
---|---|---|
committer | 2016-11-29 21:12:12 +0100 | |
commit | ced6473e7486702f530a49f886b73195e4977734 (patch) | |
tree | f4622f9caeccd1c86f340a86508287ff68670a1d /include/linux/device.h | |
parent | kernfs: Declare two local data structures static (diff) | |
download | linux-ced6473e7486702f530a49f886b73195e4977734.tar.gz linux-ced6473e7486702f530a49f886b73195e4977734.tar.bz2 linux-ced6473e7486702f530a49f886b73195e4977734.zip |
driver core: class: add class_groups support
struct class needs to have a set of default groups that are added, as
adding individual attributes does not work well in the long run. So add
support for that.
Future patches will convert the existing usages of class_attrs to use
class_groups and then class_attrs will go away.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/device.h')
-rw-r--r-- | include/linux/device.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/device.h b/include/linux/device.h index 4264caacebb9..4cd8e52033b0 100644 --- a/include/linux/device.h +++ b/include/linux/device.h @@ -362,6 +362,7 @@ int subsys_virtual_register(struct bus_type *subsys, * @name: Name of the class. * @owner: The module owner. * @class_attrs: Default attributes of this class. + * @class_groups: Default attributes of this class. * @dev_groups: Default attributes of the devices that belong to the class. * @dev_kobj: The kobject that represents this class and links it into the hierarchy. * @dev_uevent: Called when a device is added, removed from this class, or a @@ -390,6 +391,7 @@ struct class { struct module *owner; struct class_attribute *class_attrs; + const struct attribute_group **class_groups; const struct attribute_group **dev_groups; struct kobject *dev_kobj; |