linux-hardened/fs/kernfs
Tejun Heo 9a8049affd kernfs: update sysfs_init_inode_attrs()
sysfs_init_inode_attrs() is a bit clumsy to use requiring the caller
to check whether @sd->s_iattr is already set or not.  Rename it to
sysfs_inode_attrs(), update it to check whether @sd->s_iattr is
already initialized before trying to initialize it and return
@sd->s_iattr.  This simplifies the callers.

While at it,

* Rename struct sysfs_inode_attrs pointer variables to "attrs".  As
  kernfs no longer deals with "struct attribute", this isn't confusing
  and makes it easier to distinguish from struct iattr pointers.

* A new field will be added to sysfs_inode_attrs.  Reindent in
  preparation.

This patch doesn't introduce any behavior changes.

Signed-off-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-04 07:34:45 -08:00
..
dir.c sysfs, kernfs: implement kernfs_ns_enabled() 2013-11-29 18:41:28 -08:00
file.c sysfs, kernfs: make inode number ida per kernfs_root 2013-11-29 18:10:48 -08:00
inode.c kernfs: update sysfs_init_inode_attrs() 2013-12-04 07:34:45 -08:00
kernfs-internal.h kernfs: update sysfs_init_inode_attrs() 2013-12-04 07:34:45 -08:00
Makefile sysfs, kernfs: add skeletons for kernfs 2013-11-27 13:28:24 -08:00
mount.c sysfs, kernfs: move mount core code to fs/kernfs/mount.c 2013-11-29 18:16:08 -08:00
symlink.c sysfs, kernfs: implement kernfs_ns_enabled() 2013-11-29 18:41:28 -08:00