Btrfs: Init address_space->writeback_index properly
authorChris Mason <chris.mason@oracle.com>
Fri, 15 Aug 2008 19:34:14 +0000 (15:34 -0400)
committerChris Mason <chris.mason@oracle.com>
Thu, 25 Sep 2008 15:04:06 +0000 (11:04 -0400)
commitdb69e0ebae944690de89851315404f483e6464e0
tree2c95462bfc86b0ab34d3ee1ab5675b060d896430
parent2db04966ae9a3eeb57f28df9aac4e77d5b287cb1
Btrfs: Init address_space->writeback_index properly

The writeback_index field is used by write_cache_pages to pick up where
writeback on a given inode left off.  But, it is never set to a sane
value, so writeback can often start at a random offset in the file.

Kernels 2.6.28 and higher will have this fixed, but for everyone else,
we also fill in the value in btrfs.

Signed-off-by: Chris Mason <chris.mason@oracle.com>
fs/btrfs/inode.c