summaryrefslogtreecommitdiffstats
path: root/fs/fat/dir.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/fat/dir.c')
-rw-r--r--fs/fat/dir.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/fat/dir.c b/fs/fat/dir.c
index 0295a095b920..9d01db37183f 100644
--- a/fs/fat/dir.c
+++ b/fs/fat/dir.c
@@ -57,7 +57,7 @@ static inline void fat_dir_readahead(struct inode *dir, sector_t iblock,
57 if ((iblock & (sbi->sec_per_clus - 1)) || sbi->sec_per_clus == 1) 57 if ((iblock & (sbi->sec_per_clus - 1)) || sbi->sec_per_clus == 1)
58 return; 58 return;
59 /* root dir of FAT12/FAT16 */ 59 /* root dir of FAT12/FAT16 */
60 if ((sbi->fat_bits != 32) && (dir->i_ino == MSDOS_ROOT_INO)) 60 if (!is_fat32(sbi) && (dir->i_ino == MSDOS_ROOT_INO))
61 return; 61 return;
62 62
63 bh = sb_find_get_block(sb, phys); 63 bh = sb_find_get_block(sb, phys);
@@ -1313,7 +1313,7 @@ int fat_add_entries(struct inode *dir, void *slots, int nr_slots,
1313 } 1313 }
1314 } 1314 }
1315 if (dir->i_ino == MSDOS_ROOT_INO) { 1315 if (dir->i_ino == MSDOS_ROOT_INO) {
1316 if (sbi->fat_bits != 32) 1316 if (!is_fat32(sbi))
1317 goto error; 1317 goto error;
1318 } else if (MSDOS_I(dir)->i_start == 0) { 1318 } else if (MSDOS_I(dir)->i_start == 0) {
1319 fat_msg(sb, KERN_ERR, "Corrupted directory (i_pos %lld)", 1319 fat_msg(sb, KERN_ERR, "Corrupted directory (i_pos %lld)",