[dm-devel] 2 TB wraparound on snapshots on kernels < 2.6.33
Phillip Susi
psusi at cfl.rr.com
Wed Jun 16 13:52:54 UTC 2010
Aha! I looked at the code carefully as it aroused my suspicions, but I
couldn't quite work out how it actually caused the problem. Good catch.
On 6/16/2010 9:45 AM, Mikulas Patocka wrote:
> The bug existed even in upstream, but only in 2.6.32 kernel. The reason
> was this function:
> static inline chunk_t sector_to_chunk(struct dm_exception_store *store,
> sector_t sector)
> {
> return (sector & ~store->chunk_mask) >> store->chunk_shift;
> }
>
> "store->chunk_mask" was changed to be unsigned in 2.6.32, so it was
> masking the sector with 32-bit value. In 2.6.33 that masking was removed.
> Ubuntu picked that 2.6.32 patch but didn't pick further patches.
>
> Mikulas
More information about the dm-devel
mailing list