diff options
author | Christoph Hellwig <hch@infradead.org> | 2010-03-03 09:05:07 -0500 |
---|---|---|
committer | Jan Kara <jack@suse.cz> | 2010-03-04 18:20:30 -0500 |
commit | 871a293155a24554e153538d36e3a80fa169aefb (patch) | |
tree | 7e38f5a2f9e87f63cbc4bc1077a4bb49dde441b0 /fs/ocfs2/namei.c | |
parent | 907f4554e2521cb28b0009d17167760650a9561c (diff) |
dquot: cleanup dquot initialize routine
Get rid of the initialize dquot operation - it is now always called from
the filesystem and if a filesystem really needs it's own (which none
currently does) it can just call into it's own routine directly.
Rename the now static low-level dquot_initialize helper to __dquot_initialize
and vfs_dq_init to dquot_initialize to have a consistent namespace.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'fs/ocfs2/namei.c')
-rw-r--r-- | fs/ocfs2/namei.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/fs/ocfs2/namei.c b/fs/ocfs2/namei.c index 8b5b142eb638..d9cd4e373a53 100644 --- a/fs/ocfs2/namei.c +++ b/fs/ocfs2/namei.c | |||
@@ -212,7 +212,7 @@ static struct inode *ocfs2_get_init_inode(struct inode *dir, int mode) | |||
212 | } else | 212 | } else |
213 | inode->i_gid = current_fsgid(); | 213 | inode->i_gid = current_fsgid(); |
214 | inode->i_mode = mode; | 214 | inode->i_mode = mode; |
215 | vfs_dq_init(inode); | 215 | dquot_initialize(inode); |
216 | return inode; | 216 | return inode; |
217 | } | 217 | } |
218 | 218 | ||
@@ -244,7 +244,7 @@ static int ocfs2_mknod(struct inode *dir, | |||
244 | (unsigned long)dev, dentry->d_name.len, | 244 | (unsigned long)dev, dentry->d_name.len, |
245 | dentry->d_name.name); | 245 | dentry->d_name.name); |
246 | 246 | ||
247 | vfs_dq_init(dir); | 247 | dquot_initialize(dir); |
248 | 248 | ||
249 | /* get our super block */ | 249 | /* get our super block */ |
250 | osb = OCFS2_SB(dir->i_sb); | 250 | osb = OCFS2_SB(dir->i_sb); |
@@ -634,7 +634,7 @@ static int ocfs2_link(struct dentry *old_dentry, | |||
634 | if (S_ISDIR(inode->i_mode)) | 634 | if (S_ISDIR(inode->i_mode)) |
635 | return -EPERM; | 635 | return -EPERM; |
636 | 636 | ||
637 | vfs_dq_init(dir); | 637 | dquot_initialize(dir); |
638 | 638 | ||
639 | err = ocfs2_inode_lock_nested(dir, &parent_fe_bh, 1, OI_LS_PARENT); | 639 | err = ocfs2_inode_lock_nested(dir, &parent_fe_bh, 1, OI_LS_PARENT); |
640 | if (err < 0) { | 640 | if (err < 0) { |
@@ -791,7 +791,7 @@ static int ocfs2_unlink(struct inode *dir, | |||
791 | mlog_entry("(0x%p, 0x%p, '%.*s')\n", dir, dentry, | 791 | mlog_entry("(0x%p, 0x%p, '%.*s')\n", dir, dentry, |
792 | dentry->d_name.len, dentry->d_name.name); | 792 | dentry->d_name.len, dentry->d_name.name); |
793 | 793 | ||
794 | vfs_dq_init(dir); | 794 | dquot_initialize(dir); |
795 | 795 | ||
796 | BUG_ON(dentry->d_parent->d_inode != dir); | 796 | BUG_ON(dentry->d_parent->d_inode != dir); |
797 | 797 | ||
@@ -1053,8 +1053,8 @@ static int ocfs2_rename(struct inode *old_dir, | |||
1053 | old_dentry->d_name.len, old_dentry->d_name.name, | 1053 | old_dentry->d_name.len, old_dentry->d_name.name, |
1054 | new_dentry->d_name.len, new_dentry->d_name.name); | 1054 | new_dentry->d_name.len, new_dentry->d_name.name); |
1055 | 1055 | ||
1056 | vfs_dq_init(old_dir); | 1056 | dquot_initialize(old_dir); |
1057 | vfs_dq_init(new_dir); | 1057 | dquot_initialize(new_dir); |
1058 | 1058 | ||
1059 | osb = OCFS2_SB(old_dir->i_sb); | 1059 | osb = OCFS2_SB(old_dir->i_sb); |
1060 | 1060 | ||
@@ -1604,7 +1604,7 @@ static int ocfs2_symlink(struct inode *dir, | |||
1604 | mlog_entry("(0x%p, 0x%p, symname='%s' actual='%.*s')\n", dir, | 1604 | mlog_entry("(0x%p, 0x%p, symname='%s' actual='%.*s')\n", dir, |
1605 | dentry, symname, dentry->d_name.len, dentry->d_name.name); | 1605 | dentry, symname, dentry->d_name.len, dentry->d_name.name); |
1606 | 1606 | ||
1607 | vfs_dq_init(dir); | 1607 | dquot_initialize(dir); |
1608 | 1608 | ||
1609 | sb = dir->i_sb; | 1609 | sb = dir->i_sb; |
1610 | osb = OCFS2_SB(sb); | 1610 | osb = OCFS2_SB(sb); |