patch-2.1.128 linux/fs/super.c

Next file: linux/fs/sysv/dir.c
Previous file: linux/fs/smbfs/file.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.127/linux/fs/super.c linux/fs/super.c
@@ -33,6 +33,7 @@
 #include <linux/fd.h>
 #include <linux/init.h>
 #include <linux/quotaops.h>
+#include <linux/acct.h>
 
 #include <asm/system.h>
 #include <asm/uaccess.h>
@@ -663,10 +664,7 @@
 	 * are no quotas running any more. Just turn them on again.
 	 */
 	DQUOT_OFF(dev);
-
-#ifdef CONFIG_BSD_PROCESS_ACCT
-	(void) acct_auto_close(dev);
-#endif
+	acct_auto_close(dev);
 
 	/*
 	 * If we may have to abort operations to get out of this
@@ -971,6 +969,8 @@
 			 */
 			shrink_dcache_sb(sb);
 			fsync_dev(sb->s_dev);
+			if (flags & MS_RDONLY)
+				acct_auto_close(sb->s_dev);
 			retval = do_remount_sb(sb, flags, data);
 		}
 		dput(dentry);

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov