diff options
author | Liu Bo <bo.li.liu@oracle.com> | 2013-01-29 04:18:40 +0100 |
---|---|---|
committer | Chris Mason <chris.mason@fusionio.com> | 2013-02-21 00:06:09 +0100 |
commit | 38c227d87c49ad5d173cb5d4374d49acec6a495d (patch) | |
tree | e68e689e44508cea68bf51928d864cd19f12e09d /kernel/time.c | |
parent | Btrfs: fix max chunk size on raid5/6 (diff) | |
download | linux-38c227d87c49ad5d173cb5d4374d49acec6a495d.tar.xz linux-38c227d87c49ad5d173cb5d4374d49acec6a495d.zip |
Btrfs: snapshot-aware defrag
This comes from one of btrfs's project ideas,
As we defragment files, we break any sharing from other snapshots.
The balancing code will preserve the sharing, and defrag needs to grow this
as well.
Now we're able to fill the blank with this patch, in which we make full use of
backref walking stuff.
Here is the basic idea,
o set the writeback ranges started by defragment with flag EXTENT_DEFRAG
o at endio, after we finish updating fs tree, we use backref walking to find
all parents of the ranges and re-link them with the new COWed file layout by
adding corresponding backrefs.
Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Signed-off-by: Liu Bo <bo.li.liu@oracle.com>
Signed-off-by: Chris Mason <chris.mason@fusionio.com>
Diffstat (limited to 'kernel/time.c')
0 files changed, 0 insertions, 0 deletions