Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

fat: use new setup() for ->dir_ops too

Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>

+6 -9
+1 -2
fs/fat/fat.h
··· 319 319 struct msdos_dir_entry *de, loff_t i_pos); 320 320 extern int fat_sync_inode(struct inode *inode); 321 321 extern int fat_fill_super(struct super_block *sb, void *data, int silent, 322 - const struct inode_operations *fs_dir_inode_ops, 323 - int isvfat, void (*setup)(struct super_block *)); 322 + int isvfat, void (*setup)(struct super_block *)); 324 323 325 324 extern int fat_flush_inodes(struct super_block *sb, struct inode *i1, 326 325 struct inode *i2);
+1 -3
fs/fat/inode.c
··· 1238 1238 /* 1239 1239 * Read the super block of an MS-DOS FS. 1240 1240 */ 1241 - int fat_fill_super(struct super_block *sb, void *data, int silent, 1242 - const struct inode_operations *fs_dir_inode_ops, int isvfat, 1241 + int fat_fill_super(struct super_block *sb, void *data, int silent, int isvfat, 1243 1242 void (*setup)(struct super_block *)) 1244 1243 { 1245 1244 struct inode *root_inode = NULL, *fat_inode = NULL; ··· 1267 1268 sb->s_magic = MSDOS_SUPER_MAGIC; 1268 1269 sb->s_op = &fat_sops; 1269 1270 sb->s_export_op = &fat_export_ops; 1270 - sbi->dir_ops = fs_dir_inode_ops; 1271 1271 ratelimit_state_init(&sbi->ratelimit, DEFAULT_RATELIMIT_INTERVAL, 1272 1272 DEFAULT_RATELIMIT_BURST); 1273 1273
+2 -2
fs/fat/namei_msdos.c
··· 659 659 660 660 static void setup(struct super_block *sb) 661 661 { 662 + MSDOS_SB(sb)->dir_ops = &msdos_dir_inode_operations; 662 663 sb->s_d_op = &msdos_dentry_operations; 663 664 sb->s_flags |= MS_NOATIME; 664 665 } 665 666 666 667 static int msdos_fill_super(struct super_block *sb, void *data, int silent) 667 668 { 668 - return fat_fill_super(sb, data, silent, &msdos_dir_inode_operations, 669 - 0, setup); 669 + return fat_fill_super(sb, data, silent, 0, setup); 670 670 } 671 671 672 672 static struct dentry *msdos_mount(struct file_system_type *fs_type,
+2 -2
fs/fat/namei_vfat.c
··· 1065 1065 1066 1066 static void setup(struct super_block *sb) 1067 1067 { 1068 + MSDOS_SB(sb)->dir_ops = &vfat_dir_inode_operations; 1068 1069 if (MSDOS_SB(sb)->options.name_check != 's') 1069 1070 sb->s_d_op = &vfat_ci_dentry_ops; 1070 1071 else ··· 1074 1073 1075 1074 static int vfat_fill_super(struct super_block *sb, void *data, int silent) 1076 1075 { 1077 - return fat_fill_super(sb, data, silent, &vfat_dir_inode_operations, 1078 - 1, setup); 1076 + return fat_fill_super(sb, data, silent, 1, setup); 1079 1077 } 1080 1078 1081 1079 static struct dentry *vfat_mount(struct file_system_type *fs_type,