Lines Matching full:class

3  * The class-specific portions of the driver model
26 * struct class - device classes
27 * @name: Name of the class.
28 * @class_groups: Default attributes of this class.
29 * @dev_groups: Default attributes of the devices that belong to the class.
30 * @dev_uevent: Called when a device is added, removed from this class, or a
34 * @class_release: Called to release this class.
38 * @namespace: Namespace of the device belongs to this class.
39 * @get_ownership: Allows class to specify uid/gid of the sysfs directories
40 * for the devices belonging to the class. Usually tied to
42 * @pm: The default device power management operations of this class.
44 * A class is a higher-level view of a device that abstracts out low-level
46 * at the class level, they are all simply disks. Classes allow user space
50 struct class { struct
59 void (*class_release)(const struct class *class); argument
78 int __must_check class_register(const struct class *class); argument
79 void class_unregister(const struct class *class);
80 bool class_is_registered(const struct class *class);
88 void class_dev_iter_init(struct class_dev_iter *iter, const struct class *class,
93 int class_for_each_device(const struct class *class, const struct device *start,
95 struct device *class_find_device(const struct class *class, const struct device *start,
101 * @class: class type
104 static inline struct device *class_find_device_by_name(const struct class *class, in class_find_device_by_name() argument
107 return class_find_device(class, NULL, name, device_match_name); in class_find_device_by_name()
113 * @class: class type
116 static inline struct device *class_find_device_by_of_node(const struct class *class, in class_find_device_by_of_node() argument
119 return class_find_device(class, NULL, np, device_match_of_node); in class_find_device_by_of_node()
125 * @class: class type
128 static inline struct device *class_find_device_by_fwnode(const struct class *class, in class_find_device_by_fwnode() argument
131 return class_find_device(class, NULL, fwnode, device_match_fwnode); in class_find_device_by_fwnode()
137 * @class: class type
140 static inline struct device *class_find_device_by_devt(const struct class *class, in class_find_device_by_devt() argument
143 return class_find_device(class, NULL, &devt, device_match_devt); in class_find_device_by_devt()
151 * @class: class type
154 static inline struct device *class_find_device_by_acpi_dev(const struct class *class, in class_find_device_by_acpi_dev() argument
157 return class_find_device(class, NULL, adev, device_match_acpi_dev); in class_find_device_by_acpi_dev()
160 static inline struct device *class_find_device_by_acpi_dev(const struct class *class, in class_find_device_by_acpi_dev() argument
169 ssize_t (*show)(const struct class *class, const struct class_attribute *attr,
171 ssize_t (*store)(const struct class *class, const struct class_attribute *attr,
182 int __must_check class_create_file_ns(const struct class *class, const struct class_attribute *attr,
184 void class_remove_file_ns(const struct class *class, const struct class_attribute *attr,
187 static inline int __must_check class_create_file(const struct class *class, in class_create_file() argument
190 return class_create_file_ns(class, attr, NULL); in class_create_file()
193 static inline void class_remove_file(const struct class *class, in class_remove_file() argument
196 return class_remove_file_ns(class, attr, NULL); in class_remove_file()
199 /* Simple class attribute that is just a static string */
212 ssize_t show_class_attr_string(const struct class *class, const struct class_attribute *attr,
217 const struct class *class; member
226 struct class * __must_check class_create(const char *name);
227 void class_destroy(const struct class *cls);