Messages in this thread Patches in this message |  | | Date | Sun, 19 Nov 2000 02:08:29 +0100 | From | Andrea Arcangeli <> | Subject | Re: [PATCH] ext2 largefile fixes + [f]truncate() error value fix |
| |
On Sat, Nov 18, 2000 at 07:46:29PM -0500, Alexander Viro wrote: > ed fs/ext2/inode.c <<EOF > /ext2_notify_change/ > /size >> 33/ > s/33/32/ > w > q > EOF
Good spotting but wrong fix.
Right fix for 2.2.x:
--- 33/fs/ext2/inode.c.~1~ Sun Nov 12 00:45:43 2000 +++ 33/fs/ext2/inode.c Sun Nov 19 02:02:51 2000 @@ -739,7 +739,7 @@ } #if BITS_PER_LONG == 64 - if (size >> 33) { + if (size >> 31) { struct super_block *sb = inode->i_sb; struct ext2_super_block *es = sb->u.ext2_sb.s_es; if (!(es->s_feature_ro_compat &
Fix for 2.4.0-test11-pre6:
--- 2.4.0-test11-pre6/fs/ext2/inode.c.~1~ Thu Nov 16 15:37:32 2000 +++ 2.4.0-test11-pre6/fs/ext2/inode.c Sun Nov 19 02:07:03 2000 @@ -1188,7 +1188,7 @@ raw_inode->i_dir_acl = cpu_to_le32(inode->u.ext2_i.i_dir_acl); else { raw_inode->i_size_high = cpu_to_le32(inode->i_size >> 32); - if (raw_inode->i_size_high) { + if (inode->i_size >> 31) { struct super_block *sb = inode->i_sb; struct ext2_super_block *es = sb->u.ext2_sb.s_es; if (!(es->s_feature_ro_compat & cpu_to_le32(EXT2_FEATURE_RO_COMPAT_LARGE_FILE))) {
Andrea - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/
|  |