Re: [Ext2-devel] [PATCH] fix ext3 mounts at 16T

From: Mingming Cao
Date: Fri Aug 18 2006 - 13:31:17 EST


sho@xxxxxxxxxxxxxx wrote:

I have reviewed your patch and found other place which might
cause overflow as below. If group_first_block is the first block of
the last group, overflow will occur. This has already been fixed
in my patch.

o ext3_try_to_allocate_with_rsv() in fs/ext3/balloc.c
if ((my_rsv->rsv_start >= group_first_block + EXT3_BLOCKS_PER_GROUP(sb))
|| (my_rsv->rsv_end < group_first_block))
BUG();


Yes, this isn't being addressed in the current 2.6.18-rc4 kernel. I think this is better than casting to unsigned long long:

- if ((my_rsv->rsv_start >= group_first_block + EXT3_BLOCKS_PER_GROUP(sb))
+ if ((my_rsv->rsv_start > group_first_block - 1 + EXT3_BLOCKS_PER_GROUP(sb))


Thanks,

Mingming
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/