Btrfs: update to the right index of defragment
authorLiu Bo <liubo2009@cn.fujitsu.com>
Thu, 29 Mar 2012 13:57:45 +0000 (09:57 -0400)
committerChris Mason <chris.mason@oracle.com>
Thu, 29 Mar 2012 13:57:45 +0000 (09:57 -0400)
commite1f041e14cfb322f41f41a308bfede00f1b080cd
tree8bae36b522a96948be985af03073813e3b0d851f
parent66c2689226ac322fbc9acd2e8e418b78dcd52f51
Btrfs: update to the right index of defragment

When we use autodefrag, we forget to update the index which indicates
the last page we've dirty.  And we'll set dirty flags on a same set of
pages again and again.

Signed-off-by: Liu Bo <liubo2009@cn.fujitsu.com>
Signed-off-by: Chris Mason <chris.mason@oracle.com>
fs/btrfs/ioctl.c