diff options
Diffstat (limited to 'fs/kernfs/mount.c')
-rw-r--r-- | fs/kernfs/mount.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/fs/kernfs/mount.c b/fs/kernfs/mount.c index 27d967ba0bb9..0d6ce895a9ee 100644 --- a/fs/kernfs/mount.c +++ b/fs/kernfs/mount.c | |||
@@ -22,10 +22,10 @@ struct kmem_cache *kernfs_node_cache; | |||
22 | static const struct super_operations kernfs_sops = { | 22 | static const struct super_operations kernfs_sops = { |
23 | .statfs = simple_statfs, | 23 | .statfs = simple_statfs, |
24 | .drop_inode = generic_delete_inode, | 24 | .drop_inode = generic_delete_inode, |
25 | .evict_inode = sysfs_evict_inode, | 25 | .evict_inode = kernfs_evict_inode, |
26 | }; | 26 | }; |
27 | 27 | ||
28 | static int sysfs_fill_super(struct super_block *sb) | 28 | static int kernfs_fill_super(struct super_block *sb) |
29 | { | 29 | { |
30 | struct kernfs_super_info *info = kernfs_info(sb); | 30 | struct kernfs_super_info *info = kernfs_info(sb); |
31 | struct inode *inode; | 31 | struct inode *inode; |
@@ -39,10 +39,10 @@ static int sysfs_fill_super(struct super_block *sb) | |||
39 | 39 | ||
40 | /* get root inode, initialize and unlock it */ | 40 | /* get root inode, initialize and unlock it */ |
41 | mutex_lock(&kernfs_mutex); | 41 | mutex_lock(&kernfs_mutex); |
42 | inode = sysfs_get_inode(sb, info->root->kn); | 42 | inode = kernfs_get_inode(sb, info->root->kn); |
43 | mutex_unlock(&kernfs_mutex); | 43 | mutex_unlock(&kernfs_mutex); |
44 | if (!inode) { | 44 | if (!inode) { |
45 | pr_debug("sysfs: could not get root inode\n"); | 45 | pr_debug("kernfs: could not get root inode\n"); |
46 | return -ENOMEM; | 46 | return -ENOMEM; |
47 | } | 47 | } |
48 | 48 | ||
@@ -59,7 +59,7 @@ static int sysfs_fill_super(struct super_block *sb) | |||
59 | return 0; | 59 | return 0; |
60 | } | 60 | } |
61 | 61 | ||
62 | static int sysfs_test_super(struct super_block *sb, void *data) | 62 | static int kernfs_test_super(struct super_block *sb, void *data) |
63 | { | 63 | { |
64 | struct kernfs_super_info *sb_info = kernfs_info(sb); | 64 | struct kernfs_super_info *sb_info = kernfs_info(sb); |
65 | struct kernfs_super_info *info = data; | 65 | struct kernfs_super_info *info = data; |
@@ -67,7 +67,7 @@ static int sysfs_test_super(struct super_block *sb, void *data) | |||
67 | return sb_info->root == info->root && sb_info->ns == info->ns; | 67 | return sb_info->root == info->root && sb_info->ns == info->ns; |
68 | } | 68 | } |
69 | 69 | ||
70 | static int sysfs_set_super(struct super_block *sb, void *data) | 70 | static int kernfs_set_super(struct super_block *sb, void *data) |
71 | { | 71 | { |
72 | int error; | 72 | int error; |
73 | error = set_anon_super(sb, data); | 73 | error = set_anon_super(sb, data); |
@@ -117,13 +117,13 @@ struct dentry *kernfs_mount_ns(struct file_system_type *fs_type, int flags, | |||
117 | info->root = root; | 117 | info->root = root; |
118 | info->ns = ns; | 118 | info->ns = ns; |
119 | 119 | ||
120 | sb = sget(fs_type, sysfs_test_super, sysfs_set_super, flags, info); | 120 | sb = sget(fs_type, kernfs_test_super, kernfs_set_super, flags, info); |
121 | if (IS_ERR(sb) || sb->s_fs_info != info) | 121 | if (IS_ERR(sb) || sb->s_fs_info != info) |
122 | kfree(info); | 122 | kfree(info); |
123 | if (IS_ERR(sb)) | 123 | if (IS_ERR(sb)) |
124 | return ERR_CAST(sb); | 124 | return ERR_CAST(sb); |
125 | if (!sb->s_root) { | 125 | if (!sb->s_root) { |
126 | error = sysfs_fill_super(sb); | 126 | error = kernfs_fill_super(sb); |
127 | if (error) { | 127 | if (error) { |
128 | deactivate_locked_super(sb); | 128 | deactivate_locked_super(sb); |
129 | return ERR_PTR(error); | 129 | return ERR_PTR(error); |
@@ -161,5 +161,5 @@ void __init kernfs_init(void) | |||
161 | kernfs_node_cache = kmem_cache_create("kernfs_node_cache", | 161 | kernfs_node_cache = kmem_cache_create("kernfs_node_cache", |
162 | sizeof(struct kernfs_node), | 162 | sizeof(struct kernfs_node), |
163 | 0, SLAB_PANIC, NULL); | 163 | 0, SLAB_PANIC, NULL); |
164 | sysfs_inode_init(); | 164 | kernfs_inode_init(); |
165 | } | 165 | } |