Skip to contentSkip to conversation

: Ext2/3 updates: Cleanup: Eliminate EXT3/2_DEF_RES[UG]ID

PATCH New [email protected] 1 participant 1 message Nov 12, 2002 ext2 file system

lore
Share & tools
lore
#0 lore raw

PATCH 2/4 : Ext2/3 updates: Cleanup: Eliminate EXT3/2_DEF_RES[UG]ID

Cleanup: Eliminate EXT3/2_DEF_RES[UG]ID

Remove dead code. Resuid and resgid (the user and group that is allowed to allocate the last reserved_blocks worth of blocks on the filesystem) can never be specified at compile time; the value in the superblock is used, unless overidden by a mount option. EXT3_DEF_RES[UG]ID is vestigal, and should have been removed when the corresponding fields were added to the superblock. (In ext2fs, the code was removed in an earlier cleanup, but the header file definitions weren't cleaned up.)

fs/ext3/super.c         |    3 ---
include/linux/ext2_fs.h |    6 ------
include/linux/ext3_fs.h |    6 ------
3 files changed, 15 deletions(-)
fs/ext3/super.c +0 -3
diff -Nru a/fs/ext3/super.c b/fs/ext3/super.c
@@ -1018,9 +1018,6 @@
 		return -ENOMEM;
 	sb->s_fs_info = sbi;
 	memset(sbi, 0, sizeof(*sbi));
-	sbi->s_mount_opt = 0;
-	sbi->s_resuid = EXT3_DEF_RESUID;
-	sbi->s_resgid = EXT3_DEF_RESGID;
 	setup_ro_after(sb);
 
 	blocksize = sb_min_blocksize(sb, EXT3_MIN_BLOCK_SIZE);
include/linux/ext2_fs.h +0 -6
diff -Nru a/include/linux/ext2_fs.h b/include/linux/ext2_fs.h
@@ -478,12 +478,6 @@
 #define EXT2_FEATURE_INCOMPAT_UNSUPPORTED	~EXT2_FEATURE_INCOMPAT_SUPP
 
 /*
- * Default values for user and/or group using reserved blocks
- */
-#define	EXT2_DEF_RESUID		0
-#define	EXT2_DEF_RESGID		0
-
-/*
  * Default mount options
  */
 #define EXT2_DEFM_DEBUG		0x0001
include/linux/ext3_fs.h +0 -6
diff -Nru a/include/linux/ext3_fs.h b/include/linux/ext3_fs.h
@@ -521,12 +521,6 @@
 					 EXT3_FEATURE_RO_COMPAT_BTREE_DIR)
 
 /*
- * Default values for user and/or group using reserved blocks
- */
-#define	EXT3_DEF_RESUID		0
-#define	EXT3_DEF_RESGID		0
-
-/*
  * Default mount options
  */
 #define EXT3_DEFM_DEBUG		0x0001