mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* A little bug in quotas ext3 2.6.3-rc3-mm1 patch
@ 2004-02-17 12:30 Vincent ROQUETA
  0 siblings, 0 replies; only message in thread
From: Vincent ROQUETA @ 2004-02-17 12:30 UTC (permalink / raw)
  To: linux-kernel

kernel patch 2.6.3-rc3-mm1

file : /fs/ext3/super.c

+static int
+ext3_quota_on(struct super_block *sb, int type, int format_id, char *path)
+{
+       int err;
+       struct nameidata nd;
+
+       if (!EXT3_SB(sb)->s_qf_names[0] && !EXT3_SB(sb)->s_qf_names[1]) {
+               /* Not journalling quota? */
+               return vfs_quota_on(sb, type, format_id, path);
+       }
+       err = path_lookup(path, LOOKUP_FOLLOW, &nd);
+       if (err)
+               return err;
+       if (nd.mnt->mnt_sb != sb)       /* Quotafile not on the same fs? */
+               return -EXDEV;
+       if (nd.dentry->d_parent->d_inode != sb->s_root->d_inode) {
+               /* Quotafile not of fs root? */
+               printk(KERN_WARNING "EXT3-fs: Quota file not on filesystem "
+                               "root. Journalled quota will not work\n");

	} /* Close if ...*/


+       if (!ext3_should_journal_data(nd.dentry->d_inode))
+               printk(KERN_WARNING "EXT3-fs: Quota file does not have "
+                       "data-journalling. Journalled quota will not
 work\n"); +       path_release(&nd);
+       return vfs_quota_on(sb, type, format_id, path);
+}
+
 #endif

-------------------------------------------------------


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2004-02-17 12:40 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-02-17 12:30 A little bug in quotas ext3 2.6.3-rc3-mm1 patch Vincent ROQUETA

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®