Set JBD2_FEATURE_INCOMPAT_64BIT on filesystems larger than 32-bit blocks
PATCH 1/1 Set JBD2_FEATURE_INCOMPAT_64BIT on filesystems larger than 32-bit blocks
Set the journals JBD2_FEATURE_INCOMPAT_64BIT on devices with more than 32bit block sizes during mount time. This ensure proper record lenth when writing to the journal.
--- fs/ext4/super.c | 11 +++++++++++ 1 file changed, 11 insertions(+)
fs/ext4/super.c +7 -0
@@ -1824,6 +1824,13 @@ static int ext4_fill_super (struct super goto failed_mount3; } +if (ext4_blocks_count (es) >0xffffffff && + !jbd2_journal_set_features (EXT4_SB (sb)->s_journal,0 ,0 , +JBD2_FEATURE_INCOMPAT_64BIT )) { +printk (KERN_ERR "ext4: Failed to set 64-bit journal feature\n" ); + goto failed_mount4; + } +/* We have now updated the journal if required, so we can * validate the data journaling mode. */ switch (test_opt (sb,DATA_FLAGS )) {
-JRS
Quoted 16 lines · Jose R. Santos
Set the journals
JBD2_FEATURE_INCOMPAT_64BITon devices with more than 32bit block sizes during mount time. This ensure proper record lenth when writing to the journal.Signed-off-by Jose R. Santos <[email protected]>Signed-off-by Andreas Dilger <[email protected]>Signed-off-by Mingming Cao <[email protected]>--- fs/ext4/super.c | 11 +++++++++++ 1 file changed, 11 insertions(+)Index:
linux-2.6.22-rc3/fs/ext4/super.c
===================================================================
fs/ext4/super.c static int ext4_fill_super (struct super · line 1827
Quoted 4 lines
fs/ext4/super.c +1
-0@@ -1824,6 +1824,13 @@ static int ext4_fill_super (struct super goto failed_mount3; } + if (ext4_blocks_count(es) > 0xffffffff &&
Perhaps you should use 0xffffffffULL ?
fs/ext4/super.c static int ext4_fill_super (struct super · line 1836
Quoted 9 lines
fs/ext4/super.c +6
-0+ !jbd2_journal_set_features(EXT4_SB(sb)->s_journal, 0, 0, + JBD2_FEATURE_INCOMPAT_64BIT)) { +printk (KERN_ERR "ext4: Failed to set 64-bit journal feature\n" ); + goto failed_mount4; + } +/* We have now updated the journal if required, so we can * validate the data journaling mode. */ switch (test_opt (sb,DATA_FLAGS )) {
Regards,
Laurent
Signature · 3 lines
------------- [email protected] -------------- "Any sufficiently advanced technology is indistinguishable from magic." - Arthur C. Clarke
Quoted 20 lines · On Wed, 06 Jun 2007 09:56:10 +0200 Laurent Vivier <[email protected]>…
Quoted 19 lines · Jose R. Santos
Set the journals
JBD2_FEATURE_INCOMPAT_64BITon devices with more than 32bit block sizes during mount time. This ensure proper record lenth when writing to the journal.Signed-off-by Jose R. Santos <[email protected]>Signed-off-by Andreas Dilger <[email protected]>Signed-off-by Mingming Cao <[email protected]>--- fs/ext4/super.c | 11 +++++++++++ 1 file changed, 11 insertions(+)Index:
linux-2.6.22-rc3/fs/ext4/super.c
===================================================================fs/ext4/super.c +0
-0@@ -1824,6 +1824,13 @@ static int ext4_fill_super (struct super goto failed_mount3; }
Quoted 3 lines
fs/ext4/super.c static int ext4_fill_super (struct super · line 1827
Quoted 1 line
fs/ext4/super.c +1
-0+ if (ext4_blocks_count(es) > 0xffffffff &&Perhaps you should use
0xffffffffULL?
Ah yes... Thanks for pointing that out.
I will make that change and add you to the Signed-off-by list if its OK with you.
Thanks
-JRS