Skip to content

Commit

Permalink
s390/sclp_sd: use default_groups in kobj_type
Browse files Browse the repository at this point in the history
There are currently 2 ways to create a set of sysfs files for a
kobj_type, through the default_attrs field, and the default_groups
field.  Move the sclp_sd sysfs code to use default_groups field which
has been the preferred way since commit aa30f47 ("kobject: Add
support for default attribute groups to kobj_type") so that we can
soon get rid of the obsolete default_attrs field.

Cc: Vasily Gorbik <[email protected]>
Cc: Christian Borntraeger <[email protected]>
Cc: Alexander Gordeev <[email protected]>
Cc: Peter Oberparleiter <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Heiko Carstens <[email protected]>
  • Loading branch information
gregkh authored and hcahca committed Jan 8, 2022
1 parent 7b29321 commit 1350f36
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/s390/char/sclp_sd.c
Original file line number Diff line number Diff line change
Expand Up @@ -438,11 +438,12 @@ static struct attribute *sclp_sd_file_default_attrs[] = {
&reload_attr.attr,
NULL,
};
ATTRIBUTE_GROUPS(sclp_sd_file_default);

static struct kobj_type sclp_sd_file_ktype = {
.sysfs_ops = &kobj_sysfs_ops,
.release = sclp_sd_file_release,
.default_attrs = sclp_sd_file_default_attrs,
.default_groups = sclp_sd_file_default_groups,
};

/**
Expand Down

0 comments on commit 1350f36

Please sign in to comment.