aboutsummaryrefslogtreecommitdiffstats
path: root/fs/configfs
diff options
context:
space:
mode:
authorSteven Whitehouse <swhiteho@redhat.com>2006-07-03 10:25:08 -0400
committerSteven Whitehouse <swhiteho@redhat.com>2006-07-03 10:25:08 -0400
commit0a1340c185734a57fbf4775927966ad4a1347b02 (patch)
treed9ed8f0dd809a7c542a3356601125ea5b5aaa804 /fs/configfs
parentaf18ddb8864b096e3ed4732e2d4b21c956dcfe3a (diff)
parent29454dde27d8e340bb1987bad9aa504af7081eba (diff)
Merge rsync://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
Conflicts: include/linux/kernel.h
Diffstat (limited to 'fs/configfs')
-rw-r--r--fs/configfs/dir.c12
-rw-r--r--fs/configfs/inode.c2
-rw-r--r--fs/configfs/mount.c8
-rw-r--r--fs/configfs/symlink.c2
4 files changed, 11 insertions, 13 deletions
diff --git a/fs/configfs/dir.c b/fs/configfs/dir.c
index 5f952187fc53..df025453dd97 100644
--- a/fs/configfs/dir.c
+++ b/fs/configfs/dir.c
@@ -211,7 +211,7 @@ static void remove_dir(struct dentry * d)
211 struct configfs_dirent * sd; 211 struct configfs_dirent * sd;
212 212
213 sd = d->d_fsdata; 213 sd = d->d_fsdata;
214 list_del_init(&sd->s_sibling); 214 list_del_init(&sd->s_sibling);
215 configfs_put(sd); 215 configfs_put(sd);
216 if (d->d_inode) 216 if (d->d_inode)
217 simple_rmdir(parent->d_inode,d); 217 simple_rmdir(parent->d_inode,d);
@@ -330,7 +330,7 @@ static int configfs_detach_prep(struct dentry *dentry)
330 330
331 ret = configfs_detach_prep(sd->s_dentry); 331 ret = configfs_detach_prep(sd->s_dentry);
332 if (!ret) 332 if (!ret)
333 continue; 333 continue;
334 } else 334 } else
335 ret = -ENOTEMPTY; 335 ret = -ENOTEMPTY;
336 336
@@ -931,7 +931,7 @@ int configfs_rename_dir(struct config_item * item, const char *new_name)
931 931
932 new_dentry = lookup_one_len(new_name, parent, strlen(new_name)); 932 new_dentry = lookup_one_len(new_name, parent, strlen(new_name));
933 if (!IS_ERR(new_dentry)) { 933 if (!IS_ERR(new_dentry)) {
934 if (!new_dentry->d_inode) { 934 if (!new_dentry->d_inode) {
935 error = config_item_set_name(item, "%s", new_name); 935 error = config_item_set_name(item, "%s", new_name);
936 if (!error) { 936 if (!error) {
937 d_add(new_dentry, NULL); 937 d_add(new_dentry, NULL);
@@ -1009,8 +1009,7 @@ static int configfs_readdir(struct file * filp, void * dirent, filldir_t filldir
1009 /* fallthrough */ 1009 /* fallthrough */
1010 default: 1010 default:
1011 if (filp->f_pos == 2) { 1011 if (filp->f_pos == 2) {
1012 list_del(q); 1012 list_move(q, &parent_sd->s_children);
1013 list_add(q, &parent_sd->s_children);
1014 } 1013 }
1015 for (p=q->next; p!= &parent_sd->s_children; p=p->next) { 1014 for (p=q->next; p!= &parent_sd->s_children; p=p->next) {
1016 struct configfs_dirent *next; 1015 struct configfs_dirent *next;
@@ -1033,8 +1032,7 @@ static int configfs_readdir(struct file * filp, void * dirent, filldir_t filldir
1033 dt_type(next)) < 0) 1032 dt_type(next)) < 0)
1034 return 0; 1033 return 0;
1035 1034
1036 list_del(q); 1035 list_move(q, p);
1037 list_add(q, p);
1038 p = q; 1036 p = q;
1039 filp->f_pos++; 1037 filp->f_pos++;
1040 } 1038 }
diff --git a/fs/configfs/inode.c b/fs/configfs/inode.c
index c153bd9534cb..e14488ca6411 100644
--- a/fs/configfs/inode.c
+++ b/fs/configfs/inode.c
@@ -38,7 +38,7 @@
38 38
39extern struct super_block * configfs_sb; 39extern struct super_block * configfs_sb;
40 40
41static struct address_space_operations configfs_aops = { 41static const struct address_space_operations configfs_aops = {
42 .readpage = simple_readpage, 42 .readpage = simple_readpage,
43 .prepare_write = simple_prepare_write, 43 .prepare_write = simple_prepare_write,
44 .commit_write = simple_commit_write 44 .commit_write = simple_commit_write
diff --git a/fs/configfs/mount.c b/fs/configfs/mount.c
index f920d30478e5..3e5fe843e1df 100644
--- a/fs/configfs/mount.c
+++ b/fs/configfs/mount.c
@@ -103,10 +103,10 @@ static int configfs_fill_super(struct super_block *sb, void *data, int silent)
103 return 0; 103 return 0;
104} 104}
105 105
106static struct super_block *configfs_get_sb(struct file_system_type *fs_type, 106static int configfs_get_sb(struct file_system_type *fs_type,
107 int flags, const char *dev_name, void *data) 107 int flags, const char *dev_name, void *data, struct vfsmount *mnt)
108{ 108{
109 return get_sb_single(fs_type, flags, data, configfs_fill_super); 109 return get_sb_single(fs_type, flags, data, configfs_fill_super, mnt);
110} 110}
111 111
112static struct file_system_type configfs_fs_type = { 112static struct file_system_type configfs_fs_type = {
@@ -118,7 +118,7 @@ static struct file_system_type configfs_fs_type = {
118 118
119int configfs_pin_fs(void) 119int configfs_pin_fs(void)
120{ 120{
121 return simple_pin_fs("configfs", &configfs_mount, 121 return simple_pin_fs(&configfs_fs_type, &configfs_mount,
122 &configfs_mnt_count); 122 &configfs_mnt_count);
123} 123}
124 124
diff --git a/fs/configfs/symlink.c b/fs/configfs/symlink.c
index e5512e295cf2..fb65e0800a86 100644
--- a/fs/configfs/symlink.c
+++ b/fs/configfs/symlink.c
@@ -66,7 +66,7 @@ static void fill_item_path(struct config_item * item, char * buffer, int length)
66} 66}
67 67
68static int create_link(struct config_item *parent_item, 68static int create_link(struct config_item *parent_item,
69 struct config_item *item, 69 struct config_item *item,
70 struct dentry *dentry) 70 struct dentry *dentry)
71{ 71{
72 struct configfs_dirent *target_sd = item->ci_dentry->d_fsdata; 72 struct configfs_dirent *target_sd = item->ci_dentry->d_fsdata;