Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

f2fs: replace ktype default_attrs with default_groups

The kobj_type default_attrs field is being replaced by the
default_groups field. Replace the default_attrs fields in f2fs_sb_ktype
and f2fs_feat_ktype with default_groups. Use the ATTRIBUTE_GROUPS macro
to create f2fs_groups and f2fs_feat_groups.

Signed-off-by: Kimberly Brown <kimbrownkd@gmail.com>
Reviewed-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Kimberly Brown and committed by
Greg Kroah-Hartman
dad4afe7 c9c5b5e1

+4 -2
+4 -2
fs/f2fs/sysfs.c
··· 501 501 ATTR_LIST(current_reserved_blocks), 502 502 NULL, 503 503 }; 504 + ATTRIBUTE_GROUPS(f2fs); 504 505 505 506 static struct attribute *f2fs_feat_attrs[] = { 506 507 #ifdef CONFIG_FS_ENCRYPTION ··· 521 520 ATTR_LIST(sb_checksum), 522 521 NULL, 523 522 }; 523 + ATTRIBUTE_GROUPS(f2fs_feat); 524 524 525 525 static const struct sysfs_ops f2fs_attr_ops = { 526 526 .show = f2fs_attr_show, ··· 529 527 }; 530 528 531 529 static struct kobj_type f2fs_sb_ktype = { 532 - .default_attrs = f2fs_attrs, 530 + .default_groups = f2fs_groups, 533 531 .sysfs_ops = &f2fs_attr_ops, 534 532 .release = f2fs_sb_release, 535 533 }; ··· 543 541 }; 544 542 545 543 static struct kobj_type f2fs_feat_ktype = { 546 - .default_attrs = f2fs_feat_attrs, 544 + .default_groups = f2fs_feat_groups, 547 545 .sysfs_ops = &f2fs_attr_ops, 548 546 }; 549 547