aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/acct.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/acct.c')
-rw-r--r--kernel/acct.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/kernel/acct.c b/kernel/acct.c
index 69a40c9777a2..70d0d88e5554 100644
--- a/kernel/acct.c
+++ b/kernel/acct.c
@@ -118,7 +118,7 @@ static int check_free_space(struct file *file)
118 spin_unlock(&acct_globals.lock); 118 spin_unlock(&acct_globals.lock);
119 119
120 /* May block */ 120 /* May block */
121 if (vfs_statfs(file->f_dentry, &sbuf)) 121 if (vfs_statfs(file->f_path.dentry, &sbuf))
122 return res; 122 return res;
123 suspend = sbuf.f_blocks * SUSPEND; 123 suspend = sbuf.f_blocks * SUSPEND;
124 resume = sbuf.f_blocks * RESUME; 124 resume = sbuf.f_blocks * RESUME;
@@ -194,7 +194,7 @@ static void acct_file_reopen(struct file *file)
194 add_timer(&acct_globals.timer); 194 add_timer(&acct_globals.timer);
195 } 195 }
196 if (old_acct) { 196 if (old_acct) {
197 mnt_unpin(old_acct->f_vfsmnt); 197 mnt_unpin(old_acct->f_path.mnt);
198 spin_unlock(&acct_globals.lock); 198 spin_unlock(&acct_globals.lock);
199 do_acct_process(old_acct); 199 do_acct_process(old_acct);
200 filp_close(old_acct, NULL); 200 filp_close(old_acct, NULL);
@@ -212,7 +212,7 @@ static int acct_on(char *name)
212 if (IS_ERR(file)) 212 if (IS_ERR(file))
213 return PTR_ERR(file); 213 return PTR_ERR(file);
214 214
215 if (!S_ISREG(file->f_dentry->d_inode->i_mode)) { 215 if (!S_ISREG(file->f_path.dentry->d_inode->i_mode)) {
216 filp_close(file, NULL); 216 filp_close(file, NULL);
217 return -EACCES; 217 return -EACCES;
218 } 218 }
@@ -229,11 +229,11 @@ static int acct_on(char *name)
229 } 229 }
230 230
231 spin_lock(&acct_globals.lock); 231 spin_lock(&acct_globals.lock);
232 mnt_pin(file->f_vfsmnt); 232 mnt_pin(file->f_path.mnt);
233 acct_file_reopen(file); 233 acct_file_reopen(file);
234 spin_unlock(&acct_globals.lock); 234 spin_unlock(&acct_globals.lock);
235 235
236 mntput(file->f_vfsmnt); /* it's pinned, now give up active reference */ 236 mntput(file->f_path.mnt); /* it's pinned, now give up active reference */
237 237
238 return 0; 238 return 0;
239} 239}
@@ -283,7 +283,7 @@ asmlinkage long sys_acct(const char __user *name)
283void acct_auto_close_mnt(struct vfsmount *m) 283void acct_auto_close_mnt(struct vfsmount *m)
284{ 284{
285 spin_lock(&acct_globals.lock); 285 spin_lock(&acct_globals.lock);
286 if (acct_globals.file && acct_globals.file->f_vfsmnt == m) 286 if (acct_globals.file && acct_globals.file->f_path.mnt == m)
287 acct_file_reopen(NULL); 287 acct_file_reopen(NULL);
288 spin_unlock(&acct_globals.lock); 288 spin_unlock(&acct_globals.lock);
289} 289}
@@ -299,7 +299,7 @@ void acct_auto_close(struct super_block *sb)
299{ 299{
300 spin_lock(&acct_globals.lock); 300 spin_lock(&acct_globals.lock);
301 if (acct_globals.file && 301 if (acct_globals.file &&
302 acct_globals.file->f_vfsmnt->mnt_sb == sb) { 302 acct_globals.file->f_path.mnt->mnt_sb == sb) {
303 acct_file_reopen(NULL); 303 acct_file_reopen(NULL);
304 } 304 }
305 spin_unlock(&acct_globals.lock); 305 spin_unlock(&acct_globals.lock);