• Home
  • Raw
  • Download

Lines Matching refs:grp

21 			 const struct attribute_group *grp)  in remove_files()  argument
26 if (grp->attrs) in remove_files()
27 for (attr = grp->attrs; *attr; attr++) in remove_files()
29 if (grp->bin_attrs) in remove_files()
30 for (bin_attr = grp->bin_attrs; *bin_attr; bin_attr++) in remove_files()
36 const struct attribute_group *grp, int update) in create_files() argument
42 if (grp->attrs) { in create_files()
43 for (i = 0, attr = grp->attrs; *attr && !error; i++, attr++) { in create_files()
53 if (grp->is_visible) { in create_files()
54 mode = grp->is_visible(kobj, *attr, i); in create_files()
70 remove_files(parent, grp); in create_files()
75 if (grp->bin_attrs) { in create_files()
76 for (i = 0, bin_attr = grp->bin_attrs; *bin_attr; i++, bin_attr++) { in create_files()
82 if (grp->is_bin_visible) { in create_files()
83 mode = grp->is_bin_visible(kobj, *bin_attr, i); in create_files()
101 remove_files(parent, grp); in create_files()
109 const struct attribute_group *grp) in internal_create_group() argument
122 if (!grp->attrs && !grp->bin_attrs) { in internal_create_group()
124 kobj->name, grp->name ?: ""); in internal_create_group()
128 if (grp->name) { in internal_create_group()
130 kn = kernfs_find_and_get(kobj->sd, grp->name); in internal_create_group()
133 kobj->name, grp->name); in internal_create_group()
137 kn = kernfs_create_dir_ns(kobj->sd, grp->name, in internal_create_group()
142 sysfs_warn_dup(kobj->sd, grp->name); in internal_create_group()
149 error = create_files(kn, kobj, uid, gid, grp, update); in internal_create_group()
151 if (grp->name) in internal_create_group()
156 if (grp->name && update) in internal_create_group()
173 const struct attribute_group *grp) in sysfs_create_group() argument
175 return internal_create_group(kobj, 0, grp); in sysfs_create_group()
256 const struct attribute_group *grp) in sysfs_update_group() argument
258 return internal_create_group(kobj, 1, grp); in sysfs_update_group()
271 const struct attribute_group *grp) in sysfs_remove_group() argument
276 if (grp->name) { in sysfs_remove_group()
277 kn = kernfs_find_and_get(parent, grp->name); in sysfs_remove_group()
281 grp->name, kobject_name(kobj)); in sysfs_remove_group()
289 remove_files(kn, grp); in sysfs_remove_group()
290 if (grp->name) in sysfs_remove_group()
327 const struct attribute_group *grp) in sysfs_merge_group() argument
336 parent = kernfs_find_and_get(kobj->sd, grp->name); in sysfs_merge_group()
342 for ((i = 0, attr = grp->attrs); *attr && !error; (++i, ++attr)) in sysfs_merge_group()
361 const struct attribute_group *grp) in sysfs_unmerge_group() argument
366 parent = kernfs_find_and_get(kobj->sd, grp->name); in sysfs_unmerge_group()
368 for (attr = grp->attrs; *attr; ++attr) in sysfs_unmerge_group()
469 const struct attribute_group *grp, in sysfs_group_attrs_change_owner() argument
475 if (grp->attrs) { in sysfs_group_attrs_change_owner()
478 for (attr = grp->attrs; *attr; attr++) { in sysfs_group_attrs_change_owner()
490 if (grp->bin_attrs) { in sysfs_group_attrs_change_owner()
493 for (bin_attr = grp->bin_attrs; *bin_attr; bin_attr++) { in sysfs_group_attrs_change_owner()
518 const struct attribute_group *grp, kuid_t kuid, in sysfs_group_change_owner() argument
532 if (grp->name) { in sysfs_group_change_owner()
533 grp_kn = kernfs_find_and_get(kobj->sd, grp->name); in sysfs_group_change_owner()
543 error = sysfs_group_attrs_change_owner(grp_kn, grp, &newattrs); in sysfs_group_change_owner()