summaryrefslogtreecommitdiffstats
path: root/fs/ext4/ext4.h
diff options
context:
space:
mode:
Diffstat (limited to 'fs/ext4/ext4.h')
-rw-r--r--fs/ext4/ext4.h21
1 files changed, 20 insertions, 1 deletions
diff --git a/fs/ext4/ext4.h b/fs/ext4/ext4.h
index 2a2e6ed9aab4..c1504c471fef 100644
--- a/fs/ext4/ext4.h
+++ b/fs/ext4/ext4.h
@@ -1313,7 +1313,9 @@ struct ext4_super_block {
1313 __u8 s_first_error_time_hi; 1313 __u8 s_first_error_time_hi;
1314 __u8 s_last_error_time_hi; 1314 __u8 s_last_error_time_hi;
1315 __u8 s_pad[2]; 1315 __u8 s_pad[2];
1316 __le32 s_reserved[96]; /* Padding to the end of the block */ 1316 __le16 s_encoding; /* Filename charset encoding */
1317 __le16 s_encoding_flags; /* Filename charset encoding flags */
1318 __le32 s_reserved[95]; /* Padding to the end of the block */
1317 __le32 s_checksum; /* crc32c(superblock) */ 1319 __le32 s_checksum; /* crc32c(superblock) */
1318}; 1320};
1319 1321
@@ -1338,6 +1340,16 @@ struct ext4_super_block {
1338/* Number of quota types we support */ 1340/* Number of quota types we support */
1339#define EXT4_MAXQUOTAS 3 1341#define EXT4_MAXQUOTAS 3
1340 1342
1343#define EXT4_ENC_UTF8_12_1 1
1344
1345/*
1346 * Flags for ext4_sb_info.s_encoding_flags.
1347 */
1348#define EXT4_ENC_STRICT_MODE_FL (1 << 0)
1349
1350#define ext4_has_strict_mode(sbi) \
1351 (sbi->s_encoding_flags & EXT4_ENC_STRICT_MODE_FL)
1352
1341/* 1353/*
1342 * fourth extended-fs super-block data in memory 1354 * fourth extended-fs super-block data in memory
1343 */ 1355 */
@@ -1387,6 +1399,10 @@ struct ext4_sb_info {
1387 struct kobject s_kobj; 1399 struct kobject s_kobj;
1388 struct completion s_kobj_unregister; 1400 struct completion s_kobj_unregister;
1389 struct super_block *s_sb; 1401 struct super_block *s_sb;
1402#ifdef CONFIG_UNICODE
1403 struct unicode_map *s_encoding;
1404 __u16 s_encoding_flags;
1405#endif
1390 1406
1391 /* Journaling */ 1407 /* Journaling */
1392 struct journal_s *s_journal; 1408 struct journal_s *s_journal;
@@ -1660,6 +1676,7 @@ static inline void ext4_clear_state_flags(struct ext4_inode_info *ei)
1660#define EXT4_FEATURE_INCOMPAT_LARGEDIR 0x4000 /* >2GB or 3-lvl htree */ 1676#define EXT4_FEATURE_INCOMPAT_LARGEDIR 0x4000 /* >2GB or 3-lvl htree */
1661#define EXT4_FEATURE_INCOMPAT_INLINE_DATA 0x8000 /* data in inode */ 1677#define EXT4_FEATURE_INCOMPAT_INLINE_DATA 0x8000 /* data in inode */
1662#define EXT4_FEATURE_INCOMPAT_ENCRYPT 0x10000 1678#define EXT4_FEATURE_INCOMPAT_ENCRYPT 0x10000
1679#define EXT4_FEATURE_INCOMPAT_CASEFOLD 0x20000
1663 1680
1664extern void ext4_update_dynamic_rev(struct super_block *sb); 1681extern void ext4_update_dynamic_rev(struct super_block *sb);
1665 1682
@@ -1753,6 +1770,7 @@ EXT4_FEATURE_INCOMPAT_FUNCS(csum_seed, CSUM_SEED)
1753EXT4_FEATURE_INCOMPAT_FUNCS(largedir, LARGEDIR) 1770EXT4_FEATURE_INCOMPAT_FUNCS(largedir, LARGEDIR)
1754EXT4_FEATURE_INCOMPAT_FUNCS(inline_data, INLINE_DATA) 1771EXT4_FEATURE_INCOMPAT_FUNCS(inline_data, INLINE_DATA)
1755EXT4_FEATURE_INCOMPAT_FUNCS(encrypt, ENCRYPT) 1772EXT4_FEATURE_INCOMPAT_FUNCS(encrypt, ENCRYPT)
1773EXT4_FEATURE_INCOMPAT_FUNCS(casefold, CASEFOLD)
1756 1774
1757#define EXT2_FEATURE_COMPAT_SUPP EXT4_FEATURE_COMPAT_EXT_ATTR 1775#define EXT2_FEATURE_COMPAT_SUPP EXT4_FEATURE_COMPAT_EXT_ATTR
1758#define EXT2_FEATURE_INCOMPAT_SUPP (EXT4_FEATURE_INCOMPAT_FILETYPE| \ 1776#define EXT2_FEATURE_INCOMPAT_SUPP (EXT4_FEATURE_INCOMPAT_FILETYPE| \
@@ -1780,6 +1798,7 @@ EXT4_FEATURE_INCOMPAT_FUNCS(encrypt, ENCRYPT)
1780 EXT4_FEATURE_INCOMPAT_MMP | \ 1798 EXT4_FEATURE_INCOMPAT_MMP | \
1781 EXT4_FEATURE_INCOMPAT_INLINE_DATA | \ 1799 EXT4_FEATURE_INCOMPAT_INLINE_DATA | \
1782 EXT4_FEATURE_INCOMPAT_ENCRYPT | \ 1800 EXT4_FEATURE_INCOMPAT_ENCRYPT | \
1801 EXT4_FEATURE_INCOMPAT_CASEFOLD | \
1783 EXT4_FEATURE_INCOMPAT_CSUM_SEED | \ 1802 EXT4_FEATURE_INCOMPAT_CSUM_SEED | \
1784 EXT4_FEATURE_INCOMPAT_LARGEDIR) 1803 EXT4_FEATURE_INCOMPAT_LARGEDIR)
1785#define EXT4_FEATURE_RO_COMPAT_SUPP (EXT4_FEATURE_RO_COMPAT_SPARSE_SUPER| \ 1804#define EXT4_FEATURE_RO_COMPAT_SUPP (EXT4_FEATURE_RO_COMPAT_SPARSE_SUPER| \