[PATCH] Quota-tools support for ext4

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



quota-tools has support for ext4dev filesystem already (at least in
v3.16) . But it seems still missing the ext4 filesystem support which
prevent quotacheck recognizes the ext4 filesystem.  The following patch
fixed it for me.

Signed-off-by: Mingming Cao <cmm@xxxxxxxxxx>

Index: quota-tools/mntopt.h
===================================================================
--- quota-tools.orig/mntopt.h	2007-08-22 04:26:55.000000000 -0700
+++ quota-tools/mntopt.h	2008-10-29 16:37:57.000000000 -0700
@@ -6,7 +6,8 @@
 /* filesystem type */
 #define MNTTYPE_EXT2		"ext2"	/* 2nd Extended file system */
 #define MNTTYPE_EXT3		"ext3"	/* ext2 + journaling */
-#define MNTTYPE_EXT4		"ext4dev"	/* ext4 filesystem */
+#define MNTTYPE_EXT4		"ext4"	/* ext4 filesystem */
+#define MNTTYPE_EXT4DEV		"ext4dev"/* ext4dev filesystem */
 #define MNTTYPE_MINIX		"minix"	/* MINIX file system */
 #define MNTTYPE_UFS		"ufs"	/* UNIX file system */
 #define MNTTYPE_UDF		"udf"	/* OSTA UDF file system */
Index: quota-tools/quotacheck.c
===================================================================
--- quota-tools.orig/quotacheck.c	2008-10-29 16:38:50.000000000 -0700
+++ quota-tools/quotacheck.c	2008-10-29 16:39:09.000000000 -0700
@@ -1064,6 +1064,7 @@ static void check_all(void)
 		    !hasmntopt(mnt, MNTOPT_GRPJQUOTA) && !warned &&
 		    (!strcmp(mnt->mnt_type, MNTTYPE_EXT3) ||
 		     !strcmp(mnt->mnt_type, MNTTYPE_EXT4) ||
+		     !strcmp(mnt->mnt_type, MNTTYPE_EXT4DEV) ||
 		     !strcmp(mnt->mnt_type, MNTTYPE_REISER))) {
 			struct utsname stats;
 
Index: quota-tools/quotasys.c
===================================================================
--- quota-tools.orig/quotasys.c	2008-10-29 16:39:45.000000000 -0700
+++ quota-tools/quotasys.c	2008-10-29 16:40:01.000000000 -0700
@@ -63,6 +63,7 @@ static int correct_fstype(char *type)
 		if (!strcmp(type, MNTTYPE_EXT2) ||
 		    !strcmp(type, MNTTYPE_EXT3) ||
 		    !strcmp(type, MNTTYPE_EXT4) ||
+		    !strcmp(type, MNTTYPE_EXT4DEV) ||
 		    !strcmp(type, MNTTYPE_JFS) ||
 		    !strcmp(type, MNTTYPE_MINIX) ||
 		    !strcmp(type, MNTTYPE_UFS) ||


--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux