diff options
author | Maneesh Soni <maneesh@in.ibm.com> | 2005-05-31 10:39:52 +0530 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2005-06-20 15:15:37 -0700 |
commit | 8215534ce7d073423bfa9c17405c43ab7636ca03 (patch) | |
tree | b53aed1111cf10a7d42ef0695308c4a70b820747 /fs/sysfs/mount.c | |
parent | 988d186de5b6966a71a8cc52e6cb4895fd2f7799 (diff) | |
download | kernel_samsung_tuna-8215534ce7d073423bfa9c17405c43ab7636ca03.zip kernel_samsung_tuna-8215534ce7d073423bfa9c17405c43ab7636ca03.tar.gz kernel_samsung_tuna-8215534ce7d073423bfa9c17405c43ab7636ca03.tar.bz2 |
[PATCH] sysfs-iattr: set inode attributes
o Following patch sets the attributes for newly allocated inodes for sysfs
objects. If the object has non-default attributes, inode attributes are
set as saved in sysfs_dirent->s_iattr, pointer to struct iattr.
Signed-off-by: Maneesh Soni <maneesh@in.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'fs/sysfs/mount.c')
-rw-r--r-- | fs/sysfs/mount.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/sysfs/mount.c b/fs/sysfs/mount.c index 5c805bb..f1117e8 100644 --- a/fs/sysfs/mount.c +++ b/fs/sysfs/mount.c @@ -28,6 +28,7 @@ static struct sysfs_dirent sysfs_root = { .s_children = LIST_HEAD_INIT(sysfs_root.s_children), .s_element = NULL, .s_type = SYSFS_ROOT, + .s_iattr = NULL, }; static int sysfs_fill_super(struct super_block *sb, void *data, int silent) @@ -42,7 +43,8 @@ static int sysfs_fill_super(struct super_block *sb, void *data, int silent) sb->s_time_gran = 1; sysfs_sb = sb; - inode = sysfs_new_inode(S_IFDIR | S_IRWXU | S_IRUGO | S_IXUGO); + inode = sysfs_new_inode(S_IFDIR | S_IRWXU | S_IRUGO | S_IXUGO, + &sysfs_root); if (inode) { inode->i_op = &sysfs_dir_inode_operations; inode->i_fop = &sysfs_dir_operations; |